LineEditΒΆ

Inherited: Frame

DescriptionΒΆ

The LineEdit class provides a user interface for text input, supporting text editing, cursor positioning, and input handling. It inherits functionality from the Widget class and extends it to handle text-related features and animations.

Public MethodsΒΆ

float

cursorAt (int position) const

void

editingFinished ()

void

focusIn ()

void

focusOut ()

Font *

font () const

void

setFont (Font * font)

void

setText (const TString & text)

void

setTextColor (const Vector4 & color)

TString

text () const

Vector4

textColor () const

Static MethodsΒΆ

None

Methods DescriptionΒΆ

float LineEdit::cursorAt (int position) const

Returns a position for virtual cursor.


void LineEdit::editingFinished ()

Called when editing is finished (Enter key pressed). Emits a signal indicating editing has completed.


void LineEdit::focusIn ()

Called when the component receives focus. Emits a signal indicating focus has been gained.


void LineEdit::focusOut ()

Called when the component loses focus. Emits a signal indicating focus has been lost.


Font * LineEdit::font () const

Returns the font which will be used to draw a text.

See also setFont().


void LineEdit::setFont (Font * font)

Changes the font which will be used to draw a text.

See also font().


void LineEdit::setText (TString & text)

Sets the text in the TextInput.

See also text().


void LineEdit::setTextColor (Vector4 & color)

Sets the color of the text.

See also textColor().


TString LineEdit::text () const

Returns the current text entered into the TextInput.

See also setText().


Vector4 LineEdit::textColor () const

Returns color of the text.

See also setTextColor().