text:
:github_url: hide

.. Generated automatically by doc/tools/makerst.py in Godot's source tree.
.. DO NOT EDIT THIS FILE, but the TLRichTextEdit.xml source instead.
.. The source is found in doc/classes or modules/<name>/doc_classes.

.. _class_TLRichTextEdit:

TLRichTextEdit
==============

**Inherits:**

**Category:** Core

Brief Description
-----------------

Rich text display and input control.

Rich text can contain custom text, fonts, images and formatting.

Properties
----------

+---------------------------------------------------+-----------------------------------------------------------------------------+---------------------+
| Color                                             | :ref:`back_color<class_TLRichTextEdit_property_back_color>`                 | Color( 1, 1, 1, 0 ) |
+---------------------------------------------------+-----------------------------------------------------------------------------+---------------------+
| Control.FocusMode                                 | focus_mode                                                                  | **O:** 2            |
+---------------------------------------------------+-----------------------------------------------------------------------------+---------------------+
| float                                             | :ref:`paragraph_spacing<class_TLRichTextEdit_property_paragraph_spacing>`   | 3.0                 |
+---------------------------------------------------+-----------------------------------------------------------------------------+---------------------+
| bool                                              | :ref:`readonly<class_TLRichTextEdit_property_readonly>`                     | false               |
+---------------------------------------------------+-----------------------------------------------------------------------------+---------------------+
| bool                                              | :ref:`selectable<class_TLRichTextEdit_property_selectable>`                 | true                |
+---------------------------------------------------+-----------------------------------------------------------------------------+---------------------+
| :ref:`TLShapedParagraph<class_TLShapedParagraph>` | :ref:`paragraphs/{index}<class_TLRichTextEdit_property_paragraphs/{index}>` |                     |
+---------------------------------------------------+-----------------------------------------------------------------------------+---------------------+

Methods
-------

.. table::
   :class: longtable
   :widths: 7 20

   +---------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | void                                                          | :ref:`add_attribute<class_TLRichTextEdit_method_add_attribute>` **(** :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` selection, int attribute, Variant value **)**                         |
   +---------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | void                                                          | :ref:`clear<class_TLRichTextEdit_method_clear>` **(** **)**                                                                                |
   +---------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | void                                                          | :ref:`debug_draw<class_TLRichTextEdit_method_debug_draw>` **(** RID rid, Vector2 position, Vector2 hit_position, bool draw_brk_ops, bool draw_jst_ops **)**                                               |
   +---------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | void                                                          | :ref:`debug_draw_as_hex<class_TLRichTextEdit_method_debug_draw_as_hex>` **(** RID rid, Vector2 position, Vector2 hit_position, bool draw_brk_ops, bool draw_jst_ops **)**                                 |
   +---------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | void                                                          | :ref:`debug_draw_logical_as_hex<class_TLRichTextEdit_method_debug_draw_logical_as_hex>` **(** RID rid, Vector2 position, Vector2 hit_position, bool draw_brk_ops, bool draw_jst_ops **)**                 |
   +---------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | Vector2                                                       | :ref:`get_caret_position<class_TLRichTextEdit_method_get_caret_position>` **(** **)**                                                                                |
   +---------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | String                                                        | :ref:`get_cluster_debug_info_hit_test<class_TLRichTextEdit_method_get_cluster_debug_info_hit_test>` **(** Vector2 position **)**                                                                          |
   +---------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | Array                                                         | :ref:`get_cluster_glyphs_hit_test<class_TLRichTextEdit_method_get_cluster_glyphs_hit_test>` **(** Vector2 position **)**                                                                                |
   +---------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | Rect2                                                         | :ref:`get_cluster_rect_hit_test<class_TLRichTextEdit_method_get_cluster_rect_hit_test>` **(** Vector2 position **)**                                                                                |
   +---------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | :ref:`TLShapedParagraph<class_TLShapedParagraph>`             | :ref:`get_paragraph<class_TLRichTextEdit_method_get_paragraph>` **(** int index **)** const                                                                                |
   +---------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | int                                                           | :ref:`get_paragraphs<class_TLRichTextEdit_method_get_paragraphs>` **(** **)**                                                                                |
   +---------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` | :ref:`get_selection<class_TLRichTextEdit_method_get_selection>` **(** **)** const                                                                                |
   +---------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | int                                                           | :ref:`insert_paragraph<class_TLRichTextEdit_method_insert_paragraph>` **(** :ref:`TLShapedParagraph<class_TLShapedParagraph>` para, int index **)**                                                       |
   +---------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | void                                                          | :ref:`remove_attribute<class_TLRichTextEdit_method_remove_attribute>` **(** :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` selection, int attribute **)**                                  |
   +---------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | void                                                          | :ref:`remove_attributes<class_TLRichTextEdit_method_remove_attributes>` **(** :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` selection **)**                                               |
   +---------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | void                                                          | :ref:`remove_paragraph<class_TLRichTextEdit_method_remove_paragraph>` **(** int index **)**                                                                                |
   +---------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | void                                                          | :ref:`replace_sstring<class_TLRichTextEdit_method_replace_sstring>` **(** :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` selection, :ref:`TLShapedString<class_TLShapedString>` text **)** |
   +---------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | void                                                          | :ref:`replace_text<class_TLRichTextEdit_method_replace_text>` **(** :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` selection, String text **)**                                            |
   +---------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | void                                                          | :ref:`replace_utf16<class_TLRichTextEdit_method_replace_utf16>` **(** :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` selection, PoolByteArray text **)**                                   |
   +---------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | void                                                          | :ref:`replace_utf32<class_TLRichTextEdit_method_replace_utf32>` **(** :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` selection, PoolByteArray text **)**                                   |
   +---------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | void                                                          | :ref:`replace_utf8<class_TLRichTextEdit_method_replace_utf8>` **(** :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` selection, PoolByteArray text **)**                                     |
   +---------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | void                                                          | :ref:`set_paragraph<class_TLRichTextEdit_method_set_paragraph>` **(** :ref:`TLShapedParagraph<class_TLShapedParagraph>` para, int index **)**                                                             |
   +---------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | void                                                          | :ref:`set_paragraph_back_color<class_TLRichTextEdit_method_set_paragraph_back_color>` **(** :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` selection, Color bcolor **)**                   |
   +---------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | void                                                          | :ref:`set_paragraph_brk_flags<class_TLRichTextEdit_method_set_paragraph_brk_flags>` **(** :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` selection, int flags **)**                        |
   +---------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | void                                                          | :ref:`set_paragraph_halign<class_TLRichTextEdit_method_set_paragraph_halign>` **(** :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` selection, int halign **)**                             |
   +---------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | void                                                          | :ref:`set_paragraph_indent<class_TLRichTextEdit_method_set_paragraph_indent>` **(** :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` selection, float indent **)**                           |
   +---------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | void                                                          | :ref:`set_paragraph_jst_flags<class_TLRichTextEdit_method_set_paragraph_jst_flags>` **(** :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` selection, int flags **)**                        |
   +---------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | void                                                          | :ref:`set_paragraph_line_spacing<class_TLRichTextEdit_method_set_paragraph_line_spacing>` **(** :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` selection, float line_spacing **)**         |
   +---------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | void                                                          | :ref:`set_paragraph_width<class_TLRichTextEdit_method_set_paragraph_width>` **(** :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` selection, float width **)**                              |
   +---------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | void                                                          | :ref:`set_selection<class_TLRichTextEdit_method_set_selection>` **(** :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` selection **)**                                                       |
   +---------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+

Signals
-------

.. _class_TLRichTextEdit_signal_cursor_changed:

- **cursor_changed** **(** **)**

Emitted when caret moves or selection changes.

----

.. _class_TLRichTextEdit_signal_paragraph_changed:

- **paragraph_changed** **(** **)**

Emitted when paragraph text or attributes changes.

Property Descriptions
---------------------

.. _class_TLRichTextEdit_property_back_color:

- Color **back_color**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+-----------------------+
   | *Default* | Color( 1, 1, 1, 0 )   |
   +-----------+-----------------------+
   | *Setter*  | set_back_color(value) |
   +-----------+-----------------------+
   | *Getter*  | get_back_color()      |
   +-----------+-----------------------+

Background color of the control.

----

.. _class_TLRichTextEdit_property_paragraph_spacing:

- float **paragraph_spacing**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+------------------------------+
   | *Default* | 3.0                          |
   +-----------+------------------------------+
   | *Setter*  | set_paragraph_spacing(value) |
   +-----------+------------------------------+
   | *Getter*  | get_paragraph_spacing()      |
   +-----------+------------------------------+

Spacing between the paragraphs in pixels.

----

.. _class_TLRichTextEdit_property_readonly:

- bool **readonly**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+---------------------+
   | *Default* | false               |
   +-----------+---------------------+
   | *Setter*  | set_readonly(value) |
   +-----------+---------------------+
   | *Getter*  | get_readonly()      |
   +-----------+---------------------+

If ``true``, existing text cannot be modified and new text cannot be added.

----

.. _class_TLRichTextEdit_property_selectable:

- bool **selectable**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+-----------------------+
   | *Default* | true                  |
   +-----------+-----------------------+
   | *Setter*  | set_selectable(value) |
   +-----------+-----------------------+
   | *Getter*  | get_selectable()      |
   +-----------+-----------------------+

If ``true``, the control allows text selection.

----

.. _class_TLRichTextEdit_property_paragraphs/{index}:

- :ref:`TLShapedParagraph<class_TLShapedParagraph>` **paragraphs/{index}**

Paragraphs of the text.

Method Descriptions
-------------------

.. _class_TLRichTextEdit_method_add_attribute:

- void **add_attribute** **(** :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` selection, int attribute, Variant value **)**

Sets ``attribute`` attribute to ``value`` for the selection.

----

.. _class_TLRichTextEdit_method_clear:

- void **clear** **(** **)**

Clears the attributes and sets text to an empty string.

----

.. _class_TLRichTextEdit_method_debug_draw:

- void **debug_draw** **(** RID rid, Vector2 position, Vector2 hit_position, bool draw_brk_ops, bool draw_jst_ops **)**

``DEBUG:`` Draws text with additional debug information.

----

.. _class_TLRichTextEdit_method_debug_draw_as_hex:

- void **debug_draw_as_hex** **(** RID rid, Vector2 position, Vector2 hit_position, bool draw_brk_ops, bool draw_jst_ops **)**

``DEBUG:`` Draws text using "hexbox" fallback font.

----

.. _class_TLRichTextEdit_method_debug_draw_logical_as_hex:

- void **debug_draw_logical_as_hex** **(** RID rid, Vector2 position, Vector2 hit_position, bool draw_brk_ops, bool draw_jst_ops **)**

``DEBUG:`` Draws logical character codes of the text with additional debug information.

----

.. _class_TLRichTextEdit_method_get_caret_position:

- Vector2 **get_caret_position** **(** **)**

Returns position of the caret, in (paragraph, offset) format.

----

.. _class_TLRichTextEdit_method_get_cluster_debug_info_hit_test:

- String **get_cluster_debug_info_hit_test** **(** Vector2 position **)**

``DEBUG:`` Returns cluster hit test info.

----

.. _class_TLRichTextEdit_method_get_cluster_glyphs_hit_test:

- Array **get_cluster_glyphs_hit_test** **(** Vector2 position **)**

Returns glyph hit test info.

----

.. _class_TLRichTextEdit_method_get_cluster_rect_hit_test:

- Rect2 **get_cluster_rect_hit_test** **(** Vector2 position **)**

Returns replacement object hit test info.

----

.. _class_TLRichTextEdit_method_get_paragraph:

- :ref:`TLShapedParagraph<class_TLShapedParagraph>` **get_paragraph** **(** int index **)** const

Returns paragraph of text.

----

.. _class_TLRichTextEdit_method_get_paragraphs:

- int **get_paragraphs** **(** **)**

Returns number of paragraph in the text.

----

.. _class_TLRichTextEdit_method_get_selection:

- :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` **get_selection** **(** **)** const

Returns current selection and caret position.

----

.. _class_TLRichTextEdit_method_insert_paragraph:

- int **insert_paragraph** **(** :ref:`TLShapedParagraph<class_TLShapedParagraph>` para, int index **)**

Inserts paragraph of text at the index position.

----

.. _class_TLRichTextEdit_method_remove_attribute:

- void **remove_attribute** **(** :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` selection, int attribute **)**

