04 FString插入与移除 04 FString插入与移除 4.1 插入 FString s = TEXT("hello world");s.InsertAt(2,'x');s.InsertAt(2,"hello");s.InsertAt(2,TEXT("hello"));const ANSICHAR* p = "f";const WIDECHAR* p2 = "g";s.InsertAt(2,p);s.InsertAt(2,p2); 4.2 移除 FString s = TEXT("hello world");s.RemoveAt(2,3,true); //index count isShrinks.RemoveFromStart(TEXT("hello")); //find from start, if exists, remove its.RemoveFromEnd(TEXT("world")); //find from end, if exists, remove its.RemoveSpacesInline(); //remove all spaces.Shrink(); //clear space 发布于 2023-09-27