Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions automated_updates_data.json
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,10 @@
{
"date": "2026-04-22",
"summary": "Improved resources-loading docs (named Preload scene action, documented SceneLoadingProgress expression and AreSceneAssetsLoaded condition, clarified custom loading screen approach) and added extension lifecycle functions table to events/functions docs"
},
{
"date": "2026-06-04",
"summary": "Improved Text Input object docs: added Input is submitted condition, Focus action/Focused condition, and placeholder and maximum length explanations"
}
]
}
12 changes: 12 additions & 0 deletions docs/gdevelop5/objects/text_input/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,18 @@ According to the type, some devices might display visual aids or **a different k
After adding a Text Input object, put an instance on the scene. You can then use the expression `Text` on the object in the events to read the text. For example, this event copies the content of the field into a [Text object](/gdevelop5/objects/text) (to display it somewhere else on the screen):
![](pasted/20220310-010309.png)

To know when the player is done typing, use the **Input is submitted** condition. This is triggered when the player presses the Enter key on a keyboard, or the corresponding button on a mobile virtual keyboard. It's the natural way to react to a search query or to validate a login form without adding a separate button.

## Focusing the field

A field is *focused* when the cursor is in it and the player can type. Use the **Focused** condition to check this state, and the **Focus** action to put the cursor in the field from events (as if the player had touched or clicked it). This is useful to automatically select the first field of a form when a scene starts, or to move focus to the next field after a submission.

## Placeholder and limiting the input

A **placeholder** is the greyed-out hint text displayed while the field is empty (for example "Enter your name..."). It disappears as soon as the player types and is never returned by the `Text` expression.

You can also set a **maximum length** to limit how many characters the player can enter, which is handy for things like usernames or fixed-length codes.

## Read-only and disabled fields

You can set, either from the object properties or using actions, the field as :
Expand Down