Returns ``attribute`` attribute value in the selection.

----

.. _class_TLRichTextEdit_method_remove_attributes:

- void **remove_attributes** **(** :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` selection **)**

Removes all attributes in the selection.

----

.. _class_TLRichTextEdit_method_remove_paragraph:

- void **remove_paragraph** **(** int index **)**

Removes paragraph of the text.

----

.. _class_TLRichTextEdit_method_replace_sstring:

- void **replace_sstring** **(** :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` selection, :ref:`TLShapedString<class_TLShapedString>` text **)**

Replaces selection with the shaped string.

----

.. _class_TLRichTextEdit_method_replace_text:

- void **replace_text** **(** :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` selection, String text **)**

Replaces selection with the plain string.

----

.. _class_TLRichTextEdit_method_replace_utf16:

- void **replace_utf16** **(** :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` selection, PoolByteArray text **)**

Replaces selection with the contents of the raw UTF-16 encoded string.

----

.. _class_TLRichTextEdit_method_replace_utf32:

- void **replace_utf32** **(** :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` selection, PoolByteArray text **)**

Replaces selection with the contents of the raw UTF-32 encoded string.

----

.. _class_TLRichTextEdit_method_replace_utf8:

- void **replace_utf8** **(** :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` selection, PoolByteArray text **)**

Replaces selection with the contents of the raw UTF-8 encoded string.

----

.. _class_TLRichTextEdit_method_set_paragraph:

- void **set_paragraph** **(** :ref:`TLShapedParagraph<class_TLShapedParagraph>` para, int index **)**

Sets content of the specific paragraph.

----

.. _class_TLRichTextEdit_method_set_paragraph_back_color:

- void **set_paragraph_back_color** **(** :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` selection, Color bcolor **)**

Sets background color of the paragraph.

----

.. _class_TLRichTextEdit_method_set_paragraph_brk_flags:

- void **set_paragraph_brk_flags** **(** :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` selection, int flags **)**

Sets line breaking flags of the paragraph.

----

.. _class_TLRichTextEdit_method_set_paragraph_halign:

- void **set_paragraph_halign** **(** :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` selection, int halign **)**

Sets horizontal alignment of the paragraph.

----

.. _class_TLRichTextEdit_method_set_paragraph_indent:

- void **set_paragraph_indent** **(** :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` selection, float indent **)**

Sets indentation of the paragraph.

----

.. _class_TLRichTextEdit_method_set_paragraph_jst_flags:

- void **set_paragraph_jst_flags** **(** :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` selection, int flags **)**

Sets justification flags of the paragraph.

----

.. _class_TLRichTextEdit_method_set_paragraph_line_spacing:

- void **set_paragraph_line_spacing** **(** :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` selection, float line_spacing **)**

Sets line spacing of the paragraph.

----

.. _class_TLRichTextEdit_method_set_paragraph_width:

