Skip to content

Commit 3cde5a3

Browse files
committed
Merge pull request #97455 from Calinou/doc-lineedit-text-submitted
Clarify when LineEdit's `text_submitted` signal is emitted
2 parents 807136b + b3d413d commit 3cde5a3

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

doc/classes/LineEdit.xml

+4-4
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,11 @@
66
<description>
77
[LineEdit] provides an input field for editing a single line of text.
88
- When the [LineEdit] control is focused using the keyboard arrow keys, it will only gain focus and not enter edit mode.
9-
- To enter edit mode, click on the control with the mouse or press the "ui_text_submit" action (default: [kbd]Enter[/kbd] or [kbd]Kp Enter[/kbd]).
10-
- To exit edit mode, press "ui_text_submit" or "ui_cancel" (default: [kbd]Escape[/kbd]) actions.
9+
- To enter edit mode, click on the control with the mouse or press the [code]ui_text_submit[/code] action (by default [kbd]Enter[/kbd] or [kbd]Kp Enter[/kbd]).
10+
- To exit edit mode, press [code]ui_text_submit[/code] or [code]ui_cancel[/code] (by default [kbd]Escape[/kbd]) actions.
1111
- Check [method is_editing] and [signal editing_toggled] for more information.
1212
[b]Important:[/b]
13-
- Focusing the [LineEdit] with "ui_focus_next" (default: [kbd]Tab[/kbd]) or "ui_focus_prev" (default: [kbd]Shift + Tab[/kbd]) or [method Control.grab_focus] still enters edit mode (for compatibility).
13+
- Focusing the [LineEdit] with [code]ui_focus_next[/code] (by default [kbd]Tab[/kbd]) or [code]ui_focus_prev[/code] (by default [kbd]Shift + Tab[/kbd]) or [method Control.grab_focus] still enters edit mode (for compatibility).
1414
[LineEdit] features many built-in shortcuts that are always available ([kbd]Ctrl[/kbd] here maps to [kbd]Cmd[/kbd] on macOS):
1515
- [kbd]Ctrl + C[/kbd]: Copy
1616
- [kbd]Ctrl + X[/kbd]: Cut
@@ -365,7 +365,7 @@
365365
<signal name="text_submitted">
366366
<param index="0" name="new_text" type="String" />
367367
<description>
368-
Emitted when the user presses [constant KEY_ENTER] on the [LineEdit].
368+
Emitted when the user presses the [code]ui_text_submit[/code] action (by default: [kbd]Enter[/kbd] or [kbd]Kp Enter[/kbd]) while the [LineEdit] has focus.
369369
</description>
370370
</signal>
371371
</signals>

0 commit comments

Comments
 (0)