Utf32Buffer.Insert Method
Assembly: Topten.RichTextKit.dll
Namespace: Topten.RichTextKit.Utils
Declaring Type: Utf32Buffer
Overloads
Insert(int, Slice<int>) | Appends utf32 data to this buffer |
Insert(int, string) | Inserts text to this buffer, converting from UTF-16 to UTF-32 |
Insert(int, ReadOnlySpan<char>) | Inserts text to this buffer, converting from UTF-16 to UTF-32 |
Insert(int, Slice<int>) | |
Insert(int, int, bool) | Inserts room into the buffer |
Insert(int, Slice<int>)
Appends utf32 data to this buffer
public Slice<int> Insert(int position, Slice<int> data);
Parameters
int position | Position to insert the string |
Slice<int> data | The string of text to be appended |
Returns
Slice<int> | A slice representing the added UTF-32 data. |
Insert(int, string)
Inserts text to this buffer, converting from UTF-16 to UTF-32
public Slice<int> Insert(int position, string str);
Parameters
int position | The position to insert the string |
string str | The string of text to be inserted |
Returns
Slice<int> | A slice representing the added UTF-32 data. |
Insert(int, ReadOnlySpan<char>)
Inserts text to this buffer, converting from UTF-16 to UTF-32
public Slice<int> Insert(int position, ReadOnlySpan<char> str);
Parameters
int position | The position to insert the string |
ReadOnlySpan<char> str | The string of text to be inserted |
Returns
Slice<int> | A slice representing the added UTF-32 data. |
Insert(int, Slice<int>)
public Slice<int> Insert(int position, Slice<int> data);
Parameters
int position | |
Slice<int> data |
Returns
Slice<int> |
Insert(int, int, bool)
Inserts room into the buffer
public Slice<int> Insert(int position, int length, bool clear = true);
Parameters
int position | The position to insert at |
int length | The length to insert |
bool clear = true | Whether to clear the inserted part of the buffer |
Returns
Slice<int> | The new buffer area as a slice |