Struct IMECompositionString
A struct representing an string of characters generated by an IME for text input.
Namespace: UnityEngine.InputSystem.LowLevel
Syntax
public struct IMECompositionString : IEnumerable<char>
Remarks
This is the internal representation of character strings in the event stream. It is exposed to user content through the OnIMECompositionChanged(IMECompositionString) method. It can easily be converted to a normal C# string using ToString(), but is exposed as the raw struct to avoid allocating memory by default.
Constructors
IMECompositionString(String)
Declaration
public IMECompositionString(string characters)
Parameters
Type | Name | Description |
---|---|---|
String | characters |
Properties
Count
Declaration
public int Count { get; }
Property Value
Type | Description |
---|---|
Int32 |
Item[Int32]
Declaration
public char this[int index] { get; }
Parameters
Type | Name | Description |
---|---|---|
Int32 | index |
Property Value
Type | Description |
---|---|
Char |
Methods
GetEnumerator()
Declaration
public IEnumerator<char> GetEnumerator()
Returns
Type | Description |
---|---|
IEnumerator<Char> |
ToString()
Declaration
public override string ToString()
Returns
Type | Description |
---|---|
String |