mirror of
https://github.com/Relintai/pandemonium_engine_docs.git
synced 2025-01-23 15:17:21 +01:00
546 lines
24 KiB
ReStructuredText
546 lines
24 KiB
ReStructuredText
|
:github_url: hide
|
||
|
|
||
|
.. DO NOT EDIT THIS FILE!!!
|
||
|
.. Generated automatically from Godot engine sources.
|
||
|
.. Generator: https://github.com/godotengine/godot/tree/3.5/doc/tools/make_rst.py.
|
||
|
.. XML source: https://github.com/godotengine/godot/tree/3.5/doc/classes/Label3D.xml.
|
||
|
|
||
|
.. _class_Label3D:
|
||
|
|
||
|
Label3D
|
||
|
=======
|
||
|
|
||
|
**Inherits:** :ref:`GeometryInstance<class_GeometryInstance>` **<** :ref:`VisualInstance<class_VisualInstance>` **<** :ref:`CullInstance<class_CullInstance>` **<** :ref:`Spatial<class_Spatial>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
|
||
|
|
||
|
Displays plain text in a 3D world.
|
||
|
|
||
|
Description
|
||
|
-----------
|
||
|
|
||
|
Label3D displays plain text in a 3D world. It gives you control over the horizontal and vertical alignment.
|
||
|
|
||
|
Properties
|
||
|
----------
|
||
|
|
||
|
+----------------------------------------------------------+--------------------------------------------------------------------------------+-------------------------+
|
||
|
| :ref:`AlphaCutMode<enum_Label3D_AlphaCutMode>` | :ref:`alpha_cut<class_Label3D_property_alpha_cut>` | ``0`` |
|
||
|
+----------------------------------------------------------+--------------------------------------------------------------------------------+-------------------------+
|
||
|
| :ref:`float<class_float>` | :ref:`alpha_scissor_threshold<class_Label3D_property_alpha_scissor_threshold>` | ``0.5`` |
|
||
|
+----------------------------------------------------------+--------------------------------------------------------------------------------+-------------------------+
|
||
|
| :ref:`bool<class_bool>` | :ref:`autowrap<class_Label3D_property_autowrap>` | ``false`` |
|
||
|
+----------------------------------------------------------+--------------------------------------------------------------------------------+-------------------------+
|
||
|
| :ref:`BillboardMode<enum_SpatialMaterial_BillboardMode>` | :ref:`billboard<class_Label3D_property_billboard>` | ``0`` |
|
||
|
+----------------------------------------------------------+--------------------------------------------------------------------------------+-------------------------+
|
||
|
| :ref:`bool<class_bool>` | :ref:`double_sided<class_Label3D_property_double_sided>` | ``true`` |
|
||
|
+----------------------------------------------------------+--------------------------------------------------------------------------------+-------------------------+
|
||
|
| :ref:`bool<class_bool>` | :ref:`fixed_size<class_Label3D_property_fixed_size>` | ``false`` |
|
||
|
+----------------------------------------------------------+--------------------------------------------------------------------------------+-------------------------+
|
||
|
| :ref:`Font<class_Font>` | :ref:`font<class_Label3D_property_font>` | |
|
||
|
+----------------------------------------------------------+--------------------------------------------------------------------------------+-------------------------+
|
||
|
| :ref:`Align<enum_Label3D_Align>` | :ref:`horizontal_alignment<class_Label3D_property_horizontal_alignment>` | ``1`` |
|
||
|
+----------------------------------------------------------+--------------------------------------------------------------------------------+-------------------------+
|
||
|
| :ref:`float<class_float>` | :ref:`line_spacing<class_Label3D_property_line_spacing>` | ``0.0`` |
|
||
|
+----------------------------------------------------------+--------------------------------------------------------------------------------+-------------------------+
|
||
|
| :ref:`Color<class_Color>` | :ref:`modulate<class_Label3D_property_modulate>` | ``Color( 1, 1, 1, 1 )`` |
|
||
|
+----------------------------------------------------------+--------------------------------------------------------------------------------+-------------------------+
|
||
|
| :ref:`bool<class_bool>` | :ref:`no_depth_test<class_Label3D_property_no_depth_test>` | ``false`` |
|
||
|
+----------------------------------------------------------+--------------------------------------------------------------------------------+-------------------------+
|
||
|
| :ref:`Vector2<class_Vector2>` | :ref:`offset<class_Label3D_property_offset>` | ``Vector2( 0, 0 )`` |
|
||
|
+----------------------------------------------------------+--------------------------------------------------------------------------------+-------------------------+
|
||
|
| :ref:`Color<class_Color>` | :ref:`outline_modulate<class_Label3D_property_outline_modulate>` | ``Color( 0, 0, 0, 1 )`` |
|
||
|
+----------------------------------------------------------+--------------------------------------------------------------------------------+-------------------------+
|
||
|
| :ref:`int<class_int>` | :ref:`outline_render_priority<class_Label3D_property_outline_render_priority>` | ``-1`` |
|
||
|
+----------------------------------------------------------+--------------------------------------------------------------------------------+-------------------------+
|
||
|
| :ref:`float<class_float>` | :ref:`pixel_size<class_Label3D_property_pixel_size>` | ``0.01`` |
|
||
|
+----------------------------------------------------------+--------------------------------------------------------------------------------+-------------------------+
|
||
|
| :ref:`int<class_int>` | :ref:`render_priority<class_Label3D_property_render_priority>` | ``0`` |
|
||
|
+----------------------------------------------------------+--------------------------------------------------------------------------------+-------------------------+
|
||
|
| :ref:`bool<class_bool>` | :ref:`shaded<class_Label3D_property_shaded>` | ``false`` |
|
||
|
+----------------------------------------------------------+--------------------------------------------------------------------------------+-------------------------+
|
||
|
| :ref:`String<class_String>` | :ref:`text<class_Label3D_property_text>` | ``""`` |
|
||
|
+----------------------------------------------------------+--------------------------------------------------------------------------------+-------------------------+
|
||
|
| :ref:`bool<class_bool>` | :ref:`uppercase<class_Label3D_property_uppercase>` | ``false`` |
|
||
|
+----------------------------------------------------------+--------------------------------------------------------------------------------+-------------------------+
|
||
|
| :ref:`VAlign<enum_Label3D_VAlign>` | :ref:`vertical_alignment<class_Label3D_property_vertical_alignment>` | ``1`` |
|
||
|
+----------------------------------------------------------+--------------------------------------------------------------------------------+-------------------------+
|
||
|
| :ref:`float<class_float>` | :ref:`width<class_Label3D_property_width>` | ``500.0`` |
|
||
|
+----------------------------------------------------------+--------------------------------------------------------------------------------+-------------------------+
|
||
|
|
||
|
Methods
|
||
|
-------
|
||
|
|
||
|
+-----------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------+
|
||
|
| :ref:`TriangleMesh<class_TriangleMesh>` | :ref:`generate_triangle_mesh<class_Label3D_method_generate_triangle_mesh>` **(** **)** |const| |
|
||
|
+-----------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------+
|
||
|
| :ref:`bool<class_bool>` | :ref:`get_draw_flag<class_Label3D_method_get_draw_flag>` **(** :ref:`DrawFlags<enum_Label3D_DrawFlags>` flag **)** |const| |
|
||
|
+-----------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------+
|
||
|
| void | :ref:`set_draw_flag<class_Label3D_method_set_draw_flag>` **(** :ref:`DrawFlags<enum_Label3D_DrawFlags>` flag, :ref:`bool<class_bool>` enabled **)** |
|
||
|
+-----------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------+
|
||
|
|
||
|
Enumerations
|
||
|
------------
|
||
|
|
||
|
.. _enum_Label3D_DrawFlags:
|
||
|
|
||
|
.. _class_Label3D_constant_FLAG_SHADED:
|
||
|
|
||
|
.. _class_Label3D_constant_FLAG_DOUBLE_SIDED:
|
||
|
|
||
|
.. _class_Label3D_constant_FLAG_DISABLE_DEPTH_TEST:
|
||
|
|
||
|
.. _class_Label3D_constant_FLAG_FIXED_SIZE:
|
||
|
|
||
|
.. _class_Label3D_constant_FLAG_MAX:
|
||
|
|
||
|
enum **DrawFlags**:
|
||
|
|
||
|
- **FLAG_SHADED** = **0** --- If set, lights in the environment affect the label.
|
||
|
|
||
|
- **FLAG_DOUBLE_SIDED** = **1** --- If set, text can be seen from the back as well. If not, the text is invisible when looking at it from behind.
|
||
|
|
||
|
- **FLAG_DISABLE_DEPTH_TEST** = **2** --- Disables the depth test, so this object is drawn on top of all others. However, objects drawn after it in the draw order may cover it.
|
||
|
|
||
|
- **FLAG_FIXED_SIZE** = **3** --- Label is scaled by depth so that it always appears the same size on screen.
|
||
|
|
||
|
- **FLAG_MAX** = **4** --- Represents the size of the :ref:`DrawFlags<enum_Label3D_DrawFlags>` enum.
|
||
|
|
||
|
----
|
||
|
|
||
|
.. _enum_Label3D_AlphaCutMode:
|
||
|
|
||
|
.. _class_Label3D_constant_ALPHA_CUT_DISABLED:
|
||
|
|
||
|
.. _class_Label3D_constant_ALPHA_CUT_DISCARD:
|
||
|
|
||
|
.. _class_Label3D_constant_ALPHA_CUT_OPAQUE_PREPASS:
|
||
|
|
||
|
enum **AlphaCutMode**:
|
||
|
|
||
|
- **ALPHA_CUT_DISABLED** = **0** --- This mode performs standard alpha blending. It can display translucent areas, but transparency sorting issues may be visible when multiple transparent materials are overlapping.
|
||
|
|
||
|
- **ALPHA_CUT_DISCARD** = **1** --- This mode only allows fully transparent or fully opaque pixels. This mode is also known as *alpha testing* or *1-bit transparency*.
|
||
|
|
||
|
\ **Note:** This mode might have issues with anti-aliased fonts and outlines, try adjusting :ref:`alpha_scissor_threshold<class_Label3D_property_alpha_scissor_threshold>` or using SDF font.
|
||
|
|
||
|
\ **Note:** When using text with overlapping glyphs (e.g., cursive scripts), this mode might have transparency sorting issues between the main text and the outline.
|
||
|
|
||
|
- **ALPHA_CUT_OPAQUE_PREPASS** = **2** --- This mode draws fully opaque pixels in the depth prepass. This is slower than :ref:`ALPHA_CUT_DISABLED<class_Label3D_constant_ALPHA_CUT_DISABLED>` or :ref:`ALPHA_CUT_DISCARD<class_Label3D_constant_ALPHA_CUT_DISCARD>`, but it allows displaying translucent areas and smooth edges while using proper sorting.
|
||
|
|
||
|
\ **Note:** When using text with overlapping glyphs (e.g., cursive scripts), this mode might have transparency sorting issues between the main text and the outline.
|
||
|
|
||
|
----
|
||
|
|
||
|
.. _enum_Label3D_Align:
|
||
|
|
||
|
.. _class_Label3D_constant_ALIGN_LEFT:
|
||
|
|
||
|
.. _class_Label3D_constant_ALIGN_CENTER:
|
||
|
|
||
|
.. _class_Label3D_constant_ALIGN_RIGHT:
|
||
|
|
||
|
.. _class_Label3D_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 whitespaces to fit the width.
|
||
|
|
||
|
----
|
||
|
|
||
|
.. _enum_Label3D_VAlign:
|
||
|
|
||
|
.. _class_Label3D_constant_VALIGN_TOP:
|
||
|
|
||
|
.. _class_Label3D_constant_VALIGN_CENTER:
|
||
|
|
||
|
.. _class_Label3D_constant_VALIGN_BOTTOM:
|
||
|
|
||
|
.. _class_Label3D_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.
|
||
|
|
||
|
Property Descriptions
|
||
|
---------------------
|
||
|
|
||
|
.. _class_Label3D_property_alpha_cut:
|
||
|
|
||
|
- :ref:`AlphaCutMode<enum_Label3D_AlphaCutMode>` **alpha_cut**
|
||
|
|
||
|
+-----------+---------------------------+
|
||
|
| *Default* | ``0`` |
|
||
|
+-----------+---------------------------+
|
||
|
| *Setter* | set_alpha_cut_mode(value) |
|
||
|
+-----------+---------------------------+
|
||
|
| *Getter* | get_alpha_cut_mode() |
|
||
|
+-----------+---------------------------+
|
||
|
|
||
|
The alpha cutting mode to use for the sprite. See :ref:`AlphaCutMode<enum_Label3D_AlphaCutMode>` for possible values.
|
||
|
|
||
|
----
|
||
|
|
||
|
.. _class_Label3D_property_alpha_scissor_threshold:
|
||
|
|
||
|
- :ref:`float<class_float>` **alpha_scissor_threshold**
|
||
|
|
||
|
+-----------+------------------------------------+
|
||
|
| *Default* | ``0.5`` |
|
||
|
+-----------+------------------------------------+
|
||
|
| *Setter* | set_alpha_scissor_threshold(value) |
|
||
|
+-----------+------------------------------------+
|
||
|
| *Getter* | get_alpha_scissor_threshold() |
|
||
|
+-----------+------------------------------------+
|
||
|
|
||
|
Threshold at which the alpha scissor will discard values.
|
||
|
|
||
|
----
|
||
|
|
||
|
.. _class_Label3D_property_autowrap:
|
||
|
|
||
|
- :ref:`bool<class_bool>` **autowrap**
|
||
|
|
||
|
+-----------+---------------------+
|
||
|
| *Default* | ``false`` |
|
||
|
+-----------+---------------------+
|
||
|
| *Setter* | set_autowrap(value) |
|
||
|
+-----------+---------------------+
|
||
|
| *Getter* | get_autowrap() |
|
||
|
+-----------+---------------------+
|
||
|
|
||
|
If ``true``, wraps the text to the :ref:`width<class_Label3D_property_width>`.
|
||
|
|
||
|
----
|
||
|
|
||
|
.. _class_Label3D_property_billboard:
|
||
|
|
||
|
- :ref:`BillboardMode<enum_SpatialMaterial_BillboardMode>` **billboard**
|
||
|
|
||
|
+-----------+---------------------------+
|
||
|
| *Default* | ``0`` |
|
||
|
+-----------+---------------------------+
|
||
|
| *Setter* | set_billboard_mode(value) |
|
||
|
+-----------+---------------------------+
|
||
|
| *Getter* | get_billboard_mode() |
|
||
|
+-----------+---------------------------+
|
||
|
|
||
|
The billboard mode to use for the label. See :ref:`BillboardMode<enum_SpatialMaterial_BillboardMode>` for possible values.
|
||
|
|
||
|
----
|
||
|
|
||
|
.. _class_Label3D_property_double_sided:
|
||
|
|
||
|
- :ref:`bool<class_bool>` **double_sided**
|
||
|
|
||
|
+-----------+----------------------+
|
||
|
| *Default* | ``true`` |
|
||
|
+-----------+----------------------+
|
||
|
| *Setter* | set_draw_flag(value) |
|
||
|
+-----------+----------------------+
|
||
|
| *Getter* | get_draw_flag() |
|
||
|
+-----------+----------------------+
|
||
|
|
||
|
If ``true``, text can be seen from the back as well, if ``false``, it is invisible when looking at it from behind.
|
||
|
|
||
|
----
|
||
|
|
||
|
.. _class_Label3D_property_fixed_size:
|
||
|
|
||
|
- :ref:`bool<class_bool>` **fixed_size**
|
||
|
|
||
|
+-----------+----------------------+
|
||
|
| *Default* | ``false`` |
|
||
|
+-----------+----------------------+
|
||
|
| *Setter* | set_draw_flag(value) |
|
||
|
+-----------+----------------------+
|
||
|
| *Getter* | get_draw_flag() |
|
||
|
+-----------+----------------------+
|
||
|
|
||
|
If ``true``, the label is rendered at the same size regardless of distance.
|
||
|
|
||
|
----
|
||
|
|
||
|
.. _class_Label3D_property_font:
|
||
|
|
||
|
- :ref:`Font<class_Font>` **font**
|
||
|
|
||
|
+----------+-----------------+
|
||
|
| *Setter* | set_font(value) |
|
||
|
+----------+-----------------+
|
||
|
| *Getter* | get_font() |
|
||
|
+----------+-----------------+
|
||
|
|
||
|
:ref:`Font<class_Font>` used for the ``Label3D``'s text.
|
||
|
|
||
|
----
|
||
|
|
||
|
.. _class_Label3D_property_horizontal_alignment:
|
||
|
|
||
|
- :ref:`Align<enum_Label3D_Align>` **horizontal_alignment**
|
||
|
|
||
|
+-----------+---------------------------------+
|
||
|
| *Default* | ``1`` |
|
||
|
+-----------+---------------------------------+
|
||
|
| *Setter* | set_horizontal_alignment(value) |
|
||
|
+-----------+---------------------------------+
|
||
|
| *Getter* | get_horizontal_alignment() |
|
||
|
+-----------+---------------------------------+
|
||
|
|
||
|
Controls the text's horizontal alignment. Supports left, center, right. Set it to one of the :ref:`Align<enum_Label3D_Align>` constants.
|
||
|
|
||
|
----
|
||
|
|
||
|
.. _class_Label3D_property_line_spacing:
|
||
|
|
||
|
- :ref:`float<class_float>` **line_spacing**
|
||
|
|
||
|
+-----------+-------------------------+
|
||
|
| *Default* | ``0.0`` |
|
||
|
+-----------+-------------------------+
|
||
|
| *Setter* | set_line_spacing(value) |
|
||
|
+-----------+-------------------------+
|
||
|
| *Getter* | get_line_spacing() |
|
||
|
+-----------+-------------------------+
|
||
|
|
||
|
Vertical space between lines in multiline ``Label3D``.
|
||
|
|
||
|
----
|
||
|
|
||
|
.. _class_Label3D_property_modulate:
|
||
|
|
||
|
- :ref:`Color<class_Color>` **modulate**
|
||
|
|
||
|
+-----------+-------------------------+
|
||
|
| *Default* | ``Color( 1, 1, 1, 1 )`` |
|
||
|
+-----------+-------------------------+
|
||
|
| *Setter* | set_modulate(value) |
|
||
|
+-----------+-------------------------+
|
||
|
| *Getter* | get_modulate() |
|
||
|
+-----------+-------------------------+
|
||
|
|
||
|
Text :ref:`Color<class_Color>` of the ``Label3D``.
|
||
|
|
||
|
----
|
||
|
|
||
|
.. _class_Label3D_property_no_depth_test:
|
||
|
|
||
|
- :ref:`bool<class_bool>` **no_depth_test**
|
||
|
|
||
|
+-----------+----------------------+
|
||
|
| *Default* | ``false`` |
|
||
|
+-----------+----------------------+
|
||
|
| *Setter* | set_draw_flag(value) |
|
||
|
+-----------+----------------------+
|
||
|
| *Getter* | get_draw_flag() |
|
||
|
+-----------+----------------------+
|
||
|
|
||
|
If ``true``, depth testing is disabled and the object will be drawn in render order.
|
||
|
|
||
|
----
|
||
|
|
||
|
.. _class_Label3D_property_offset:
|
||
|
|
||
|
- :ref:`Vector2<class_Vector2>` **offset**
|
||
|
|
||
|
+-----------+---------------------+
|
||
|
| *Default* | ``Vector2( 0, 0 )`` |
|
||
|
+-----------+---------------------+
|
||
|
| *Setter* | set_offset(value) |
|
||
|
+-----------+---------------------+
|
||
|
| *Getter* | get_offset() |
|
||
|
+-----------+---------------------+
|
||
|
|
||
|
The text drawing offset (in pixels).
|
||
|
|
||
|
----
|
||
|
|
||
|
.. _class_Label3D_property_outline_modulate:
|
||
|
|
||
|
- :ref:`Color<class_Color>` **outline_modulate**
|
||
|
|
||
|
+-----------+-----------------------------+
|
||
|
| *Default* | ``Color( 0, 0, 0, 1 )`` |
|
||
|
+-----------+-----------------------------+
|
||
|
| *Setter* | set_outline_modulate(value) |
|
||
|
+-----------+-----------------------------+
|
||
|
| *Getter* | get_outline_modulate() |
|
||
|
+-----------+-----------------------------+
|
||
|
|
||
|
The tint of :ref:`Font<class_Font>`'s outline.
|
||
|
|
||
|
----
|
||
|
|
||
|
.. _class_Label3D_property_outline_render_priority:
|
||
|
|
||
|
- :ref:`int<class_int>` **outline_render_priority**
|
||
|
|
||
|
+-----------+------------------------------------+
|
||
|
| *Default* | ``-1`` |
|
||
|
+-----------+------------------------------------+
|
||
|
| *Setter* | set_outline_render_priority(value) |
|
||
|
+-----------+------------------------------------+
|
||
|
| *Getter* | get_outline_render_priority() |
|
||
|
+-----------+------------------------------------+
|
||
|
|
||
|
Sets the render priority for the text outline. Higher priority objects will be sorted in front of lower priority objects.
|
||
|
|
||
|
\ **Note:** This only applies if :ref:`alpha_cut<class_Label3D_property_alpha_cut>` is set to :ref:`ALPHA_CUT_DISABLED<class_Label3D_constant_ALPHA_CUT_DISABLED>` (default value).
|
||
|
|
||
|
\ **Note:** This only applies to sorting of transparent objects. This will not impact how transparent objects are sorted relative to opaque objects. This is because opaque objects are not sorted, while transparent objects are sorted from back to front (subject to priority).
|
||
|
|
||
|
----
|
||
|
|
||
|
.. _class_Label3D_property_pixel_size:
|
||
|
|
||
|
- :ref:`float<class_float>` **pixel_size**
|
||
|
|
||
|
+-----------+-----------------------+
|
||
|
| *Default* | ``0.01`` |
|
||
|
+-----------+-----------------------+
|
||
|
| *Setter* | set_pixel_size(value) |
|
||
|
+-----------+-----------------------+
|
||
|
| *Getter* | get_pixel_size() |
|
||
|
+-----------+-----------------------+
|
||
|
|
||
|
The size of one pixel's width on the label to scale it in 3D.
|
||
|
|
||
|
----
|
||
|
|
||
|
.. _class_Label3D_property_render_priority:
|
||
|
|
||
|
- :ref:`int<class_int>` **render_priority**
|
||
|
|
||
|
+-----------+----------------------------+
|
||
|
| *Default* | ``0`` |
|
||
|
+-----------+----------------------------+
|
||
|
| *Setter* | set_render_priority(value) |
|
||
|
+-----------+----------------------------+
|
||
|
| *Getter* | get_render_priority() |
|
||
|
+-----------+----------------------------+
|
||
|
|
||
|
Sets the render priority for the text. Higher priority objects will be sorted in front of lower priority objects.
|
||
|
|
||
|
\ **Note:** This only applies if :ref:`alpha_cut<class_Label3D_property_alpha_cut>` is set to :ref:`ALPHA_CUT_DISABLED<class_Label3D_constant_ALPHA_CUT_DISABLED>` (default value).
|
||
|
|
||
|
\ **Note:** This only applies to sorting of transparent objects. This will not impact how transparent objects are sorted relative to opaque objects. This is because opaque objects are not sorted, while transparent objects are sorted from back to front (subject to priority).
|
||
|
|
||
|
----
|
||
|
|
||
|
.. _class_Label3D_property_shaded:
|
||
|
|
||
|
- :ref:`bool<class_bool>` **shaded**
|
||
|
|
||
|
+-----------+----------------------+
|
||
|
| *Default* | ``false`` |
|
||
|
+-----------+----------------------+
|
||
|
| *Setter* | set_draw_flag(value) |
|
||
|
+-----------+----------------------+
|
||
|
| *Getter* | get_draw_flag() |
|
||
|
+-----------+----------------------+
|
||
|
|
||
|
If ``true``, the :ref:`Light<class_Light>` in the :ref:`Environment<class_Environment>` has effects on the label.
|
||
|
|
||
|
----
|
||
|
|
||
|
.. _class_Label3D_property_text:
|
||
|
|
||
|
- :ref:`String<class_String>` **text**
|
||
|
|
||
|
+-----------+-----------------+
|
||
|
| *Default* | ``""`` |
|
||
|
+-----------+-----------------+
|
||
|
| *Setter* | set_text(value) |
|
||
|
+-----------+-----------------+
|
||
|
| *Getter* | get_text() |
|
||
|
+-----------+-----------------+
|
||
|
|
||
|
The text to display on screen.
|
||
|
|
||
|
----
|
||
|
|
||
|
.. _class_Label3D_property_uppercase:
|
||
|
|
||
|
- :ref:`bool<class_bool>` **uppercase**
|
||
|
|
||
|
+-----------+----------------------+
|
||
|
| *Default* | ``false`` |
|
||
|
+-----------+----------------------+
|
||
|
| *Setter* | set_uppercase(value) |
|
||
|
+-----------+----------------------+
|
||
|
| *Getter* | is_uppercase() |
|
||
|
+-----------+----------------------+
|
||
|
|
||
|
If ``true``, all the text displays as UPPERCASE.
|
||
|
|
||
|
----
|
||
|
|
||
|
.. _class_Label3D_property_vertical_alignment:
|
||
|
|
||
|
- :ref:`VAlign<enum_Label3D_VAlign>` **vertical_alignment**
|
||
|
|
||
|
+-----------+-------------------------------+
|
||
|
| *Default* | ``1`` |
|
||
|
+-----------+-------------------------------+
|
||
|
| *Setter* | set_vertical_alignment(value) |
|
||
|
+-----------+-------------------------------+
|
||
|
| *Getter* | get_vertical_alignment() |
|
||
|
+-----------+-------------------------------+
|
||
|
|
||
|
Controls the text's vertical alignment. Supports top, center, bottom. Set it to one of the :ref:`VAlign<enum_Label3D_VAlign>` constants.
|
||
|
|
||
|
----
|
||
|
|
||
|
.. _class_Label3D_property_width:
|
||
|
|
||
|
- :ref:`float<class_float>` **width**
|
||
|
|
||
|
+-----------+------------------+
|
||
|
| *Default* | ``500.0`` |
|
||
|
+-----------+------------------+
|
||
|
| *Setter* | set_width(value) |
|
||
|
+-----------+------------------+
|
||
|
| *Getter* | get_width() |
|
||
|
+-----------+------------------+
|
||
|
|
||
|
Text width (in pixels), used for autowrap and fill alignment.
|
||
|
|
||
|
Method Descriptions
|
||
|
-------------------
|
||
|
|
||
|
.. _class_Label3D_method_generate_triangle_mesh:
|
||
|
|
||
|
- :ref:`TriangleMesh<class_TriangleMesh>` **generate_triangle_mesh** **(** **)** |const|
|
||
|
|
||
|
Returns a :ref:`TriangleMesh<class_TriangleMesh>` with the label's vertices following its current configuration (such as its :ref:`pixel_size<class_Label3D_property_pixel_size>`).
|
||
|
|
||
|
----
|
||
|
|
||
|
.. _class_Label3D_method_get_draw_flag:
|
||
|
|
||
|
- :ref:`bool<class_bool>` **get_draw_flag** **(** :ref:`DrawFlags<enum_Label3D_DrawFlags>` flag **)** |const|
|
||
|
|
||
|
Returns the value of the specified flag.
|
||
|
|
||
|
----
|
||
|
|
||
|
.. _class_Label3D_method_set_draw_flag:
|
||
|
|
||
|
- void **set_draw_flag** **(** :ref:`DrawFlags<enum_Label3D_DrawFlags>` flag, :ref:`bool<class_bool>` enabled **)**
|
||
|
|
||
|
If ``true``, the specified flag will be enabled. See :ref:`DrawFlags<enum_Label3D_DrawFlags>` for a list of flags.
|
||
|
|
||
|
.. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)`
|
||
|
.. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)`
|
||
|
.. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)`
|