mirror of
https://github.com/godotengine/godot-docs-l10n.git
synced 2026-01-04 10:09:56 +03:00
525 lines
34 KiB
ReStructuredText
525 lines
34 KiB
ReStructuredText
:github_url: hide
|
||
|
||
.. _class_TextLine:
|
||
|
||
TextLine
|
||
========
|
||
|
||
**Успадковує:** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
|
||
|
||
Підтримує рядок тексту.
|
||
|
||
.. rst-class:: classref-introduction-group
|
||
|
||
Опис
|
||
--------
|
||
|
||
Анотація над :ref:`TextServer<class_TextServer>` для обробки одного рядка тексту.
|
||
|
||
.. rst-class:: classref-reftable-group
|
||
|
||
Властивості
|
||
----------------------
|
||
|
||
.. table::
|
||
:widths: auto
|
||
|
||
+---------------------------------------------------------------------------+-----------------------------------------------------------------------------+-----------+
|
||
| :ref:`HorizontalAlignment<enum_@GlobalScope_HorizontalAlignment>` | :ref:`alignment<class_TextLine_property_alignment>` | ``0`` |
|
||
+---------------------------------------------------------------------------+-----------------------------------------------------------------------------+-----------+
|
||
| :ref:`Direction<enum_TextServer_Direction>` | :ref:`direction<class_TextLine_property_direction>` | ``0`` |
|
||
+---------------------------------------------------------------------------+-----------------------------------------------------------------------------+-----------+
|
||
| :ref:`String<class_String>` | :ref:`ellipsis_char<class_TextLine_property_ellipsis_char>` | ``"…"`` |
|
||
+---------------------------------------------------------------------------+-----------------------------------------------------------------------------+-----------+
|
||
| |bitfield|\[:ref:`JustificationFlag<enum_TextServer_JustificationFlag>`\] | :ref:`flags<class_TextLine_property_flags>` | ``3`` |
|
||
+---------------------------------------------------------------------------+-----------------------------------------------------------------------------+-----------+
|
||
| :ref:`Orientation<enum_TextServer_Orientation>` | :ref:`orientation<class_TextLine_property_orientation>` | ``0`` |
|
||
+---------------------------------------------------------------------------+-----------------------------------------------------------------------------+-----------+
|
||
| :ref:`bool<class_bool>` | :ref:`preserve_control<class_TextLine_property_preserve_control>` | ``false`` |
|
||
+---------------------------------------------------------------------------+-----------------------------------------------------------------------------+-----------+
|
||
| :ref:`bool<class_bool>` | :ref:`preserve_invalid<class_TextLine_property_preserve_invalid>` | ``true`` |
|
||
+---------------------------------------------------------------------------+-----------------------------------------------------------------------------+-----------+
|
||
| :ref:`OverrunBehavior<enum_TextServer_OverrunBehavior>` | :ref:`text_overrun_behavior<class_TextLine_property_text_overrun_behavior>` | ``3`` |
|
||
+---------------------------------------------------------------------------+-----------------------------------------------------------------------------+-----------+
|
||
| :ref:`float<class_float>` | :ref:`width<class_TextLine_property_width>` | ``-1.0`` |
|
||
+---------------------------------------------------------------------------+-----------------------------------------------------------------------------+-----------+
|
||
|
||
.. rst-class:: classref-reftable-group
|
||
|
||
Методи
|
||
------------
|
||
|
||
.. table::
|
||
:widths: auto
|
||
|
||
+---------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||
| :ref:`bool<class_bool>` | :ref:`add_object<class_TextLine_method_add_object>`\ (\ key\: :ref:`Variant<class_Variant>`, size\: :ref:`Vector2<class_Vector2>`, inline_align\: :ref:`InlineAlignment<enum_@GlobalScope_InlineAlignment>` = 5, length\: :ref:`int<class_int>` = 1, baseline\: :ref:`float<class_float>` = 0.0\ ) |
|
||
+---------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||
| :ref:`bool<class_bool>` | :ref:`add_string<class_TextLine_method_add_string>`\ (\ text\: :ref:`String<class_String>`, font\: :ref:`Font<class_Font>`, font_size\: :ref:`int<class_int>`, language\: :ref:`String<class_String>` = "", meta\: :ref:`Variant<class_Variant>` = null\ ) |
|
||
+---------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||
| |void| | :ref:`clear<class_TextLine_method_clear>`\ (\ ) |
|
||
+---------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||
| |void| | :ref:`draw<class_TextLine_method_draw>`\ (\ canvas\: :ref:`RID<class_RID>`, pos\: :ref:`Vector2<class_Vector2>`, color\: :ref:`Color<class_Color>` = Color(1, 1, 1, 1), oversampling\: :ref:`float<class_float>` = 0.0\ ) |const| |
|
||
+---------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||
| |void| | :ref:`draw_outline<class_TextLine_method_draw_outline>`\ (\ canvas\: :ref:`RID<class_RID>`, pos\: :ref:`Vector2<class_Vector2>`, outline_size\: :ref:`int<class_int>` = 1, color\: :ref:`Color<class_Color>` = Color(1, 1, 1, 1), oversampling\: :ref:`float<class_float>` = 0.0\ ) |const| |
|
||
+---------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||
| :ref:`TextLine<class_TextLine>` | :ref:`duplicate<class_TextLine_method_duplicate>`\ (\ ) |const| |
|
||
+---------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||
| :ref:`Direction<enum_TextServer_Direction>` | :ref:`get_inferred_direction<class_TextLine_method_get_inferred_direction>`\ (\ ) |const| |
|
||
+---------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||
| :ref:`float<class_float>` | :ref:`get_line_ascent<class_TextLine_method_get_line_ascent>`\ (\ ) |const| |
|
||
+---------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||
| :ref:`float<class_float>` | :ref:`get_line_descent<class_TextLine_method_get_line_descent>`\ (\ ) |const| |
|
||
+---------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||
| :ref:`float<class_float>` | :ref:`get_line_underline_position<class_TextLine_method_get_line_underline_position>`\ (\ ) |const| |
|
||
+---------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||
| :ref:`float<class_float>` | :ref:`get_line_underline_thickness<class_TextLine_method_get_line_underline_thickness>`\ (\ ) |const| |
|
||
+---------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||
| :ref:`float<class_float>` | :ref:`get_line_width<class_TextLine_method_get_line_width>`\ (\ ) |const| |
|
||
+---------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||
| :ref:`Rect2<class_Rect2>` | :ref:`get_object_rect<class_TextLine_method_get_object_rect>`\ (\ key\: :ref:`Variant<class_Variant>`\ ) |const| |
|
||
+---------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||
| :ref:`Array<class_Array>` | :ref:`get_objects<class_TextLine_method_get_objects>`\ (\ ) |const| |
|
||
+---------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||
| :ref:`RID<class_RID>` | :ref:`get_rid<class_TextLine_method_get_rid>`\ (\ ) |const| |
|
||
+---------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||
| :ref:`Vector2<class_Vector2>` | :ref:`get_size<class_TextLine_method_get_size>`\ (\ ) |const| |
|
||
+---------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||
| :ref:`bool<class_bool>` | :ref:`has_object<class_TextLine_method_has_object>`\ (\ key\: :ref:`Variant<class_Variant>`\ ) |const| |
|
||
+---------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||
| :ref:`int<class_int>` | :ref:`hit_test<class_TextLine_method_hit_test>`\ (\ coords\: :ref:`float<class_float>`\ ) |const| |
|
||
+---------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||
| :ref:`bool<class_bool>` | :ref:`resize_object<class_TextLine_method_resize_object>`\ (\ key\: :ref:`Variant<class_Variant>`, size\: :ref:`Vector2<class_Vector2>`, inline_align\: :ref:`InlineAlignment<enum_@GlobalScope_InlineAlignment>` = 5, baseline\: :ref:`float<class_float>` = 0.0\ ) |
|
||
+---------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||
| |void| | :ref:`set_bidi_override<class_TextLine_method_set_bidi_override>`\ (\ override\: :ref:`Array<class_Array>`\ ) |
|
||
+---------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||
| |void| | :ref:`tab_align<class_TextLine_method_tab_align>`\ (\ tab_stops\: :ref:`PackedFloat32Array<class_PackedFloat32Array>`\ ) |
|
||
+---------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||
|
||
.. rst-class:: classref-section-separator
|
||
|
||
----
|
||
|
||
.. rst-class:: classref-descriptions-group
|
||
|
||
Описи властивостей
|
||
------------------------------------
|
||
|
||
.. _class_TextLine_property_alignment:
|
||
|
||
.. rst-class:: classref-property
|
||
|
||
:ref:`HorizontalAlignment<enum_@GlobalScope_HorizontalAlignment>` **alignment** = ``0`` :ref:`🔗<class_TextLine_property_alignment>`
|
||
|
||
.. rst-class:: classref-property-setget
|
||
|
||
- |void| **set_horizontal_alignment**\ (\ value\: :ref:`HorizontalAlignment<enum_@GlobalScope_HorizontalAlignment>`\ )
|
||
- :ref:`HorizontalAlignment<enum_@GlobalScope_HorizontalAlignment>` **get_horizontal_alignment**\ (\ )
|
||
|
||
Встановлює вирівнювання тексту в рядку, якщо лінія була горизонтальною.
|
||
|
||
.. rst-class:: classref-item-separator
|
||
|
||
----
|
||
|
||
.. _class_TextLine_property_direction:
|
||
|
||
.. rst-class:: classref-property
|
||
|
||
:ref:`Direction<enum_TextServer_Direction>` **direction** = ``0`` :ref:`🔗<class_TextLine_property_direction>`
|
||
|
||
.. rst-class:: classref-property-setget
|
||
|
||
- |void| **set_direction**\ (\ value\: :ref:`Direction<enum_TextServer_Direction>`\ )
|
||
- :ref:`Direction<enum_TextServer_Direction>` **get_direction**\ (\ )
|
||
|
||
Напрямок написання тексту.
|
||
|
||
.. rst-class:: classref-item-separator
|
||
|
||
----
|
||
|
||
.. _class_TextLine_property_ellipsis_char:
|
||
|
||
.. rst-class:: classref-property
|
||
|
||
:ref:`String<class_String>` **ellipsis_char** = ``"…"`` :ref:`🔗<class_TextLine_property_ellipsis_char>`
|
||
|
||
.. rst-class:: classref-property-setget
|
||
|
||
- |void| **set_ellipsis_char**\ (\ value\: :ref:`String<class_String>`\ )
|
||
- :ref:`String<class_String>` **get_ellipsis_char**\ (\ )
|
||
|
||
Елліпсис характер використовується для текстового затиску.
|
||
|
||
.. rst-class:: classref-item-separator
|
||
|
||
----
|
||
|
||
.. _class_TextLine_property_flags:
|
||
|
||
.. rst-class:: classref-property
|
||
|
||
|bitfield|\[:ref:`JustificationFlag<enum_TextServer_JustificationFlag>`\] **flags** = ``3`` :ref:`🔗<class_TextLine_property_flags>`
|
||
|
||
.. rst-class:: classref-property-setget
|
||
|
||
- |void| **set_flags**\ (\ value\: |bitfield|\[:ref:`JustificationFlag<enum_TextServer_JustificationFlag>`\]\ )
|
||
- |bitfield|\[:ref:`JustificationFlag<enum_TextServer_JustificationFlag>`\] **get_flags**\ (\ )
|
||
|
||
Правила вирівнювання лінії. Для отримання додаткової інформації див. :ref:`TextServer<class_TextServer>`.
|
||
|
||
.. rst-class:: classref-item-separator
|
||
|
||
----
|
||
|
||
.. _class_TextLine_property_orientation:
|
||
|
||
.. rst-class:: classref-property
|
||
|
||
:ref:`Orientation<enum_TextServer_Orientation>` **orientation** = ``0`` :ref:`🔗<class_TextLine_property_orientation>`
|
||
|
||
.. rst-class:: classref-property-setget
|
||
|
||
- |void| **set_orientation**\ (\ value\: :ref:`Orientation<enum_TextServer_Orientation>`\ )
|
||
- :ref:`Orientation<enum_TextServer_Orientation>` **get_orientation**\ (\ )
|
||
|
||
Текстова спрямованість.
|
||
|
||
.. rst-class:: classref-item-separator
|
||
|
||
----
|
||
|
||
.. _class_TextLine_property_preserve_control:
|
||
|
||
.. rst-class:: classref-property
|
||
|
||
:ref:`bool<class_bool>` **preserve_control** = ``false`` :ref:`🔗<class_TextLine_property_preserve_control>`
|
||
|
||
.. rst-class:: classref-property-setget
|
||
|
||
- |void| **set_preserve_control**\ (\ value\: :ref:`bool<class_bool>`\ )
|
||
- :ref:`bool<class_bool>` **get_preserve_control**\ (\ )
|
||
|
||
Якщо встановити на ``true`` текст буде відображати символи керування.
|
||
|
||
.. rst-class:: classref-item-separator
|
||
|
||
----
|
||
|
||
.. _class_TextLine_property_preserve_invalid:
|
||
|
||
.. rst-class:: classref-property
|
||
|
||
:ref:`bool<class_bool>` **preserve_invalid** = ``true`` :ref:`🔗<class_TextLine_property_preserve_invalid>`
|
||
|
||
.. rst-class:: classref-property-setget
|
||
|
||
- |void| **set_preserve_invalid**\ (\ value\: :ref:`bool<class_bool>`\ )
|
||
- :ref:`bool<class_bool>` **get_preserve_invalid**\ (\ )
|
||
|
||
Якщо встановити на ``true`` текст буде відображатися недійсними символи.
|
||
|
||
.. rst-class:: classref-item-separator
|
||
|
||
----
|
||
|
||
.. _class_TextLine_property_text_overrun_behavior:
|
||
|
||
.. rst-class:: classref-property
|
||
|
||
:ref:`OverrunBehavior<enum_TextServer_OverrunBehavior>` **text_overrun_behavior** = ``3`` :ref:`🔗<class_TextLine_property_text_overrun_behavior>`
|
||
|
||
.. rst-class:: classref-property-setget
|
||
|
||
- |void| **set_text_overrun_behavior**\ (\ value\: :ref:`OverrunBehavior<enum_TextServer_OverrunBehavior>`\ )
|
||
- :ref:`OverrunBehavior<enum_TextServer_OverrunBehavior>` **get_text_overrun_behavior**\ (\ )
|
||
|
||
Поведінка обрізання, коли текст перевищує встановлену ширину рядка тексту.
|
||
|
||
.. rst-class:: classref-item-separator
|
||
|
||
----
|
||
|
||
.. _class_TextLine_property_width:
|
||
|
||
.. rst-class:: classref-property
|
||
|
||
:ref:`float<class_float>` **width** = ``-1.0`` :ref:`🔗<class_TextLine_property_width>`
|
||
|
||
.. rst-class:: classref-property-setget
|
||
|
||
- |void| **set_width**\ (\ value\: :ref:`float<class_float>`\ )
|
||
- :ref:`float<class_float>` **get_width**\ (\ )
|
||
|
||
Ширина лінії тексту.
|
||
|
||
.. rst-class:: classref-section-separator
|
||
|
||
----
|
||
|
||
.. rst-class:: classref-descriptions-group
|
||
|
||
Описи методів
|
||
--------------------------
|
||
|
||
.. _class_TextLine_method_add_object:
|
||
|
||
.. rst-class:: classref-method
|
||
|
||
:ref:`bool<class_bool>` **add_object**\ (\ key\: :ref:`Variant<class_Variant>`, size\: :ref:`Vector2<class_Vector2>`, inline_align\: :ref:`InlineAlignment<enum_@GlobalScope_InlineAlignment>` = 5, length\: :ref:`int<class_int>` = 1, baseline\: :ref:`float<class_float>` = 0.0\ ) :ref:`🔗<class_TextLine_method_add_object>`
|
||
|
||
Додає вбудований об'єкт до текстового буфера, ``key`` повинен бути унікальним. У тексті об'єкт представлений як символ заміни об'єкта ``length``.
|
||
|
||
.. rst-class:: classref-item-separator
|
||
|
||
----
|
||
|
||
.. _class_TextLine_method_add_string:
|
||
|
||
.. rst-class:: classref-method
|
||
|
||
:ref:`bool<class_bool>` **add_string**\ (\ text\: :ref:`String<class_String>`, font\: :ref:`Font<class_Font>`, font_size\: :ref:`int<class_int>`, language\: :ref:`String<class_String>` = "", meta\: :ref:`Variant<class_Variant>` = null\ ) :ref:`🔗<class_TextLine_method_add_string>`
|
||
|
||
Додає текстовий проміжок і шрифт, щоб його намалювати.
|
||
|
||
.. rst-class:: classref-item-separator
|
||
|
||
----
|
||
|
||
.. _class_TextLine_method_clear:
|
||
|
||
.. rst-class:: classref-method
|
||
|
||
|void| **clear**\ (\ ) :ref:`🔗<class_TextLine_method_clear>`
|
||
|
||
Очищає текстову лінію (подає текст та інлайн об’єкти).
|
||
|
||
.. rst-class:: classref-item-separator
|
||
|
||
----
|
||
|
||
.. _class_TextLine_method_draw:
|
||
|
||
.. rst-class:: classref-method
|
||
|
||
|void| **draw**\ (\ canvas\: :ref:`RID<class_RID>`, pos\: :ref:`Vector2<class_Vector2>`, color\: :ref:`Color<class_Color>` = Color(1, 1, 1, 1), oversampling\: :ref:`float<class_float>` = 0.0\ ) |const| :ref:`🔗<class_TextLine_method_draw>`
|
||
|
||
Намалюйте текст на елементі полотна у заданій позиції за допомогою параметра ``color``. Параметр ``pos`` визначає верхній лівий кут рамки розміру. Якщо параметр ``oversampling`` більше за нуль, він використовується як коефіцієнт передискретизації шрифту, інакше використовуються налаштування передискретизації області перегляду.
|
||
|
||
.. rst-class:: classref-item-separator
|
||
|
||
----
|
||
|
||
.. _class_TextLine_method_draw_outline:
|
||
|
||
.. rst-class:: classref-method
|
||
|
||
|void| **draw_outline**\ (\ canvas\: :ref:`RID<class_RID>`, pos\: :ref:`Vector2<class_Vector2>`, outline_size\: :ref:`int<class_int>` = 1, color\: :ref:`Color<class_Color>` = Color(1, 1, 1, 1), oversampling\: :ref:`float<class_float>` = 0.0\ ) |const| :ref:`🔗<class_TextLine_method_draw_outline>`
|
||
|
||
Намалюйте текст на елементі полотна у заданій позиції за допомогою параметра ``color``. Параметр ``pos`` визначає верхній лівий кут рамки розміру. Якщо параметр ``oversampling`` більше за нуль, він використовується як коефіцієнт передискретизації шрифту, інакше використовуються налаштування передискретизації області перегляду.
|
||
|
||
.. rst-class:: classref-item-separator
|
||
|
||
----
|
||
|
||
.. _class_TextLine_method_duplicate:
|
||
|
||
.. rst-class:: classref-method
|
||
|
||
:ref:`TextLine<class_TextLine>` **duplicate**\ (\ ) |const| :ref:`🔗<class_TextLine_method_duplicate>`
|
||
|
||
Duplicates this **TextLine**.
|
||
|
||
.. rst-class:: classref-item-separator
|
||
|
||
----
|
||
|
||
.. _class_TextLine_method_get_inferred_direction:
|
||
|
||
.. rst-class:: classref-method
|
||
|
||
:ref:`Direction<enum_TextServer_Direction>` **get_inferred_direction**\ (\ ) |const| :ref:`🔗<class_TextLine_method_get_inferred_direction>`
|
||
|
||
Повертає напрямок написання тексту, визначений алгоритмом BiDi.
|
||
|
||
.. rst-class:: classref-item-separator
|
||
|
||
----
|
||
|
||
.. _class_TextLine_method_get_line_ascent:
|
||
|
||
.. rst-class:: classref-method
|
||
|
||
:ref:`float<class_float>` **get_line_ascent**\ (\ ) |const| :ref:`🔗<class_TextLine_method_get_line_ascent>`
|
||
|
||
Повернення текстового сходження (номер пікселів над базовою основою для горизонтального планування або зліва від базової лінії для вертикальної).
|
||
|
||
.. rst-class:: classref-item-separator
|
||
|
||
----
|
||
|
||
.. _class_TextLine_method_get_line_descent:
|
||
|
||
.. rst-class:: classref-method
|
||
|
||
:ref:`float<class_float>` **get_line_descent**\ (\ ) |const| :ref:`🔗<class_TextLine_method_get_line_descent>`
|
||
|
||
Повертає текстовий спуск (номер пікселів нижче базової лінії для горизонтального планування або праворуч від базової лінії для вертикальної).
|
||
|
||
.. rst-class:: classref-item-separator
|
||
|
||
----
|
||
|
||
.. _class_TextLine_method_get_line_underline_position:
|
||
|
||
.. rst-class:: classref-method
|
||
|
||
:ref:`float<class_float>` **get_line_underline_position**\ (\ ) |const| :ref:`🔗<class_TextLine_method_get_line_underline_position>`
|
||
|
||
Повертає піксельний зсув нижньої лінії нижче базової лінії.
|
||
|
||
.. rst-class:: classref-item-separator
|
||
|
||
----
|
||
|
||
.. _class_TextLine_method_get_line_underline_thickness:
|
||
|
||
.. rst-class:: classref-method
|
||
|
||
:ref:`float<class_float>` **get_line_underline_thickness**\ (\ ) |const| :ref:`🔗<class_TextLine_method_get_line_underline_thickness>`
|
||
|
||
Повертає товщину нижньої лінії.
|
||
|
||
.. rst-class:: classref-item-separator
|
||
|
||
----
|
||
|
||
.. _class_TextLine_method_get_line_width:
|
||
|
||
.. rst-class:: classref-method
|
||
|
||
:ref:`float<class_float>` **get_line_width**\ (\ ) |const| :ref:`🔗<class_TextLine_method_get_line_width>`
|
||
|
||
Повертає ширину (для горизонтального планування) або висоти (для вертикального) тексту.
|
||
|
||
.. rst-class:: classref-item-separator
|
||
|
||
----
|
||
|
||
.. _class_TextLine_method_get_object_rect:
|
||
|
||
.. rst-class:: classref-method
|
||
|
||
:ref:`Rect2<class_Rect2>` **get_object_rect**\ (\ key\: :ref:`Variant<class_Variant>`\ ) |const| :ref:`🔗<class_TextLine_method_get_object_rect>`
|
||
|
||
Повертає межу прямокутника об'єкта inline.
|
||
|
||
.. rst-class:: classref-item-separator
|
||
|
||
----
|
||
|
||
.. _class_TextLine_method_get_objects:
|
||
|
||
.. rst-class:: classref-method
|
||
|
||
:ref:`Array<class_Array>` **get_objects**\ (\ ) |const| :ref:`🔗<class_TextLine_method_get_objects>`
|
||
|
||
Повертає масив вбудованих об'єктів.
|
||
|
||
.. rst-class:: classref-item-separator
|
||
|
||
----
|
||
|
||
.. _class_TextLine_method_get_rid:
|
||
|
||
.. rst-class:: classref-method
|
||
|
||
:ref:`RID<class_RID>` **get_rid**\ (\ ) |const| :ref:`🔗<class_TextLine_method_get_rid>`
|
||
|
||
Повернення текстового сервера буфера RID.
|
||
|
||
.. rst-class:: classref-item-separator
|
||
|
||
----
|
||
|
||
.. _class_TextLine_method_get_size:
|
||
|
||
.. rst-class:: classref-method
|
||
|
||
:ref:`Vector2<class_Vector2>` **get_size**\ (\ ) |const| :ref:`🔗<class_TextLine_method_get_size>`
|
||
|
||
Повертає розмір межі тексту.
|
||
|
||
.. rst-class:: classref-item-separator
|
||
|
||
----
|
||
|
||
.. _class_TextLine_method_has_object:
|
||
|
||
.. rst-class:: classref-method
|
||
|
||
:ref:`bool<class_bool>` **has_object**\ (\ key\: :ref:`Variant<class_Variant>`\ ) |const| :ref:`🔗<class_TextLine_method_has_object>`
|
||
|
||
Returns ``true`` if an object with ``key`` is embedded in this line.
|
||
|
||
.. rst-class:: classref-item-separator
|
||
|
||
----
|
||
|
||
.. _class_TextLine_method_hit_test:
|
||
|
||
.. rst-class:: classref-method
|
||
|
||
:ref:`int<class_int>` **hit_test**\ (\ coords\: :ref:`float<class_float>`\ ) |const| :ref:`🔗<class_TextLine_method_hit_test>`
|
||
|
||
Повертає увагу, що вихід символів у зазначеному офсеті пікселя на базовій лінії. Ця функція завжди повертає дійсну позицію.
|
||
|
||
.. rst-class:: classref-item-separator
|
||
|
||
----
|
||
|
||
.. _class_TextLine_method_resize_object:
|
||
|
||
.. rst-class:: classref-method
|
||
|
||
:ref:`bool<class_bool>` **resize_object**\ (\ key\: :ref:`Variant<class_Variant>`, size\: :ref:`Vector2<class_Vector2>`, inline_align\: :ref:`InlineAlignment<enum_@GlobalScope_InlineAlignment>` = 5, baseline\: :ref:`float<class_float>` = 0.0\ ) :ref:`🔗<class_TextLine_method_resize_object>`
|
||
|
||
Налаштовує новий розмір і вирівнювання вбудованого об'єкта.
|
||
|
||
.. rst-class:: classref-item-separator
|
||
|
||
----
|
||
|
||
.. _class_TextLine_method_set_bidi_override:
|
||
|
||
.. rst-class:: classref-method
|
||
|
||
|void| **set_bidi_override**\ (\ override\: :ref:`Array<class_Array>`\ ) :ref:`🔗<class_TextLine_method_set_bidi_override>`
|
||
|
||
Надійшла BiDi для структурованого тексту.
|
||
|
||
Визначні діапазони повинні закривати текст повного джерела без перекриття. Для кожного діапазону використовуйте алгоритм BiDi.
|
||
|
||
.. rst-class:: classref-item-separator
|
||
|
||
----
|
||
|
||
.. _class_TextLine_method_tab_align:
|
||
|
||
.. rst-class:: classref-method
|
||
|
||
|void| **tab_align**\ (\ tab_stops\: :ref:`PackedFloat32Array<class_PackedFloat32Array>`\ ) :ref:`🔗<class_TextLine_method_tab_align>`
|
||
|
||
Вирівнює текст на задану вкладку.
|
||
|
||
.. |virtual| replace:: :abbr:`virtual (Зазвичай, цей метод перевизначається користувачем, щоб він мав вплив.)`
|
||
.. |required| replace:: :abbr:`required (This method is required to be overridden when extending its base class.)`
|
||
.. |const| replace:: :abbr:`const (Цей метод не має побічних ефектів. Не змінює ніяку змінну екземпляра об'єкта.)`
|
||
.. |vararg| replace:: :abbr:`vararg (Цей метод приймає будь-яке число аргументів після описаних тут.)`
|
||
.. |constructor| replace:: :abbr:`constructor (Цей метод використовується для побудови типів.)`
|
||
.. |static| replace:: :abbr:`static (Цей метод не потребує екземпляра для виклику, його можна викликати безпосередньо за допомогою назви класу.)`
|
||
.. |operator| replace:: :abbr:`operator (Цей метод описує дійсний оператор для взаємодії з цим типом як з лівим операндом.)`
|
||
.. |bitfield| replace:: :abbr:`BitField (Це значення є цілим числом, складеним у вигляді бітової маски з наступних прапорів.)`
|
||
.. |void| replace:: :abbr:`void (Значення не повертається.)`
|