Stay organized with collections
Save and categorize content based on your preferences.
GameTextInputState
#include <gametextinput.h>
This struct holds the state of an editable section of text.
Summary
The text can have a selection and a composing region defined on it. A composing region is used by IMEs that allow input using multiple steps to compose a glyph or word. Use functions GameTextInput_getState and GameTextInput_setState to read and modify the state that an IME is editing.
Public attributes
|
composingRegion
|
A composing region defined on the text.
|
selection
|
A selection defined on the text.
|
text_UTF8
|
const char *
Text owned by the state, as a modified UTF-8 string.
|
text_length
|
int32_t
Length in bytes of text_UTF8, not including the null at end.
|
Public attributes
composingRegion
GameTextInputSpan GameTextInputState::composingRegion
A composing region defined on the text.
selection
GameTextInputSpan GameTextInputState::selection
A selection defined on the text.
text_UTF8
const char * GameTextInputState::text_UTF8
text_length
int32_t GameTextInputState::text_length
Length in bytes of text_UTF8, not including the null at end.
Content and code samples on this page are subject to the licenses described in the Content License. Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.
Last updated 2021-07-12 UTC.
[null,null,["Last updated 2021-07-12 UTC."],[],[],null,["# GameTextInputState Struct Reference\n\nGameTextInputState\n==================\n\n`#include \u003cgametextinput.h\u003e`\n\nThis struct holds the state of an editable section of text.\n\nSummary\n-------\n\nThe text can have a selection and a composing region defined on it. A composing region is used by IMEs that allow input using multiple steps to compose a glyph or word. Use functions GameTextInput_getState and GameTextInput_setState to read and modify the state that an IME is editing.\n\n| ### Public attributes ||\n|-------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------|\n| [composingRegion](#struct_game_text_input_state_1aa1be38f4bf3263b6f7e3659551d00b62) | [GameTextInputSpan](/reference/games/game-text-input/struct/game-text-input-span#struct_game_text_input_span) A composing region defined on the text. |\n| [selection](#struct_game_text_input_state_1a658f4715131e56dad9a42ba3cabbe431) | [GameTextInputSpan](/reference/games/game-text-input/struct/game-text-input-span#struct_game_text_input_span) A selection defined on the text. |\n| [text_UTF8](#struct_game_text_input_state_1a092c8a927e349378ff4917de7f22a28f) | `const char *` Text owned by the state, as a modified UTF-8 string. |\n| [text_length](#struct_game_text_input_state_1a9981733dff3f0cb99a7095565ca92e4b) | `int32_t` Length in bytes of text_UTF8, *not* including the null at end. |\n\nPublic attributes\n-----------------\n\n### composingRegion\n\n```text\nGameTextInputSpan GameTextInputState::composingRegion\n``` \nA composing region defined on the text. \n\n### selection\n\n```text\nGameTextInputSpan GameTextInputState::selection\n``` \nA selection defined on the text. \n\n### text_UTF8\n\n```gdscript\nconst char * GameTextInputState::text_UTF8\n``` \nText owned by the state, as a modified UTF-8 string.\n\nNull-terminated. \u003chttps://en.wikipedia.org/wiki/UTF-8#Modified_UTF-8\u003e \n\n### text_length\n\n```scdoc\nint32_t GameTextInputState::text_length\n``` \nLength in bytes of text_UTF8, *not* including the null at end."]]