- void **set_paragraph_width** **(** :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` selection, float width **)**

Sets max width of the paragraph.

----

.. _class_TLRichTextEdit_method_set_selection:

- void **set_selection** **(** :ref:`TLRichTextEditSelection<class_TLRichTextEditSelection>` selection **)**

Sets current selection.


text:
:github_url: hide

.. Generated automatically by doc/tools/makerst.py in Godot's source tree.
.. DO NOT EDIT THIS FILE, but the TLLabel.xml source instead.
.. The source is found in doc/classes or modules/<name>/doc_classes.

.. _class_TLLabel:

TLLabel
=======

**Inherits:**

**Category:** Core

Brief Description
-----------------

Displays plain text in a line or wrapped inside a rectangle. For formatted text, use :ref:`TLRichTextEdit<class_TLRichTextEdit>`.

Copy of Godot Label with the shaping support. TLLabel uses the same theme items as the Label.

Properties
----------

+-----------------------------------------+----------------------------------------------------------------------+-----------+
| int                                     | :ref:`align<class_TLLabel_property_align>`                           | 0         |
+-----------------------------------------+----------------------------------------------------------------------+-----------+
| bool                                    | :ref:`autowrap<class_TLLabel_property_autowrap>`                     | false     |
+-----------------------------------------+----------------------------------------------------------------------+-----------+
| :ref:`TLFontFamily<class_TLFontFamily>` | :ref:`base_font<class_TLLabel_property_base_font>`                   |           |
+-----------------------------------------+----------------------------------------------------------------------+-----------+
| int                                     | :ref:`base_font_size<class_TLLabel_property_base_font_size>`         | 12        |
+-----------------------------------------+----------------------------------------------------------------------+-----------+
| String                                  | :ref:`base_font_style<class_TLLabel_property_base_font_style>`       | "Regular" |
+-----------------------------------------+----------------------------------------------------------------------+-----------+
| bool                                    | :ref:`clip_text<class_TLLabel_property_clip_text>`                   | false     |
+-----------------------------------------+----------------------------------------------------------------------+-----------+
| String                                  | :ref:`language<class_TLLabel_property_language>`                     | ""        |
+-----------------------------------------+----------------------------------------------------------------------+-----------+
| int                                     | :ref:`lines_skipped<class_TLLabel_property_lines_skipped>`           | 0         |
+-----------------------------------------+----------------------------------------------------------------------+-----------+
| int                                     | :ref:`max_lines_visible<class_TLLabel_property_max_lines_visible>`   | -1        |
+-----------------------------------------+----------------------------------------------------------------------+-----------+
| int                                     | mouse_filter                                                         | **O:** 2  |
+-----------------------------------------+----------------------------------------------------------------------+-----------+
| String                                  | :ref:`ot_features<class_TLLabel_property_ot_features>`               | ""        |
+-----------------------------------------+----------------------------------------------------------------------+-----------+
| float                                   | :ref:`percent_visible<class_TLLabel_property_percent_visible>`       | 1.0       |
+-----------------------------------------+----------------------------------------------------------------------+-----------+
| int                                     | size_flags_vertical                                                  | **O:** 4  |
+-----------------------------------------+----------------------------------------------------------------------+-----------+
| String                                  | :ref:`text<class_TLLabel_property_text>`                             | ""        |
+-----------------------------------------+----------------------------------------------------------------------+-----------+
| int                                     | :ref:`text_direction<class_TLLabel_property_text_direction>`         | 3         |
+-----------------------------------------+----------------------------------------------------------------------+-----------+
| bool                                    | :ref:`uppercase<class_TLLabel_property_uppercase>`                   | false     |
+-----------------------------------------+----------------------------------------------------------------------+-----------+
| int                                     | :ref:`valign<class_TLLabel_property_valign>`                         | 0         |
+-----------------------------------------+----------------------------------------------------------------------+-----------+
| int                                     | :ref:`visible_characters<class_TLLabel_property_visible_characters>` | -1        |
+-----------------------------------------+----------------------------------------------------------------------+-----------+

Methods
-------

.. table::
   :class: longtable
   :widths: 7 20

   +-----+----------------------------------------------------------------------------------------------------+
   | int | :ref:`get_line_count<class_TLLabel_method_get_line_count>` **(** **)** const                       |
   +-----+----------------------------------------------------------------------------------------------------+
   | int | :ref:`get_line_height<class_TLLabel_method_get_line_height>` **(** **)** const                     |
   +-----+----------------------------------------------------------------------------------------------------+
   | int | :ref:`get_total_character_count<class_TLLabel_method_get_total_character_count>` **(** **)** const |
   +-----+----------------------------------------------------------------------------------------------------+
   | int | :ref:`get_visible_line_count<class_TLLabel_method_get_visible_line_count>` **(** **)** const       |
   +-----+----------------------------------------------------------------------------------------------------+

Enumerations
------------

.. _enum_TLLabel_Align:

.. _class_TLLabel_constant_ALIGN_LEFT:

.. _class_TLLabel_constant_ALIGN_CENTER:

.. _class_TLLabel_constant_ALIGN_RIGHT:

.. _class_TLLabel_constant_ALIGN_FILL:

enum **Align**:

- **ALIGN_LEFT** = **0** --- Align rows to the left (default).

- **ALIGN_CENTER** = **1** --- Align rows centered.

- **ALIGN_RIGHT** = **2** --- Align rows to the right.

- **ALIGN_FILL** = **3** --- Expand row white spaces to fit the width.

----

.. _enum_TLLabel_VAlign:

.. _class_TLLabel_constant_VALIGN_TOP:

.. _class_TLLabel_constant_VALIGN_CENTER:

.. _class_TLLabel_constant_VALIGN_BOTTOM:

.. _class_TLLabel_constant_VALIGN_FILL:

enum **VAlign**:

- **VALIGN_TOP** = **0** --- Align the whole text to the top.

- **VALIGN_CENTER** = **1** --- Align the whole text to the center.

- **VALIGN_BOTTOM** = **2** --- Align the whole text to the bottom.

- **VALIGN_FILL** = **3** --- Align the whole text by spreading the rows.

Description
-----------

Label displays plain text on the screen. It gives you control over the horizontal and vertical alignment, and can wrap the text inside the node's bounding rectangle. It doesn't support bold, italics or other formatting. For that, use RichTextLabel instead.

Property Descriptions
---------------------

.. _class_TLLabel_property_align:

- int **align**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+------------------+
   | *Default* | 0                |
   +-----------+------------------+
   | *Setter*  | set_align(value) |
   +-----------+------------------+
   | *Getter*  | get_align()      |
   +-----------+------------------+

Controls the text's horizontal align. Supports left, center, right, and fill, or justify. Set it to one of the ``ALIGN_*`` constants.

----

.. _class_TLLabel_property_autowrap:

- bool **autowrap**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+---------------------+
   | *Default* | false               |
   +-----------+---------------------+
   | *Setter*  | set_autowrap(value) |
   +-----------+---------------------+
   | *Getter*  | has_autowrap()      |
   +-----------+---------------------+

If ``true``, wraps the text inside the node's bounding rectangle. If you resize the node, it will change its height automatically to show all the text.

----

.. _class_TLLabel_property_base_font:

- :ref:`TLFontFamily<class_TLFontFamily>` **base_font**

.. table::
   :class: longtable
   :widths: 7 20

   +----------+----------------------+
   | *Setter* | set_base_font(value) |
   +----------+----------------------+
   | *Getter* | get_base_font()      |
   +----------+----------------------+

Base font.

----

.. _class_TLLabel_property_base_font_size:

- int **base_font_size**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+---------------------------+
   | *Default* | 12                        |
   +-----------+---------------------------+
   | *Setter*  | set_base_font_size(value) |
   +-----------+---------------------------+
   | *Getter*  | get_base_font_size()      |
   +-----------+---------------------------+

Base font size.

----

.. _class_TLLabel_property_base_font_style:

- String **base_font_style**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+----------------------------+
   | *Default* | "Regular"                  |
   +-----------+----------------------------+
   | *Setter*  | set_base_font_style(value) |
   +-----------+----------------------------+
   | *Getter*  | get_base_font_style()      |
   +-----------+----------------------------+

Base font style.

----

.. _class_TLLabel_property_clip_text:

- bool **clip_text**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+----------------------+
   | *Default* | false                |
   +-----------+----------------------+
   | *Setter*  | set_clip_text(value) |
   +-----------+----------------------+
   | *Getter*  | is_clipping_text()   |
   +-----------+----------------------+

If ``true``, the Label only shows the text that fits inside its bounding rectangle. It also lets you scale the node down freely.

----

.. _class_TLLabel_property_language:

- String **language**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+---------------------+
   | *Default* | ""                  |
   +-----------+---------------------+
   | *Setter*  | set_language(value) |
   +-----------+---------------------+
   | *Getter*  | get_language()      |
   +-----------+---------------------+

Language code for line-breaking and text shaping algorithms.

----

.. _class_TLLabel_property_lines_skipped:

- int **lines_skipped**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+--------------------------+
   | *Default* | 0                        |
   +-----------+--------------------------+
   | *Setter*  | set_lines_skipped(value) |
   +-----------+--------------------------+
   | *Getter*  | get_lines_skipped()      |
   +-----------+--------------------------+

The node ignores the first ``lines_skipped`` lines before it starts to display text.

----

.. _class_TLLabel_property_max_lines_visible:

- int **max_lines_visible**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+------------------------------+
   | *Default* | -1                           |
   +-----------+------------------------------+
   | *Setter*  | set_max_lines_visible(value) |
   +-----------+------------------------------+
   | *Getter*  | get_max_lines_visible()      |
   +-----------+------------------------------+

Limits the lines of text the node shows on screen.

----

.. _class_TLLabel_property_ot_features:

- String **ot_features**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+------------------------+
   | *Default* | ""                     |
   +-----------+------------------------+
   | *Setter*  | set_ot_features(value) |
   +-----------+------------------------+
   | *Getter*  | get_ot_features()      |
   +-----------+------------------------+

Comma separated list of OpenType feature tags.

----

.. _class_TLLabel_property_percent_visible:

- float **percent_visible**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+----------------------------+
   | *Default* | 1.0                        |
   +-----------+----------------------------+
   | *Setter*  | set_percent_visible(value) |
   +-----------+----------------------------+
   | *Getter*  | get_percent_visible()      |
   +-----------+----------------------------+

Limits the count of visible characters. If you set ``percent_visible`` to 50, only up to half of the text's characters will display on screen. Useful to animate the text in a dialog box.

----

.. _class_TLLabel_property_text:

- String **text**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+-----------------+
   | *Default* | ""              |
   +-----------+-----------------+
   | *Setter*  | set_text(value) |
   +-----------+-----------------+
   | *Getter*  | get_text()      |
   +-----------+-----------------+

The text to display on screen.

----

.. _class_TLLabel_property_text_direction:

- int **text_direction**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+---------------------------+
   | *Default* | 3                         |
   +-----------+---------------------------+
   | *Setter*  | set_text_direction(value) |
   +-----------+---------------------------+
   | *Getter*  | get_text_direction()      |
   +-----------+---------------------------+

Base direction of the text.

----

.. _class_TLLabel_property_uppercase:

- bool **uppercase**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+----------------------+
   | *Default* | false                |
   +-----------+----------------------+
   | *Setter*  | set_uppercase(value) |
   +-----------+----------------------+
   | *Getter*  | is_uppercase()       |
   +-----------+----------------------+

If ``true``, all the text displays as UPPERCASE.

----

.. _class_TLLabel_property_valign:

- int **valign**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+-------------------+
   | *Default* | 0                 |
   +-----------+-------------------+
   | *Setter*  | set_valign(value) |
   +-----------+-------------------+
   | *Getter*  | get_valign()      |
   +-----------+-------------------+

Controls the text's vertical align. Supports top, center, bottom, and fill. Set it to one of the ``VALIGN_*`` constants.

----

.. _class_TLLabel_property_visible_characters:

- int **visible_characters**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+-------------------------------+
   | *Default* | -1                            |
   +-----------+-------------------------------+
   | *Setter*  | set_visible_characters(value) |
   +-----------+-------------------------------+
   | *Getter*  | get_visible_characters()      |
   +-----------+-------------------------------+

Restricts the number of characters to display. Set to -1 to disable.

Method Descriptions
-------------------

.. _class_TLLabel_method_get_line_count:

- int **get_line_count** **(** **)** const

Returns the amount of lines of text the Label has.

----

.. _class_TLLabel_method_get_line_height:

- int **get_line_height** **(** **)** const

Returns the of the line in pixels.

----

.. _class_TLLabel_method_get_total_character_count:

- int **get_total_character_count** **(** **)** const

Returns the total number of printable characters in the text.

----

.. _class_TLLabel_method_get_visible_line_count:

- int **get_visible_line_count** **(** **)** const

Returns the number of lines shown. Useful if the Label's height cannot currently display all lines.

repo_language: C

mime_type: text/x-c


text:
:github_url: hide

.. Generated automatically by doc/tools/makerst.py in Godot's source tree.
.. DO NOT EDIT THIS FILE, but the TLShapedAttributedString.xml source instead.
.. The source is found in doc/classes or modules/<name>/doc_classes.

.. _class_TLShapedAttributedString:

TLShapedAttributedString
========================

**Inherits:** :ref:`TLShapedString<class_TLShapedString>`

**Category:** Core

Brief Description
-----------------

Golds shaped line of text with associated attributes.

Properties
----------

+---------+---------------------------------------------------------------------------------+
| Array   | :ref:`attributes_dict<class_TLShapedAttributedString_property_attributes_dict>` |
+---------+---------------------------------------------------------------------------------+
| int     | :ref:`attribute/type<class_TLShapedAttributedString_property_attribute/type>`   |
+---------+---------------------------------------------------------------------------------+
| Variant | :ref:`attribute/value<class_TLShapedAttributedString_property_attribute/value>` |
+---------+---------------------------------------------------------------------------------+
| int     | :ref:`attribute/start<class_TLShapedAttributedString_property_attribute/start>` |
+---------+---------------------------------------------------------------------------------+
| int     | :ref:`attribute/end<class_TLShapedAttributedString_property_attribute/end>`     |
+---------+---------------------------------------------------------------------------------+

Methods
-------

.. table::
   :class: longtable
   :widths: 7 20

   +---------+----------------------------------------------------------------------------------------------------------------------------------------+
   | void    | :ref:`add_attribute<class_TLShapedAttributedString_method_add_attribute>` **(** int attribute, Variant value, int start, int end **)** |
   +---------+----------------------------------------------------------------------------------------------------------------------------------------+
   | void    | :ref:`clear_attributes<class_TLShapedAttributedString_method_clear_attributes>` **(** **)**                                            |
   +---------+----------------------------------------------------------------------------------------------------------------------------------------+
   | void    | :ref:`commit_attribute<class_TLShapedAttributedString_method_commit_attribute>` **(** **)**                                            |
   +---------+----------------------------------------------------------------------------------------------------------------------------------------+
   | Variant | :ref:`get_attribute<class_TLShapedAttributedString_method_get_attribute>` **(** int attribute, int index **)** const                   |
   +---------+----------------------------------------------------------------------------------------------------------------------------------------+
   | int     | :ref:`get_attribute_end<class_TLShapedAttributedString_method_get_attribute_end>` **(** int attribute, int index **)** const           |
   +---------+----------------------------------------------------------------------------------------------------------------------------------------+
   | int     | :ref:`get_attribute_start<class_TLShapedAttributedString_method_get_attribute_start>` **(** int attribute, int index **)** const       |
   +---------+----------------------------------------------------------------------------------------------------------------------------------------+
   | Array   | :ref:`get_embedded_rects<class_TLShapedAttributedString_method_get_embedded_rects>` **(** **)**                                        |
   +---------+----------------------------------------------------------------------------------------------------------------------------------------+
   | bool    | :ref:`has_attribute<class_TLShapedAttributedString_method_has_attribute>` **(** int attribute, int index **)** const                   |
   +---------+----------------------------------------------------------------------------------------------------------------------------------------+
   | void    | :ref:`load_attributes_dict<class_TLShapedAttributedString_method_load_attributes_dict>` **(** Array array **)**                        |
   +---------+----------------------------------------------------------------------------------------------------------------------------------------+
   | void    | :ref:`remove_attribute<class_TLShapedAttributedString_method_remove_attribute>` **(** int attribute, int start, int end **)**          |
   +---------+----------------------------------------------------------------------------------------------------------------------------------------+
   | void    | :ref:`remove_attributes<class_TLShapedAttributedString_method_remove_attributes>` **(** int start, int end **)**                       |
   +---------+----------------------------------------------------------------------------------------------------------------------------------------+
   | Array   | :ref:`save_attributes_dict<class_TLShapedAttributedString_method_save_attributes_dict>` **(** **)** const                              |
   +---------+----------------------------------------------------------------------------------------------------------------------------------------+

Enumerations
------------

.. _enum_TLShapedAttributedString_TextAttribute:

.. _class_TLShapedAttributedString_constant_TEXT_ATTRIBUTE_FONT:

.. _class_TLShapedAttributedString_constant_TEXT_ATTRIBUTE_FONT_STYLE:

.. _class_TLShapedAttributedString_constant_TEXT_ATTRIBUTE_FONT_SIZE:

.. _class_TLShapedAttributedString_constant_TEXT_ATTRIBUTE_FONT_FEATURES:

.. _class_TLShapedAttributedString_constant_TEXT_ATTRIBUTE_LANGUAGE:

.. _class_TLShapedAttributedString_constant_TEXT_ATTRIBUTE_REPLACEMENT_IMAGE:

.. _class_TLShapedAttributedString_constant_TEXT_ATTRIBUTE_REPLACEMENT_RECT:

.. _class_TLShapedAttributedString_constant_TEXT_ATTRIBUTE_REPLACEMENT_ID:

.. _class_TLShapedAttributedString_constant_TEXT_ATTRIBUTE_REPLACEMENT_VALIGN:

.. _class_TLShapedAttributedString_constant_TEXT_ATTRIBUTE_COLOR:

.. _class_TLShapedAttributedString_constant_TEXT_ATTRIBUTE_OUTLINE_COLOR:

.. _class_TLShapedAttributedString_constant_TEXT_ATTRIBUTE_UNDERLINE_COLOR:

.. _class_TLShapedAttributedString_constant_TEXT_ATTRIBUTE_UNDERLINE_WIDTH:

.. _class_TLShapedAttributedString_constant_TEXT_ATTRIBUTE_STRIKETHROUGH_COLOR:

.. _class_TLShapedAttributedString_constant_TEXT_ATTRIBUTE_STRIKETHROUGH_WIDTH:

.. _class_TLShapedAttributedString_constant_TEXT_ATTRIBUTE_OVERLINE_COLOR:

.. _class_TLShapedAttributedString_constant_TEXT_ATTRIBUTE_OVERLINE_WIDTH:

.. _class_TLShapedAttributedString_constant_TEXT_ATTRIBUTE_HIGHLIGHT_COLOR:

.. _class_TLShapedAttributedString_constant_TEXT_ATTRIBUTE_META:

enum **TextAttribute**:

- **TEXT_ATTRIBUTE_FONT** = **1** --- Font family. Attribute type: :ref:`TLFontFamily<class_TLFontFamily>`

- **TEXT_ATTRIBUTE_FONT_STYLE** = **2** --- Font style (Regular, Bold, Italic, Oblique etc.). Attribute type: String

- **TEXT_ATTRIBUTE_FONT_SIZE** = **3** --- Font size. Attribute type: ``int``

- **TEXT_ATTRIBUTE_FONT_FEATURES** = **4** --- Comma separated list of OpenType feature tags. More info: https://docs.microsoft.com/en-us/typography/opentype/spec/featuretags. Attribute type: String

- **TEXT_ATTRIBUTE_LANGUAGE** = **5** --- Language code for line-breaking and text shaping algorithms. Attribute type: String

- **TEXT_ATTRIBUTE_REPLACEMENT_IMAGE** = **6** --- Embedded image. Attribute type: Texture

- **TEXT_ATTRIBUTE_REPLACEMENT_RECT** = **7** --- Reserved space for custom embedded object. Attribute type: Vector2

- **TEXT_ATTRIBUTE_REPLACEMENT_ID** = **8** --- Embedded object id key. Attribute type: Variant

- **TEXT_ATTRIBUTE_REPLACEMENT_VALIGN** = **9** --- Embedded image/object inline alignment. Attribute type: ``TEXT_VALIGN_*``

- **TEXT_ATTRIBUTE_COLOR** = **31** --- Text color. Attribute type: Color

- **TEXT_ATTRIBUTE_OUTLINE_COLOR** = **32** --- Text outline color. Attribute type: Color

- **TEXT_ATTRIBUTE_UNDERLINE_COLOR** = **41** --- Underline color. Attribute type: Color

- **TEXT_ATTRIBUTE_UNDERLINE_WIDTH** = **42** --- Underline width. Attribute type: ``int``

- **TEXT_ATTRIBUTE_STRIKETHROUGH_COLOR** = **51** --- Strike through line color. Attribute type: Color

- **TEXT_ATTRIBUTE_STRIKETHROUGH_WIDTH** = **52** --- Strike through line width. Attribute type: ``int``

- **TEXT_ATTRIBUTE_OVERLINE_COLOR** = **61** --- Overline color/ Attribute type: Color

- **TEXT_ATTRIBUTE_OVERLINE_WIDTH** = **62** --- Overline width. Attribute type: ``int``

- **TEXT_ATTRIBUTE_HIGHLIGHT_COLOR** = **71** --- Highlight color. Attribute type: Color

- **TEXT_ATTRIBUTE_META** = **100** --- User defined data, use ``TEXT_ATTRIBUTE_META + x`` to define multiple user attributes. Attribute type: Variant

----

.. _enum_TLShapedAttributedString_TextVAlign:

.. _class_TLShapedAttributedString_constant_TEXT_VALIGN_TOP:

.. _class_TLShapedAttributedString_constant_TEXT_VALIGN_CENTER:

.. _class_TLShapedAttributedString_constant_TEXT_VALIGN_BOTTOM:

enum **TextVAlign**:

- **TEXT_VALIGN_TOP** = **0** --- Inline vertical top alignment.

- **TEXT_VALIGN_CENTER** = **1** --- Inline vertical center alignment.

- **TEXT_VALIGN_BOTTOM** = **2** --- Inline vertical bottom alignment.

Property Descriptions
---------------------

.. _class_TLShapedAttributedString_property_attributes_dict:

- Array **attributes_dict**

.. table::
   :class: longtable
   :widths: 7 20

   +----------+-----------------------------+
   | *Setter* | load_attributes_dict(value) |
   +----------+-----------------------------+
   | *Getter* | save_attributes_dict()      |
   +----------+-----------------------------+

Array of attribute Dictionary.

----

.. _class_TLShapedAttributedString_property_attribute/type:

- int **attribute/type**

Temporary attribute type, temporary attributes can be committed to the string by calling :ref:`commit_attribute<class_TLShapedAttributedString_method_commit_attribute>`.

----

.. _class_TLShapedAttributedString_property_attribute/value:

- Variant **attribute/value**

Temporary attribute value, temporary attributes can be committed to the string by calling :ref:`commit_attribute<class_TLShapedAttributedString_method_commit_attribute>`.

----

.. _class_TLShapedAttributedString_property_attribute/start:

- int **attribute/start**

Temporary attribute start offset, temporary attributes can be committed to the string by calling :ref:`commit_attribute<class_TLShapedAttributedString_method_commit_attribute>`.

----

.. _class_TLShapedAttributedString_property_attribute/end:

- int **attribute/end**

Temporary attribute end offset, temporary attributes can be committed to the string by calling :ref:`commit_attribute<class_TLShapedAttributedString_method_commit_attribute>`.

Method Descriptions
-------------------

.. _class_TLShapedAttributedString_method_add_attribute:

- void **add_attribute** **(** int attribute, Variant value, int start, int end **)**

Sets ``attribute`` attribute to ``value`` for specified text range.

----

.. _class_TLShapedAttributedString_method_clear_attributes:

- void **clear_attributes** **(** **)**

Removes all attributes.

----

.. _class_TLShapedAttributedString_method_commit_attribute:

- void **commit_attribute** **(** **)**

----

.. _class_TLShapedAttributedString_method_get_attribute:

- Variant **get_attribute** **(** int attribute, int index **)** const

Returns ``attribute`` attribute value for specified text position.

----

.. _class_TLShapedAttributedString_method_get_attribute_end:

- int **get_attribute_end** **(** int attribute, int index **)** const

Returns last position of ``attribute`` attribute run enclosing specified position.

----

.. _class_TLShapedAttributedString_method_get_attribute_start:

- int **get_attribute_start** **(** int attribute, int index **)** const

Returns first position of ``attribute`` attribute run enclosing specified position.

----

.. _class_TLShapedAttributedString_method_get_embedded_rects:

- Array **get_embedded_rects** **(** **)**

Returns bounding rectangles of embedded objects (``TEXT_ATTRIBUTE_REPLACEMENT_RECT`` attributes).

----

.. _class_TLShapedAttributedString_method_has_attribute:

- bool **has_attribute** **(** int attribute, int index **)** const

Returns ``true`` if specified position has ``attribute`` attribute set.

----

.. _class_TLShapedAttributedString_method_load_attributes_dict:

- void **load_attributes_dict** **(** Array array **)**

Loads attributes from Array of Dictionary.

----

.. _class_TLShapedAttributedString_method_remove_attribute:

- void **remove_attribute** **(** int attribute, int start, int end **)**

Removes ``attribute`` attribute for specified text range.

----

.. _class_TLShapedAttributedString_method_remove_attributes:

- void **remove_attributes** **(** int start, int end **)**

Removes all attributes for specified text range.

----

.. _class_TLShapedAttributedString_method_save_attributes_dict:

- Array **save_attributes_dict** **(** **)** const

Stores string attributes into Array of Dictionary.


text:
:github_url: hide

.. Generated automatically by doc/tools/makerst.py in Godot's source tree.
.. DO NOT EDIT THIS FILE, but the TLFontFace.xml source instead.
.. The source is found in doc/classes or modules/<name>/doc_classes.

.. _class_TLFontFace:

TLFontFace
==========

**Inherits:**

**Inherited By:** :ref:`TLBitmapFontFace<class_TLBitmapFontFace>`, :ref:`TLDynamicFontFace<class_TLDynamicFontFace>`

**Category:** Core

Brief Description
-----------------

\*Virtual class\*

A base font face class.

Properties
----------

+--------+---------------------------------------------------------------+----+
| String | :ref:`font_path<class_TLFontFace_property_font_path>`         | "" |
+--------+---------------------------------------------------------------+----+
| int    | :ref:`texture_flags<class_TLFontFace_property_texture_flags>` | 0  |
+--------+---------------------------------------------------------------+----+

Methods
-------

.. table::
   :class: longtable
   :widths: 7 20

   +-------+---------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | void  | :ref:`draw_glyph<class_TLFontFace_method_draw_glyph>` **(** RID canvas_item, Vector2 pos, int codepoint, Color modulate, int size **)** const                 |
   +-------+---------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | void  | :ref:`draw_glyph_outline<class_TLFontFace_method_draw_glyph_outline>` **(** RID canvas_item, Vector2 pos, int codepoint, Color modulate, int size **)** const |
   +-------+---------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | float | :ref:`get_ascent<class_TLFontFace_method_get_ascent>` **(** int size **)** const                                                                              |
   +-------+---------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | int   | :ref:`get_base_size<class_TLFontFace_method_get_base_size>` **(** **)** const                                                                                |
   +-------+---------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | float | :ref:`get_descent<class_TLFontFace_method_get_descent>` **(** int size **)** const                                                                            |
   +-------+---------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | Array | :ref:`get_glyph_outline<class_TLFontFace_method_get_glyph_outline>` **(** Vector2 pos, int codepoint, int size **)** const                                    |
   +-------+---------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | float | :ref:`get_height<class_TLFontFace_method_get_height>` **(** int size **)** const                                                                              |
   +-------+---------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | bool  | :ref:`load<class_TLFontFace_method_load>` **(** String resource_path **)**                                                                                |
   +-------+---------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | Array | :ref:`unicode_scripts_supported<class_TLFontFace_method_unicode_scripts_supported>` **(** **)** const                                                         |
   +-------+---------------------------------------------------------------------------------------------------------------------------------------------------------------+

Property Descriptions
---------------------

.. _class_TLFontFace_property_font_path:

- String **font_path**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+----------------------+
   | *Default* | ""                   |
   +-----------+----------------------+
   | *Setter*  | set_font_path(value) |
   +-----------+----------------------+
   | *Getter*  | get_font_path()      |
   +-----------+----------------------+

Path of the font file.

----

.. _class_TLFontFace_property_texture_flags:

- int **texture_flags**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+--------------------------+
   | *Default* | 0                        |
   +-----------+--------------------------+
   | *Setter*  | set_texture_flags(value) |
   +-----------+--------------------------+
   | *Getter*  | get_texture_flags()      |
   +-----------+--------------------------+

Underlaying textures flags, see Texture class documentation https://docs.godotengine.org/en/latest/classes/class_texture.html#enumerations for more info.

Method Descriptions
-------------------

.. _class_TLFontFace_method_draw_glyph:

- void **draw_glyph** **(** RID canvas_item, Vector2 pos, int codepoint, Color modulate, int size **)** const

Draws a single glyph.

----

.. _class_TLFontFace_method_draw_glyph_outline:

- void **draw_glyph_outline** **(** RID canvas_item, Vector2 pos, int codepoint, Color modulate, int size **)** const

Draws single glyph outline.

----

.. _class_TLFontFace_method_get_ascent:

- float **get_ascent** **(** int size **)** const

Returns ascent (distance from the baseline to the highest position characters extend to) of the font.

----

.. _class_TLFontFace_method_get_base_size:

- int **get_base_size** **(** **)** const

Returns default font size for bitmap fonts or ``0`` for dynamic fonts.

----

.. _class_TLFontFace_method_get_descent:

- float **get_descent** **(** int size **)** const

Returns descent (distance from the base line to the lowest point characters extend to) of the font.

----

.. _class_TLFontFace_method_get_glyph_outline:

- Array **get_glyph_outline** **(** Vector2 pos, int codepoint, int size **)** const

Returns array of glyph counture points, if it's supported by font implementation or empty array otherwise.

----

.. _class_TLFontFace_method_get_height:

- float **get_height** **(** int size **)** const

Returns height (vertical distance between two consecutive baselines) of the font.

----

.. _class_TLFontFace_method_load:

- bool **load** **(** String resource_path **)**

Loads font from speified file.

----

.. _class_TLFontFace_method_unicode_scripts_supported:

- Array **unicode_scripts_supported** **(** **)** const

Returns array of supported ISO 15924 script codes.


text:
libgdtl API
===========

.. toctree::
   :maxdepth: 1
   :name: toc-class-ref
   :glob:

   class_*


text:
:github_url: hide

.. Generated automatically by doc/tools/makerst.py in Godot's source tree.
.. DO NOT EDIT THIS FILE, but the TLBitmapFontFace.xml source instead.
.. The source is found in doc/classes or modules/<name>/doc_classes.

.. _class_TLBitmapFontFace:

TLBitmapFontFace
================

**Inherits:** :ref:`TLFontFace<class_TLFontFace>`

**Category:** Core

Brief Description
-----------------

An AngelCode Bitmap Font Generator bitmap font for drawing text.

Properties
----------

+-----+---------------+-------------+
| int | texture_flags | **O:** 2048 |
+-----+---------------+-------------+

Description
-----------

TLBitmapFontFace have limited shaping support.

TLBitmapFontFace doesn't support OpenType features.


text:
:github_url: hide

.. Generated automatically by doc/tools/makerst.py in Godot's source tree.
.. DO NOT EDIT THIS FILE, but the TLICUDataLoader.xml source instead.
.. The source is found in doc/classes or modules/<name>/doc_classes.

.. _class_TLICUDataLoader:

TLICUDataLoader
===============

**Inherits:**

**Category:** Core

Brief Description
-----------------

Helper class that handles ICU data loading.

Properties
----------

+--------+------------------------------------------------------------+----+
| String | :ref:`data_path<class_TLICUDataLoader_property_data_path>` | "" |
+--------+------------------------------------------------------------+----+

Methods
-------

.. table::
   :class: longtable
   :widths: 7 20

   +------+---------------------------------------------------------------------------------+
   | bool | :ref:`load<class_TLICUDataLoader_method_load>` **(** String resource_path **)** |
   +------+---------------------------------------------------------------------------------+

Property Descriptions
---------------------

.. _class_TLICUDataLoader_property_data_path:

- String **data_path**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+----------------------+
   | *Default* | ""                   |
   +-----------+----------------------+
   | *Setter*  | set_data_path(value) |
   +-----------+----------------------+
   | *Getter*  | get_data_path()      |
   +-----------+----------------------+

ICU data file path.

Method Descriptions
-------------------

.. _class_TLICUDataLoader_method_load:

- bool **load** **(** String resource_path **)**

Loads ICU data file, should be done at most once in a process, before the first ICU operation. Returns ``true`` if function succeeds.


text:
:github_url: hide

.. Generated automatically by doc/tools/makerst.py in Godot's source tree.
.. DO NOT EDIT THIS FILE, but the TLLineEdit.xml source instead.
.. The source is found in doc/classes or modules/<name>/doc_classes.

.. _class_TLLineEdit:

TLLineEdit
==========

**Inherits:**

**Category:** Core

Brief Description
-----------------

Control that provides single-line string editing. For formatted or/and multiline text, use :ref:`TLRichTextEdit<class_TLRichTextEdit>`.

Copy of Godot LineEdit with the shaping support. TLLineEdit uses the same theme items as the LineEdit.

Properties
----------

+-----------------------------------------+-------------------------------------------------------------------------------+-----------+
| int                                     | :ref:`align<class_TLLineEdit_property_align>`                                 | 0         |
+-----------------------------------------+-------------------------------------------------------------------------------+-----------+
| :ref:`TLFontFamily<class_TLFontFamily>` | :ref:`base_font<class_TLLineEdit_property_base_font>`                         |           |
+-----------------------------------------+-------------------------------------------------------------------------------+-----------+
| int                                     | :ref:`base_font_size<class_TLLineEdit_property_base_font_size>`               | 12        |
+-----------------------------------------+-------------------------------------------------------------------------------+-----------+
| String                                  | :ref:`base_font_style<class_TLLineEdit_property_base_font_style>`             | "Regular" |
+-----------------------------------------+-------------------------------------------------------------------------------+-----------+
| bool                                    | :ref:`caret_blink<class_TLLineEdit_property_caret_blink>`                     | false     |
+-----------------------------------------+-------------------------------------------------------------------------------+-----------+
| float                                   | :ref:`caret_blink_speed<class_TLLineEdit_property_caret_blink_speed>`         | 0.65      |
+-----------------------------------------+-------------------------------------------------------------------------------+-----------+
| int                                     | :ref:`caret_position<class_TLLineEdit_property_caret_position>`               | 0         |
+-----------------------------------------+-------------------------------------------------------------------------------+-----------+
| bool                                    | :ref:`clear_button_enabled<class_TLLineEdit_property_clear_button_enabled>`   | false     |
+-----------------------------------------+-------------------------------------------------------------------------------+-----------+
| bool                                    | :ref:`context_menu_enabled<class_TLLineEdit_property_context_menu_enabled>`   | true      |
+-----------------------------------------+-------------------------------------------------------------------------------+-----------+
| bool                                    | :ref:`editable<class_TLLineEdit_property_editable>`                           | true      |
+-----------------------------------------+-------------------------------------------------------------------------------+-----------+
| bool                                    | :ref:`expand_to_text_length<class_TLLineEdit_property_expand_to_text_length>` | false     |
+-----------------------------------------+-------------------------------------------------------------------------------+-----------+
| int                                     | focus_mode                                                                    | **O:** 2  |
+-----------------------------------------+-------------------------------------------------------------------------------+-----------+
| String                                  | :ref:`language<class_TLLineEdit_property_language>`                           | ""        |
+-----------------------------------------+-------------------------------------------------------------------------------+-----------+
| int                                     | :ref:`max_length<class_TLLineEdit_property_max_length>`                       | 0         |
+-----------------------------------------+-------------------------------------------------------------------------------+-----------+
| Control.CursorShape                     | mouse_default_cursor_shape                                                    | **O:** 1  |
+-----------------------------------------+-------------------------------------------------------------------------------+-----------+
| String                                  | :ref:`ot_features<class_TLLineEdit_property_ot_features>`                     | ""        |
+-----------------------------------------+-------------------------------------------------------------------------------+-----------+
| float                                   | :ref:`placeholder_alpha<class_TLLineEdit_property_placeholder_alpha>`         | 0.6       |
+-----------------------------------------+-------------------------------------------------------------------------------+-----------+
| String                                  | :ref:`placeholder_text<class_TLLineEdit_property_placeholder_text>`           | ""        |
+-----------------------------------------+-------------------------------------------------------------------------------+-----------+
| bool                                    | :ref:`secret<class_TLLineEdit_property_secret>`                               | false     |
+-----------------------------------------+-------------------------------------------------------------------------------+-----------+
| String                                  | :ref:`secret_character<class_TLLineEdit_property_secret_character>`           | "*"       |
+-----------------------------------------+-------------------------------------------------------------------------------+-----------+
| String                                  | :ref:`text<class_TLLineEdit_property_text>`                                   | ""        |
+-----------------------------------------+-------------------------------------------------------------------------------+-----------+
| int                                     | :ref:`text_direction<class_TLLineEdit_property_text_direction>`               | 3         |
+-----------------------------------------+-------------------------------------------------------------------------------+-----------+

Methods
-------

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+-------------------------------------------------------------------------------------------+
   | void      | :ref:`append_at_cursor<class_TLLineEdit_method_append_at_cursor>` **(** String text **)** |
   +-----------+-------------------------------------------------------------------------------------------+
   | void      | :ref:`clear<class_TLLineEdit_method_clear>` **(** **)**                                   |
   +-----------+-------------------------------------------------------------------------------------------+
   | void      | :ref:`deselect<class_TLLineEdit_method_deselect>` **(** **)**                             |
   +-----------+-------------------------------------------------------------------------------------------+
   | PopupMenu | :ref:`get_menu<class_TLLineEdit_method_get_menu>` **(** **)** const                       |
   +-----------+-------------------------------------------------------------------------------------------+
   | void      | :ref:`menu_option<class_TLLineEdit_method_menu_option>` **(** int option **)**            |
   +-----------+-------------------------------------------------------------------------------------------+
   | void      | :ref:`select<class_TLLineEdit_method_select>` **(** int from=0, int to=-1 **)**           |
   +-----------+-------------------------------------------------------------------------------------------+
   | void      | :ref:`select_all<class_TLLineEdit_method_select_all>` **(** **)**                         |
   +-----------+-------------------------------------------------------------------------------------------+

Signals
-------

.. _class_TLLineEdit_signal_text_changed:

- **text_changed** **(** String new_text **)**

Emitted when the text changes.

----

.. _class_TLLineEdit_signal_text_entered:

- **text_entered** **(** String new_text **)**

Emitted when the user presses ``KEY_ENTER`` on the ``TLLineEdit``.

Enumerations
------------

.. _enum_TLLineEdit_Align:

.. _class_TLLineEdit_constant_ALIGN_LEFT:

.. _class_TLLineEdit_constant_ALIGN_CENTER:

.. _class_TLLineEdit_constant_ALIGN_RIGHT:

.. _class_TLLineEdit_constant_ALIGN_FILL:

enum **Align**:

- **ALIGN_LEFT** = **0** --- Aligns the text on the left-hand side of the ``TLLineEdit``.

- **ALIGN_CENTER** = **1** --- Centers the text in the middle of the ``TLLineEdit``.

- **ALIGN_RIGHT** = **2** --- Aligns the text on the right-hand side of the ``TLLineEdit``.

- **ALIGN_FILL** = **3** --- Stretches white spaces to fit the ``TLLineEdit``'s width.

----

.. _enum_TLLineEdit_MenuItems:

.. _class_TLLineEdit_constant_MENU_CUT:

.. _class_TLLineEdit_constant_MENU_COPY:

.. _class_TLLineEdit_constant_MENU_PASTE:

.. _class_TLLineEdit_constant_MENU_CLEAR:

.. _class_TLLineEdit_constant_MENU_SELECT_ALL:

.. _class_TLLineEdit_constant_MENU_UNDO:

.. _class_TLLineEdit_constant_MENU_REDO:

.. _class_TLLineEdit_constant_MENU_MAX:

enum **MenuItems**:

- **MENU_CUT** = **0** --- Cuts (copies and clears) the selected text.

- **MENU_COPY** = **1** --- Copies the selected text.

- **MENU_PASTE** = **2** --- Pastes the clipboard text over the selected text (or at the cursor's position).

Non-printable escape characters are automatically stripped from the OS clipboard via ``String.strip_escapes``.

- **MENU_CLEAR** = **3** --- Erases the whole ``TLLineEdit`` text.

- **MENU_SELECT_ALL** = **4** --- Selects the whole ``TLLineEdit`` text.

- **MENU_UNDO** = **5** --- Undoes the previous action.

- **MENU_REDO** = **6** --- Reverse the last undo action.

- **MENU_MAX** = **7** --- Represents the size of the :ref:`MenuItems<enum_TLLineEdit_MenuItems>` enum.

Description
-----------

TLLineEdit provides a single-line string editor, used for text fields. It features many built-in shortcuts which will always be available:

- Ctrl + C: Copy

- Ctrl + X: Cut

- Ctrl + V or Ctrl + Y: Paste/"yank"

- Ctrl + Z: Undo

- Ctrl + Shift + Z: Redo

- Ctrl + U: Delete text from the cursor position to the beginning of the line

- Ctrl + K: Delete text from the cursor position to the end of the line

- Ctrl + A: Select all text

- Ctrl + D: Swap current input direction (primary cursor)

- Up/Down arrow: Move the cursor to the beginning/end of the line

Property Descriptions
---------------------

.. _class_TLLineEdit_property_align:

- int **align**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+------------------+
   | *Default* | 0                |
   +-----------+------------------+
   | *Setter*  | set_align(value) |
   +-----------+------------------+
   | *Getter*  | get_align()      |
   +-----------+------------------+

Text alignment as defined in the ``ALIGN_*`` enum.

----

.. _class_TLLineEdit_property_base_font:

- :ref:`TLFontFamily<class_TLFontFamily>` **base_font**

.. table::
   :class: longtable
   :widths: 7 20

   +----------+----------------------+
   | *Setter* | set_base_font(value) |
   +----------+----------------------+
   | *Getter* | get_base_font()      |
   +----------+----------------------+

Base font.

----

.. _class_TLLineEdit_property_base_font_size:

- int **base_font_size**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+---------------------------+
   | *Default* | 12                        |
   +-----------+---------------------------+
   | *Setter*  | set_base_font_size(value) |
   +-----------+---------------------------+
   | *Getter*  | get_base_font_size()      |
   +-----------+---------------------------+

Base font size.

----

.. _class_TLLineEdit_property_base_font_style:

- String **base_font_style**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+----------------------------+
   | *Default* | "Regular"                  |
   +-----------+----------------------------+
   | *Setter*  | set_base_font_style(value) |
   +-----------+----------------------------+
   | *Getter*  | get_base_font_style()      |
   +-----------+----------------------------+

Base font style.

----

.. _class_TLLineEdit_property_caret_blink:

- bool **caret_blink**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+---------------------------------+
   | *Default* | false                           |
   +-----------+---------------------------------+
   | *Setter*  | cursor_set_blink_enabled(value) |
   +-----------+---------------------------------+
   | *Getter*  | cursor_get_blink_enabled()      |
   +-----------+---------------------------------+

If ``true``, the caret (visual cursor) blinks.

----

.. _class_TLLineEdit_property_caret_blink_speed:

- float **caret_blink_speed**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+-------------------------------+
   | *Default* | 0.65                          |
   +-----------+-------------------------------+
   | *Setter*  | cursor_set_blink_speed(value) |
   +-----------+-------------------------------+
   | *Getter*  | cursor_get_blink_speed()      |
   +-----------+-------------------------------+

Duration (in seconds) of a caret's blinking cycle.

----

.. _class_TLLineEdit_property_caret_position:

- int **caret_position**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+----------------------------+
   | *Default* | 0                          |
   +-----------+----------------------------+
   | *Setter*  | set_cursor_position(value) |
   +-----------+----------------------------+
   | *Getter*  | get_cursor_position()      |
   +-----------+----------------------------+

The cursor's position inside the ``TLLineEdit``. When set, the text may scroll to accommodate it.

----

.. _class_TLLineEdit_property_clear_button_enabled:

- bool **clear_button_enabled**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+---------------------------------+
   | *Default* | false                           |
   +-----------+---------------------------------+
   | *Setter*  | set_clear_button_enabled(value) |
   +-----------+---------------------------------+
   | *Getter*  | is_clear_button_enabled()       |
   +-----------+---------------------------------+

If ``true``, the ``TLLineEdit`` will show a clear button if ``text`` is not empty.

----

.. _class_TLLineEdit_property_context_menu_enabled:

- bool **context_menu_enabled**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+---------------------------------+
   | *Default* | true                            |
   +-----------+---------------------------------+
   | *Setter*  | set_context_menu_enabled(value) |
   +-----------+---------------------------------+
   | *Getter*  | is_context_menu_enabled()       |
   +-----------+---------------------------------+

If ``true``, the context menu will appear when right-clicked.

----

.. _class_TLLineEdit_property_editable:

- bool **editable**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+---------------------+
   | *Default* | true                |
   +-----------+---------------------+
   | *Setter*  | set_editable(value) |
   +-----------+---------------------+
   | *Getter*  | is_editable()       |
   +-----------+---------------------+

If ``false``, existing text cannot be modified and new text cannot be added.

----

.. _class_TLLineEdit_property_expand_to_text_length:

- bool **expand_to_text_length**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+----------------------------------+
   | *Default* | false                            |
   +-----------+----------------------------------+
   | *Setter*  | set_expand_to_text_length(value) |
   +-----------+----------------------------------+
   | *Getter*  | get_expand_to_text_length()      |
   +-----------+----------------------------------+

If ``true``, the ``TLLineEdit`` width will increase to stay longer than the :ref:`text<class_TLLineEdit_property_text>`. It will **not** compress if the :ref:`text<class_TLLineEdit_property_text>` is shortened.

----

.. _class_TLLineEdit_property_language:

- String **language**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+---------------------+
   | *Default* | ""                  |
   +-----------+---------------------+
   | *Setter*  | set_language(value) |
   +-----------+---------------------+
   | *Getter*  | get_language()      |
   +-----------+---------------------+

Language code for line-breaking and text shaping algorithms.

----

.. _class_TLLineEdit_property_max_length:

- int **max_length**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+-----------------------+
   | *Default* | 0                     |
   +-----------+-----------------------+
   | *Setter*  | set_max_length(value) |
   +-----------+-----------------------+
   | *Getter*  | get_max_length()      |
   +-----------+-----------------------+

Maximum amount of characters that can be entered inside the LineEdit. If ``0``, there is no limit.

----

.. _class_TLLineEdit_property_ot_features:

- String **ot_features**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+------------------------+
   | *Default* | ""                     |
   +-----------+------------------------+
   | *Setter*  | set_ot_features(value) |
   +-----------+------------------------+
   | *Getter*  | get_ot_features()      |
   +-----------+------------------------+

Comma separated list of OpenType feature tags.

----

.. _class_TLLineEdit_property_placeholder_alpha:

- float **placeholder_alpha**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+------------------------------+
   | *Default* | 0.6                          |
   +-----------+------------------------------+
   | *Setter*  | set_placeholder_alpha(value) |
   +-----------+------------------------------+
   | *Getter*  | get_placeholder_alpha()      |
   +-----------+------------------------------+

Opacity of the :ref:`placeholder_text<class_TLLineEdit_property_placeholder_text>`. From ``0`` to ``1``.

----

.. _class_TLLineEdit_property_placeholder_text:

- String **placeholder_text**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+------------------------+
   | *Default* | ""                     |
   +-----------+------------------------+
   | *Setter*  | set_placeholder(value) |
   +-----------+------------------------+
   | *Getter*  | get_placeholder()      |
   +-----------+------------------------+

Text shown when the ``TLLineEdit`` is empty. It is **not** the ``TLLineEdit``'s default value (see :ref:`text<class_TLLineEdit_property_text>`).

----

.. _class_TLLineEdit_property_secret:

- bool **secret**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+-------------------+
   | *Default* | false             |
   +-----------+-------------------+
   | *Setter*  | set_secret(value) |
   +-----------+-------------------+
   | *Getter*  | is_secret()       |
   +-----------+-------------------+

If ``true``, every character is replaced with the secret character (see :ref:`secret_character<class_TLLineEdit_property_secret_character>`).

----

.. _class_TLLineEdit_property_secret_character:

- String **secret_character**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+-----------------------------+
   | *Default* | "*"                         |
   +-----------+-----------------------------+
   | *Setter*  | set_secret_character(value) |
   +-----------+-----------------------------+
   | *Getter*  | get_secret_character()      |
   +-----------+-----------------------------+

The character to use to mask secret input (defaults to "\*"). Only a single character can be used as the secret character.

----

.. _class_TLLineEdit_property_text:

- String **text**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+-----------------+
   | *Default* | ""              |
   +-----------+-----------------+
   | *Setter*  | set_text(value) |
   +-----------+-----------------+
   | *Getter*  | get_text()      |
   +-----------+-----------------+

String value of the ``TLLineEdit``.

----

.. _class_TLLineEdit_property_text_direction:

- int **text_direction**

.. table::
   :class: longtable
   :widths: 7 20

   +-----------+---------------------------+
   | *Default* | 3                         |
   +-----------+---------------------------+
   | *Setter*  | set_text_direction(value) |
   +-----------+---------------------------+
   | *Getter*  | get_text_direction()      |
   +-----------+---------------------------+

Base direction of the text.

Method Descriptions
-------------------

.. _class_TLLineEdit_method_append_at_cursor:

- void **append_at_cursor** **(** String text **)**

Adds ``text`` after the cursor. If the resulting value is longer than :ref:`max_length<class_TLLineEdit_property_max_length>`, nothing happens.

----

.. _class_TLLineEdit_method_clear:

- void **clear** **(** **)**

Erases the ``TLLineEdit`` text.

----

.. _class_TLLineEdit_method_deselect:

- void **deselect** **(** **)**

Clears the current selection.

----

.. _class_TLLineEdit_method_get_menu:

- PopupMenu **get_menu** **(** **)** const

Returns the PopupMenu of this ``TLLineEdit``. By default, this menu is displayed when right-clicking on the ``TLLineEdit``.

----

.. _class_TLLineEdit_method_menu_option:

- void **menu_option** **(** int option **)**

Executes a given action as defined in the``MENU_*`` enum.

----

.. _class_TLLineEdit_method_select:

- void **select** **(** int from=0, int to=-1 **)**

Selects characters inside ``TLLineEdit`` between ``from`` and ``to``. By default, ``from`` is at the beginning and ``to`` at the end.

::

    text = "Welcome"
    select()     # Will select "Welcome"
    select(4)    # Will select "ome"
    select(2, 5) # Will select "lco"

----

.. _class_TLLineEdit_method_select_all:

- void **select_all** **(** **)**

Selects the whole String.