Control that provides single line string editing.
LineEdit provides a single line string editor, used for text fields.
Adds [code]text[/code] after the cursor. If the resulting value is longer than [member max_length], nothing happens.
Erases the [LineEdit] text.
Gets whether the line edit caret is blinking.
Gets the line edit caret blink speed.
Set the line edit caret to blink.
Set the line edit caret blink speed. Cannot be less then or equal to 0.
Return the align mode of the [code]LineEdit[/code].
Returns the cursor position inside the [code]LineEdit[/code].
Return the maximum amount of characters the [code]LineEdit[/code] can edit. If 0 is returned, no limit exists.
Returns the [PopupMenu] of this [code]LineEdit[/code]. By default, this menu is displayed when right-clicking on the [LineEdit].
Return the placeholder text.
Return transparency of the placeholder text.
Return the text in the [code]LineEdit[/code].
Return the [i]editable[/i] status of the [code]LineEdit[/code] (see [method set_editable]).
Return the [i]secret[/i] status of the [code]LineEdit[/code] (see [method set_secret]).
Executes a given action as defined in the MENU_* enum.
Selects characters inside [LineEdit] between [code]from[/code] and [code]to[/code]. By default [code]from[/code] is at the beginning and [code]to[/code] at the end.
[codeblock]
text = "Welcome"
select() # Welcome
select(4) # ome
select(2, 5) # lco
[/codeblock]
Selects the whole [String].
Set text alignment of the [code]LineEdit[/code].
Sets the cursor position inside the [code]LineEdit[/code]. The text may scroll if needed.
Set the [i]editable[/i] status of the [code]LineEdit[/code]. When disabled, existing text can't be modified and new text can't be added.
Set the maximum amount of characters the [code]LineEdit[/code] can edit, and cropping existing text in case it exceeds that limit. Setting 0 removes the limit.
Set the placeholder text.
Set transparency of the placeholder text.
Set the [i]secret[/i] status of the [code]LineEdit[/code]. When enabled, every character is displayed as "*".
Set the text in the [code]LineEdit[/code], clearing the existing one and the selection.
Text alignment as defined in the ALIGN_* enum.
If [code]true[/code] the caret (visual cursor) blinks.
Duration (in seconds) of a caret's blinking cycle.
If [code]false[/code] existing text cannot be modified and new text cannot be added.
If [code]true[/code] the [LineEdit] width will increase to stay longer than the [member text]. It will [b]not[/b] compress if the [member text] is shortened.
Defines how the [LineEdit] can grab focus (Keyboard and mouse, only keyboard, or none). See [code]enum FocusMode[/code] in [Control] for details.
Maximum amount of characters that can be entered inside the [LineEdit]. If [code]0[/code], there is no limit.
Opacity of the [member placeholder_text]. From [code]0[/code] to [code]1[/code].
Text shown when the [LineEdit] is empty. It is [b]not[/b] the [LineEdit]'s default value (see [member text]).
If [code]true[/code] every character is shown as "*".
String value of the [LineEdit].
Emitted when the text changes.
Emitted when the user presses KEY_ENTER on the [code]LineEdit[/code].
Aligns the text on the left hand side of the [LineEdit].
Centers the text in the middle of the [LineEdit].
Aligns the text on the right hand side of the [LineEdit].
Stretches whitespaces to fit the [LineEdit]'s width.
Cuts (Copies and clears) the selected text.
Copies the selected text.
Pastes the clipboard text over the selected text (or at the cursor's position).
Erases the whole [Linedit] text.
Selects the whole [Linedit] text.
Undoes the previous action.