Browse Source

[Complex Text Layouts] Update tutorials and documentation to match TextServer changes.

bruvzg 4 năm trước cách đây
mục cha
commit
20bcd1307a

+ 6 - 4
about/list_of_features.rst

@@ -92,12 +92,13 @@ Vulkan renderer.
 
    - Hard or soft shadows.
 
-- Font rendering using bitmaps (BitmapFont) or rasterization using FreeType (DynamicFont).
+- Font rendering using bitmaps or rasterization using FreeType.
 
    - Bitmap fonts can be exported using tools like BMFont.
-   - DynamicFont supports monochrome fonts as well as colored fonts.
+   - Dynamic fonts supports monochrome fonts as well as colored fonts.
      Supported formats are TTF and OTF.
-   - DynamicFont supports optional font outlines with adjustable width and color.
+   - Dynamic fonts supports optional font outlines with adjustable width and color.
+   - Dynamic fonts supports variable fonts and OpenType features.
    - Support for font oversampling to keep fonts sharp at higher resolutions.
 
 - GPU-based particles with support for custom particle shaders.
@@ -437,7 +438,8 @@ Internationalization
   or :ref:`gettext <doc_localization_using_gettext>`.
 - Use localized strings in your project automatically in GUI elements or by
   using the ``tr()`` function.
-- Support for right-to-left typesetting and text shaping planned in Godot 4.0.
+- Support for bidirectional typesetting and text shaping and OpenType localized forms.
+- Automatic UI mirroring for right-to-left locales.
 
 Windowing and OS integration
 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^

+ 1162 - 0
classes/class_textserver.rst

@@ -0,0 +1,1162 @@
+:github_url: hide
+
+.. Generated automatically by doc/tools/makerst.py in Godot's source tree.
+.. DO NOT EDIT THIS FILE, but the TextServer.xml source instead.
+.. The source is found in doc/classes or modules/<name>/doc_classes.
+
+.. _class_TextServer:
+
+TextServer
+==========
+
+**Inherits:** :ref:`Object<class_Object>`
+
+Interface for the fonts and complex text layouts.
+
+Description
+-----------
+
+``TextServer`` is the API backend for managing fonts, and rendering complex text.
+
+Methods
+-------
+
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`RID<class_RID>`                             | :ref:`create_font_memory<class_TextServer_method_create_font_memory>` **(** :ref:`PackedByteArray<class_PackedByteArray>` data, :ref:`String<class_String>` type, :ref:`int<class_int>` base_size=16 **)**                                                                                                                                        |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`RID<class_RID>`                             | :ref:`create_font_resource<class_TextServer_method_create_font_resource>` **(** :ref:`String<class_String>` filename, :ref:`int<class_int>` base_size=16 **)**                                                                                                                                                                                    |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`RID<class_RID>`                             | :ref:`create_font_system<class_TextServer_method_create_font_system>` **(** :ref:`String<class_String>` name, :ref:`int<class_int>` base_size=16 **)**                                                                                                                                                                                            |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`RID<class_RID>`                             | :ref:`create_shaped_text<class_TextServer_method_create_shaped_text>` **(** :ref:`Direction<enum_TextServer_Direction>` direction=0, :ref:`Orientation<enum_TextServer_Orientation>` orientation=0 **)**                                                                                                                                          |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| void                                              | :ref:`draw_hex_code_box<class_TextServer_method_draw_hex_code_box>` **(** :ref:`RID<class_RID>` canvas, :ref:`int<class_int>` size, :ref:`Vector2<class_Vector2>` pos, :ref:`int<class_int>` index, :ref:`Color<class_Color>` color **)** |const|                                                                                                 |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`Vector2<class_Vector2>`                     | :ref:`font_draw_glyph<class_TextServer_method_font_draw_glyph>` **(** :ref:`RID<class_RID>` font, :ref:`RID<class_RID>` canvas, :ref:`int<class_int>` size, :ref:`Vector2<class_Vector2>` pos, :ref:`int<class_int>` index, :ref:`Color<class_Color>` color=Color( 1, 1, 1, 1 ) **)** |const|                                                     |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`Vector2<class_Vector2>`                     | :ref:`font_draw_glyph_outline<class_TextServer_method_font_draw_glyph_outline>` **(** :ref:`RID<class_RID>` font, :ref:`RID<class_RID>` canvas, :ref:`int<class_int>` size, :ref:`int<class_int>` outline_size, :ref:`Vector2<class_Vector2>` pos, :ref:`int<class_int>` index, :ref:`Color<class_Color>` color=Color( 1, 1, 1, 1 ) **)** |const| |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`bool<class_bool>`                           | :ref:`font_get_antialiased<class_TextServer_method_font_get_antialiased>` **(** :ref:`RID<class_RID>` font **)** |const|                                                                                                                                                                                                                          |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`float<class_float>`                         | :ref:`font_get_ascent<class_TextServer_method_font_get_ascent>` **(** :ref:`RID<class_RID>` font, :ref:`int<class_int>` size **)** |const|                                                                                                                                                                                                        |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`float<class_float>`                         | :ref:`font_get_base_size<class_TextServer_method_font_get_base_size>` **(** :ref:`RID<class_RID>` font **)** |const|                                                                                                                                                                                                                              |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`float<class_float>`                         | :ref:`font_get_descent<class_TextServer_method_font_get_descent>` **(** :ref:`RID<class_RID>` font, :ref:`int<class_int>` size **)** |const|                                                                                                                                                                                                      |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`bool<class_bool>`                           | :ref:`font_get_distance_field_hint<class_TextServer_method_font_get_distance_field_hint>` **(** :ref:`RID<class_RID>` font **)** |const|                                                                                                                                                                                                          |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`bool<class_bool>`                           | :ref:`font_get_force_autohinter<class_TextServer_method_font_get_force_autohinter>` **(** :ref:`RID<class_RID>` font **)** |const|                                                                                                                                                                                                                |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`Vector2<class_Vector2>`                     | :ref:`font_get_glyph_advance<class_TextServer_method_font_get_glyph_advance>` **(** :ref:`RID<class_RID>` font, :ref:`int<class_int>` index, :ref:`int<class_int>` size **)** |const|                                                                                                                                                             |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`int<class_int>`                             | :ref:`font_get_glyph_index<class_TextServer_method_font_get_glyph_index>` **(** :ref:`RID<class_RID>` font, :ref:`int<class_int>` char, :ref:`int<class_int>` variation_selector=0 **)** |const|                                                                                                                                                  |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`Vector2<class_Vector2>`                     | :ref:`font_get_glyph_kerning<class_TextServer_method_font_get_glyph_kerning>` **(** :ref:`RID<class_RID>` font, :ref:`int<class_int>` index_a, :ref:`int<class_int>` index_b, :ref:`int<class_int>` size **)** |const|                                                                                                                            |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`float<class_float>`                         | :ref:`font_get_height<class_TextServer_method_font_get_height>` **(** :ref:`RID<class_RID>` font, :ref:`int<class_int>` size **)** |const|                                                                                                                                                                                                        |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`Hinting<enum_TextServer_Hinting>`           | :ref:`font_get_hinting<class_TextServer_method_font_get_hinting>` **(** :ref:`RID<class_RID>` font **)** |const|                                                                                                                                                                                                                                  |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`bool<class_bool>`                           | :ref:`font_get_language_support_override<class_TextServer_method_font_get_language_support_override>` **(** :ref:`RID<class_RID>` font, :ref:`String<class_String>` language **)**                                                                                                                                                                |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`PackedStringArray<class_PackedStringArray>` | :ref:`font_get_language_support_overrides<class_TextServer_method_font_get_language_support_overrides>` **(** :ref:`RID<class_RID>` font **)**                                                                                                                                                                                                    |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`float<class_float>`                         | :ref:`font_get_oversampling<class_TextServer_method_font_get_oversampling>` **(** **)** |const|                                                                                                                                                                                                                                                   |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`bool<class_bool>`                           | :ref:`font_get_script_support_override<class_TextServer_method_font_get_script_support_override>` **(** :ref:`RID<class_RID>` font, :ref:`String<class_String>` script **)**                                                                                                                                                                      |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`PackedStringArray<class_PackedStringArray>` | :ref:`font_get_script_support_overrides<class_TextServer_method_font_get_script_support_overrides>` **(** :ref:`RID<class_RID>` font **)**                                                                                                                                                                                                        |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`String<class_String>`                       | :ref:`font_get_supported_chars<class_TextServer_method_font_get_supported_chars>` **(** :ref:`RID<class_RID>` font **)** |const|                                                                                                                                                                                                                  |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`float<class_float>`                         | :ref:`font_get_underline_position<class_TextServer_method_font_get_underline_position>` **(** :ref:`RID<class_RID>` font, :ref:`int<class_int>` size **)** |const|                                                                                                                                                                                |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`float<class_float>`                         | :ref:`font_get_underline_thickness<class_TextServer_method_font_get_underline_thickness>` **(** :ref:`RID<class_RID>` font, :ref:`int<class_int>` size **)** |const|                                                                                                                                                                              |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`String<class_String>`                       | :ref:`font_get_variation_list<class_TextServer_method_font_get_variation_list>` **(** :ref:`RID<class_RID>` fonte **)** |const|                                                                                                                                                                                                                   |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`String<class_String>`                       | :ref:`font_get_variations<class_TextServer_method_font_get_variations>` **(** :ref:`RID<class_RID>` font **)** |const|                                                                                                                                                                                                                            |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`bool<class_bool>`                           | :ref:`font_has_char<class_TextServer_method_font_has_char>` **(** :ref:`RID<class_RID>` font, :ref:`int<class_int>` char **)** |const|                                                                                                                                                                                                            |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`bool<class_bool>`                           | :ref:`font_has_outline<class_TextServer_method_font_has_outline>` **(** :ref:`RID<class_RID>` font **)** |const|                                                                                                                                                                                                                                  |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`bool<class_bool>`                           | :ref:`font_is_language_supported<class_TextServer_method_font_is_language_supported>` **(** :ref:`RID<class_RID>` font, :ref:`String<class_String>` language **)** |const|                                                                                                                                                                        |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`bool<class_bool>`                           | :ref:`font_is_script_supported<class_TextServer_method_font_is_script_supported>` **(** :ref:`RID<class_RID>` font, :ref:`String<class_String>` script **)** |const|                                                                                                                                                                              |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| void                                              | :ref:`font_remove_language_support_override<class_TextServer_method_font_remove_language_support_override>` **(** :ref:`RID<class_RID>` font, :ref:`String<class_String>` language **)**                                                                                                                                                          |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| void                                              | :ref:`font_remove_script_support_override<class_TextServer_method_font_remove_script_support_override>` **(** :ref:`RID<class_RID>` font, :ref:`String<class_String>` script **)**                                                                                                                                                                |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| void                                              | :ref:`font_set_antialiased<class_TextServer_method_font_set_antialiased>` **(** :ref:`RID<class_RID>` font, :ref:`bool<class_bool>` antialiased **)**                                                                                                                                                                                             |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| void                                              | :ref:`font_set_distance_field_hint<class_TextServer_method_font_set_distance_field_hint>` **(** :ref:`RID<class_RID>` font, :ref:`bool<class_bool>` distance_field **)**                                                                                                                                                                          |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| void                                              | :ref:`font_set_force_autohinter<class_TextServer_method_font_set_force_autohinter>` **(** :ref:`RID<class_RID>` font, :ref:`bool<class_bool>` enabeld **)**                                                                                                                                                                                       |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| void                                              | :ref:`font_set_hinting<class_TextServer_method_font_set_hinting>` **(** :ref:`RID<class_RID>` font, :ref:`Hinting<enum_TextServer_Hinting>` hinting **)**                                                                                                                                                                                         |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| void                                              | :ref:`font_set_language_support_override<class_TextServer_method_font_set_language_support_override>` **(** :ref:`RID<class_RID>` font, :ref:`String<class_String>` language, :ref:`bool<class_bool>` supported **)**                                                                                                                             |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| void                                              | :ref:`font_set_oversampling<class_TextServer_method_font_set_oversampling>` **(** :ref:`float<class_float>` oversampling **)**                                                                                                                                                                                                                    |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| void                                              | :ref:`font_set_script_support_override<class_TextServer_method_font_set_script_support_override>` **(** :ref:`RID<class_RID>` font, :ref:`String<class_String>` script, :ref:`bool<class_bool>` supported **)**                                                                                                                                   |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| void                                              | :ref:`font_set_variations<class_TextServer_method_font_set_variations>` **(** :ref:`RID<class_RID>` font, :ref:`String<class_String>` value **)**                                                                                                                                                                                                 |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`String<class_String>`                       | :ref:`format_number<class_TextServer_method_format_number>` **(** :ref:`String<class_String>` number, :ref:`String<class_String>` language="" **)** |const|                                                                                                                                                                                       |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| void                                              | :ref:`free_rid<class_TextServer_method_free_rid>` **(** :ref:`RID<class_RID>` rid **)**                                                                                                                                                                                                                                                           |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`Vector2<class_Vector2>`                     | :ref:`get_hex_code_box_size<class_TextServer_method_get_hex_code_box_size>` **(** :ref:`int<class_int>` size, :ref:`int<class_int>` index **)** |const|                                                                                                                                                                                           |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`String<class_String>`                       | :ref:`get_name<class_TextServer_method_get_name>` **(** **)** |const|                                                                                                                                                                                                                                                                             |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`PackedStringArray<class_PackedStringArray>` | :ref:`get_system_fonts<class_TextServer_method_get_system_fonts>` **(** **)** |const|                                                                                                                                                                                                                                                             |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`bool<class_bool>`                           | :ref:`has<class_TextServer_method_has>` **(** :ref:`RID<class_RID>` rid **)**                                                                                                                                                                                                                                                                     |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`bool<class_bool>`                           | :ref:`has_feature<class_TextServer_method_has_feature>` **(** :ref:`Feature<enum_TextServer_Feature>` feature **)**                                                                                                                                                                                                                               |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`bool<class_bool>`                           | :ref:`is_locale_right_to_left<class_TextServer_method_is_locale_right_to_left>` **(** :ref:`String<class_String>` locale **)**                                                                                                                                                                                                                    |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`bool<class_bool>`                           | :ref:`load_support_data<class_TextServer_method_load_support_data>` **(** :ref:`String<class_String>` filename **)**                                                                                                                                                                                                                              |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`String<class_String>`                       | :ref:`parse_number<class_TextServer_method_parse_number>` **(** :ref:`String<class_String>` number, :ref:`String<class_String>` language="" **)** |const|                                                                                                                                                                                         |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`String<class_String>`                       | :ref:`percent_sign<class_TextServer_method_percent_sign>` **(** :ref:`String<class_String>` language="" **)** |const|                                                                                                                                                                                                                             |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`bool<class_bool>`                           | :ref:`shaped_text_add_object<class_TextServer_method_shaped_text_add_object>` **(** :ref:`RID<class_RID>` shaped, :ref:`Variant<class_Variant>` key, :ref:`Vector2<class_Vector2>` size, :ref:`VAlign<enum_@GlobalScope_VAlign>` inline_align=1 **)**                                                                                             |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`bool<class_bool>`                           | :ref:`shaped_text_add_string<class_TextServer_method_shaped_text_add_string>` **(** :ref:`RID<class_RID>` shaped, :ref:`String<class_String>` text, :ref:`Array<class_Array>` fonts, :ref:`int<class_int>` size, :ref:`String<class_String>` opentype_features="", :ref:`String<class_String>` language="" **)**                                  |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| void                                              | :ref:`shaped_text_clear<class_TextServer_method_shaped_text_clear>` **(** :ref:`RID<class_RID>` arg0 **)**                                                                                                                                                                                                                                        |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| void                                              | :ref:`shaped_text_draw<class_TextServer_method_shaped_text_draw>` **(** :ref:`RID<class_RID>` shaped, :ref:`RID<class_RID>` canvas, :ref:`Vector2<class_Vector2>` pos, :ref:`float<class_float>` clip_w=-1, :ref:`Color<class_Color>` color=Color( 1, 1, 1, 1 ) **)** |const|                                                                     |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| void                                              | :ref:`shaped_text_draw_outline<class_TextServer_method_shaped_text_draw_outline>` **(** :ref:`RID<class_RID>` shaped, :ref:`RID<class_RID>` canvas, :ref:`Vector2<class_Vector2>` pos, :ref:`float<class_float>` clip_w=-1, :ref:`int<class_int>` outline_size=1, :ref:`Color<class_Color>` color=Color( 1, 1, 1, 1 ) **)** |const|               |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`float<class_float>`                         | :ref:`shaped_text_fit_to_width<class_TextServer_method_shaped_text_fit_to_width>` **(** :ref:`RID<class_RID>` shaped, :ref:`float<class_float>` width, :ref:`int<class_int>` jst_flags=48 **)**                                                                                                                                                   |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`float<class_float>`                         | :ref:`shaped_text_get_ascent<class_TextServer_method_shaped_text_get_ascent>` **(** :ref:`RID<class_RID>` shaped **)** |const|                                                                                                                                                                                                                    |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`Dictionary<class_Dictionary>`               | :ref:`shaped_text_get_carets<class_TextServer_method_shaped_text_get_carets>` **(** :ref:`RID<class_RID>` shaped, :ref:`int<class_int>` position **)** |const|                                                                                                                                                                                    |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`float<class_float>`                         | :ref:`shaped_text_get_descent<class_TextServer_method_shaped_text_get_descent>` **(** :ref:`RID<class_RID>` shaped **)** |const|                                                                                                                                                                                                                  |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`Direction<enum_TextServer_Direction>`       | :ref:`shaped_text_get_direction<class_TextServer_method_shaped_text_get_direction>` **(** :ref:`RID<class_RID>` shaped **)** |const|                                                                                                                                                                                                              |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`Direction<enum_TextServer_Direction>`       | :ref:`shaped_text_get_dominant_direciton_in_range<class_TextServer_method_shaped_text_get_dominant_direciton_in_range>` **(** :ref:`RID<class_RID>` shaped, :ref:`int<class_int>` start, :ref:`int<class_int>` end **)** |const|                                                                                                                  |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`Array<class_Array>`                         | :ref:`shaped_text_get_glyphs<class_TextServer_method_shaped_text_get_glyphs>` **(** :ref:`RID<class_RID>` shaped **)** |const|                                                                                                                                                                                                                    |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`Array<class_Array>`                         | :ref:`shaped_text_get_line_breaks<class_TextServer_method_shaped_text_get_line_breaks>` **(** :ref:`RID<class_RID>` shaped, :ref:`float<class_float>` width, :ref:`int<class_int>` start=0, :ref:`int<class_int>` break_flags=3 **)** |const|                                                                                                     |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`Array<class_Array>`                         | :ref:`shaped_text_get_line_breaks_adv<class_TextServer_method_shaped_text_get_line_breaks_adv>` **(** :ref:`RID<class_RID>` shaped, :ref:`PackedFloat32Array<class_PackedFloat32Array>` width, :ref:`int<class_int>` start=0, :ref:`bool<class_bool>` once=true, :ref:`int<class_int>` break_flags=3 **)** |const|                                |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`Rect2<class_Rect2>`                         | :ref:`shaped_text_get_object_rect<class_TextServer_method_shaped_text_get_object_rect>` **(** :ref:`RID<class_RID>` shaped, :ref:`Variant<class_Variant>` key **)** |const|                                                                                                                                                                       |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`Array<class_Array>`                         | :ref:`shaped_text_get_objects<class_TextServer_method_shaped_text_get_objects>` **(** :ref:`RID<class_RID>` shaped **)** |const|                                                                                                                                                                                                                  |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`Orientation<enum_TextServer_Orientation>`   | :ref:`shaped_text_get_orientation<class_TextServer_method_shaped_text_get_orientation>` **(** :ref:`RID<class_RID>` shaped **)** |const|                                                                                                                                                                                                          |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`RID<class_RID>`                             | :ref:`shaped_text_get_parent<class_TextServer_method_shaped_text_get_parent>` **(** :ref:`RID<class_RID>` shaped **)** |const|                                                                                                                                                                                                                    |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`bool<class_bool>`                           | :ref:`shaped_text_get_preserve_control<class_TextServer_method_shaped_text_get_preserve_control>` **(** :ref:`RID<class_RID>` shaped **)** |const|                                                                                                                                                                                                |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`bool<class_bool>`                           | :ref:`shaped_text_get_preserve_invalid<class_TextServer_method_shaped_text_get_preserve_invalid>` **(** :ref:`RID<class_RID>` shaped **)** |const|                                                                                                                                                                                                |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`Vector2i<class_Vector2i>`                   | :ref:`shaped_text_get_range<class_TextServer_method_shaped_text_get_range>` **(** :ref:`RID<class_RID>` shaped **)** |const|                                                                                                                                                                                                                      |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`Array<class_Array>`                         | :ref:`shaped_text_get_selection<class_TextServer_method_shaped_text_get_selection>` **(** :ref:`RID<class_RID>` shaped, :ref:`int<class_int>` start, :ref:`int<class_int>` end **)** |const|                                                                                                                                                      |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`Vector2<class_Vector2>`                     | :ref:`shaped_text_get_size<class_TextServer_method_shaped_text_get_size>` **(** :ref:`RID<class_RID>` shaped **)** |const|                                                                                                                                                                                                                        |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`float<class_float>`                         | :ref:`shaped_text_get_underline_position<class_TextServer_method_shaped_text_get_underline_position>` **(** :ref:`RID<class_RID>` shaped **)** |const|                                                                                                                                                                                            |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`float<class_float>`                         | :ref:`shaped_text_get_underline_thickness<class_TextServer_method_shaped_text_get_underline_thickness>` **(** :ref:`RID<class_RID>` shaped **)** |const|                                                                                                                                                                                          |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`float<class_float>`                         | :ref:`shaped_text_get_width<class_TextServer_method_shaped_text_get_width>` **(** :ref:`RID<class_RID>` shaped **)** |const|                                                                                                                                                                                                                      |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`Array<class_Array>`                         | :ref:`shaped_text_get_word_breaks<class_TextServer_method_shaped_text_get_word_breaks>` **(** :ref:`RID<class_RID>` shaped **)** |const|                                                                                                                                                                                                          |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`int<class_int>`                             | :ref:`shaped_text_hit_test_grapheme<class_TextServer_method_shaped_text_hit_test_grapheme>` **(** :ref:`RID<class_RID>` shaped, :ref:`float<class_float>` coords **)** |const|                                                                                                                                                                    |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`int<class_int>`                             | :ref:`shaped_text_hit_test_position<class_TextServer_method_shaped_text_hit_test_position>` **(** :ref:`RID<class_RID>` shaped, :ref:`float<class_float>` coords **)** |const|                                                                                                                                                                    |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`bool<class_bool>`                           | :ref:`shaped_text_is_ready<class_TextServer_method_shaped_text_is_ready>` **(** :ref:`RID<class_RID>` shaped **)** |const|                                                                                                                                                                                                                        |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`int<class_int>`                             | :ref:`shaped_text_next_grapheme_pos<class_TextServer_method_shaped_text_next_grapheme_pos>` **(** :ref:`RID<class_RID>` shaped, :ref:`int<class_int>` pos **)**                                                                                                                                                                                   |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`int<class_int>`                             | :ref:`shaped_text_prev_grapheme_pos<class_TextServer_method_shaped_text_prev_grapheme_pos>` **(** :ref:`RID<class_RID>` shaped, :ref:`int<class_int>` pos **)**                                                                                                                                                                                   |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| void                                              | :ref:`shaped_text_set_bidi_override<class_TextServer_method_shaped_text_set_bidi_override>` **(** :ref:`RID<class_RID>` shaped, :ref:`Array<class_Array>` override **)**                                                                                                                                                                          |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| void                                              | :ref:`shaped_text_set_direction<class_TextServer_method_shaped_text_set_direction>` **(** :ref:`RID<class_RID>` shaped, :ref:`Direction<enum_TextServer_Direction>` direction=0 **)**                                                                                                                                                             |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| void                                              | :ref:`shaped_text_set_orientation<class_TextServer_method_shaped_text_set_orientation>` **(** :ref:`RID<class_RID>` shaped, :ref:`Orientation<enum_TextServer_Orientation>` orientation=0 **)**                                                                                                                                                   |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| void                                              | :ref:`shaped_text_set_preserve_control<class_TextServer_method_shaped_text_set_preserve_control>` **(** :ref:`RID<class_RID>` shaped, :ref:`bool<class_bool>` enabled **)**                                                                                                                                                                       |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| void                                              | :ref:`shaped_text_set_preserve_invalid<class_TextServer_method_shaped_text_set_preserve_invalid>` **(** :ref:`RID<class_RID>` shaped, :ref:`bool<class_bool>` enabled **)**                                                                                                                                                                       |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`bool<class_bool>`                           | :ref:`shaped_text_shape<class_TextServer_method_shaped_text_shape>` **(** :ref:`RID<class_RID>` shaped **)**                                                                                                                                                                                                                                      |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`RID<class_RID>`                             | :ref:`shaped_text_substr<class_TextServer_method_shaped_text_substr>` **(** :ref:`RID<class_RID>` shaped, :ref:`int<class_int>` start, :ref:`int<class_int>` length **)** |const|                                                                                                                                                                 |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`float<class_float>`                         | :ref:`shaped_text_tab_align<class_TextServer_method_shaped_text_tab_align>` **(** :ref:`RID<class_RID>` shaped, :ref:`PackedFloat32Array<class_PackedFloat32Array>` tab_stops **)**                                                                                                                                                               |
++---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+
+Enumerations
+------------
+
+.. _enum_TextServer_Direction:
+
+.. _class_TextServer_constant_DIRECTION_AUTO:
+
+.. _class_TextServer_constant_DIRECTION_LTR:
+
+.. _class_TextServer_constant_DIRECTION_RTL:
+
+enum **Direction**:
+
+- **DIRECTION_AUTO** = **0** --- Text direction is determined based on contents and current locale.
+
+- **DIRECTION_LTR** = **1** --- Text is written from left to right.
+
+- **DIRECTION_RTL** = **2** --- Text is written from right to left.
+
+----
+
+.. _enum_TextServer_Orientation:
+
+.. _class_TextServer_constant_ORIENTATION_HORIZONTAL:
+
+.. _class_TextServer_constant_ORIENTATION_VERTICAL:
+
+enum **Orientation**:
+
+- **ORIENTATION_HORIZONTAL** = **0** --- Text is written horizontally.
+
+- **ORIENTATION_VERTICAL** = **1** --- Left to right text is written vertically from top to bottom.
+
+Right to left text is written vertically from bottom to top.
+
+----
+
+.. _enum_TextServer_JustificationFlag:
+
+.. _class_TextServer_constant_JUSTIFICATION_NONE:
+
+.. _class_TextServer_constant_JUSTIFICATION_KASHIDA:
+
+.. _class_TextServer_constant_JUSTIFICATION_WORD_BOUND:
+
+.. _class_TextServer_constant_JUSTIFICATION_TRIM_EDGE_SPACES:
+
+.. _class_TextServer_constant_JUSTIFICATION_AFTER_LAST_TAB:
+
+enum **JustificationFlag**:
+
+- **JUSTIFICATION_NONE** = **0** --- Do not justify text.
+
+- **JUSTIFICATION_KASHIDA** = **16** --- Justify text by adding and removing kashidas.
+
+- **JUSTIFICATION_WORD_BOUND** = **32** --- Justify text by changing width of the spaces between the words.
+
+- **JUSTIFICATION_TRIM_EDGE_SPACES** = **64** --- Remove trailing and leading spaces from the justified text.
+
+- **JUSTIFICATION_AFTER_LAST_TAB** = **128** --- Only apply justification to the part of the text after the last tab.
+
+----
+
+.. _enum_TextServer_LineBreakFlag:
+
+.. _class_TextServer_constant_BREAK_NONE:
+
+.. _class_TextServer_constant_BREAK_MANDATORY:
+
+.. _class_TextServer_constant_BREAK_WORD_BOUND:
+
+.. _class_TextServer_constant_BREAK_GRAPHEME_BOUND:
+
+enum **LineBreakFlag**:
+
+- **BREAK_NONE** = **0** --- Do not break the line.
+
+- **BREAK_MANDATORY** = **1** --- Break the line at the line mandatory break characters (e.g. ``"\n"``).
+
+- **BREAK_WORD_BOUND** = **2** --- Break the line between the words.
+
+- **BREAK_GRAPHEME_BOUND** = **4** --- Break the line between any unconnected graphemes.
+
+----
+
+.. _enum_TextServer_GraphemeFlag:
+
+.. _class_TextServer_constant_GRAPHEME_IS_RTL:
+
+.. _class_TextServer_constant_GRAPHEME_IS_VIRTUAL:
+
+.. _class_TextServer_constant_GRAPHEME_IS_SPACE:
+
+.. _class_TextServer_constant_GRAPHEME_IS_BREAK_HARD:
+
+.. _class_TextServer_constant_GRAPHEME_IS_BREAK_SOFT:
+
+.. _class_TextServer_constant_GRAPHEME_IS_TAB:
+
+.. _class_TextServer_constant_GRAPHEME_IS_ELONGATION:
+
+enum **GraphemeFlag**:
+
+- **GRAPHEME_IS_RTL** = **2** --- Grapheme is part of right-to-left or bottom-to-top run.
+
+- **GRAPHEME_IS_VIRTUAL** = **4** --- Grapheme is not part of source text, it was added by justification process.
+
+- **GRAPHEME_IS_SPACE** = **8** --- Grapheme is whitespace.
+
+- **GRAPHEME_IS_BREAK_HARD** = **16** --- Grapheme is mandatory break point (e.g. ``"\n"``).
+
+- **GRAPHEME_IS_BREAK_SOFT** = **32** --- Grapheme is optional break point (e.g. space).
+
+- **GRAPHEME_IS_TAB** = **64** --- Grapheme is the tabulation character.
+
+- **GRAPHEME_IS_ELONGATION** = **128** --- Grapheme is kashida.
+
+----
+
+.. _enum_TextServer_Hinting:
+
+.. _class_TextServer_constant_HINTING_NONE:
+
+.. _class_TextServer_constant_HINTING_LIGHT:
+
+.. _class_TextServer_constant_HINTING_NORMAL:
+
+enum **Hinting**:
+
+- **HINTING_NONE** = **0** --- Disables font hinting (smoother but less crisp).
+
+- **HINTING_LIGHT** = **1** --- Use the light font hinting mode.
+
+- **HINTING_NORMAL** = **2** --- Use the default font hinting mode (crisper but less smooth).
+
+----
+
+.. _enum_TextServer_Feature:
+
+.. _class_TextServer_constant_FEATURE_BIDI_LAYOUT:
+
+.. _class_TextServer_constant_FEATURE_VERTICAL_LAYOUT:
+
+.. _class_TextServer_constant_FEATURE_SHAPING:
+
+.. _class_TextServer_constant_FEATURE_KASHIDA_JUSTIFICATION:
+
+.. _class_TextServer_constant_FEATURE_BREAK_ITERATORS:
+
+.. _class_TextServer_constant_FEATURE_FONT_SYSTEM:
+
+.. _class_TextServer_constant_FEATURE_FONT_VARIABLE:
+
+.. _class_TextServer_constant_FEATURE_USE_SUPPORT_DATA:
+
+enum **Feature**:
+
+- **FEATURE_BIDI_LAYOUT** = **1** --- TextServer supports bidirectional layouts.
+
+- **FEATURE_VERTICAL_LAYOUT** = **2** --- TextServer supports vertical layouts.
+
+- **FEATURE_SHAPING** = **4** --- TextServer supports complex text shaping.
+
+- **FEATURE_KASHIDA_JUSTIFICATION** = **8** --- TextServer supports justification using kashidas.
+
+- **FEATURE_BREAK_ITERATORS** = **16** --- TextServer supports complex line/word breaking rules (e.g. dictionary based).
+
+- **FEATURE_FONT_SYSTEM** = **32** --- TextServer supports loading system fonts.
+
+- **FEATURE_FONT_VARIABLE** = **64**
+
+- **FEATURE_USE_SUPPORT_DATA** = **128**
+
+Method Descriptions
+-------------------
+
+.. _class_TextServer_method_create_font_memory:
+
+- :ref:`RID<class_RID>` **create_font_memory** **(** :ref:`PackedByteArray<class_PackedByteArray>` data, :ref:`String<class_String>` type, :ref:`int<class_int>` base_size=16 **)**
+
+Creates new font from the data in memory. To free the resulting font, use :ref:`free_rid<class_TextServer_method_free_rid>` method.
+
+Note: For non-scalable fonts ``base_size`` is ignored, use :ref:`font_get_base_size<class_TextServer_method_font_get_base_size>` to check actual font size.
+
+----
+
+.. _class_TextServer_method_create_font_resource:
+
+- :ref:`RID<class_RID>` **create_font_resource** **(** :ref:`String<class_String>` filename, :ref:`int<class_int>` base_size=16 **)**
+
+Creates new font from the file. To free the resulting font, use :ref:`free_rid<class_TextServer_method_free_rid>` method.
+
+Note: For non-scalable fonts ``base_size`` is ignored, use :ref:`font_get_base_size<class_TextServer_method_font_get_base_size>` to check actual font size.
+
+----
+
+.. _class_TextServer_method_create_font_system:
+
+- :ref:`RID<class_RID>` **create_font_system** **(** :ref:`String<class_String>` name, :ref:`int<class_int>` base_size=16 **)**
+
+Creates new font from the system font. To free the resulting font, use :ref:`free_rid<class_TextServer_method_free_rid>` method.
+
+Note: This method is supported by servers with the ``FEATURE_FONT_SYSTEM`` feature.
+
+Note: For non-scalable fonts ``base_size`` is ignored, use :ref:`font_get_base_size<class_TextServer_method_font_get_base_size>` to check actual font size.
+
+----
+
+.. _class_TextServer_method_create_shaped_text:
+
+- :ref:`RID<class_RID>` **create_shaped_text** **(** :ref:`Direction<enum_TextServer_Direction>` direction=0, :ref:`Orientation<enum_TextServer_Orientation>` orientation=0 **)**
+
+Creates new buffer for complex text layout, with the given ``direction`` and ``orientation``. To free the resulting buffer, use :ref:`free_rid<class_TextServer_method_free_rid>` method.
+
+Note: Direction is ignored if server does not support ``FEATURE_BIDI_LAYOUT`` feature.
+
+Note: Orientation is ignored if server does not support ``FEATURE_VERTICAL_LAYOUT`` feature.
+
+----
+
+.. _class_TextServer_method_draw_hex_code_box:
+
+- void **draw_hex_code_box** **(** :ref:`RID<class_RID>` canvas, :ref:`int<class_int>` size, :ref:`Vector2<class_Vector2>` pos, :ref:`int<class_int>` index, :ref:`Color<class_Color>` color **)** |const|
+
+Draws box displaying character hexadecimal code. Used for replacing missing characters.
+
+----
+
+.. _class_TextServer_method_font_draw_glyph:
+
+- :ref:`Vector2<class_Vector2>` **font_draw_glyph** **(** :ref:`RID<class_RID>` font, :ref:`RID<class_RID>` canvas, :ref:`int<class_int>` size, :ref:`Vector2<class_Vector2>` pos, :ref:`int<class_int>` index, :ref:`Color<class_Color>` color=Color( 1, 1, 1, 1 ) **)** |const|
+
+Draws single glyph into a canvas item at the position, using ``font`` at the size ``size``.
+
+Note: Glyph index is specific to the font, use glyphs indices returned by :ref:`shaped_text_get_glyphs<class_TextServer_method_shaped_text_get_glyphs>` or :ref:`font_get_glyph_index<class_TextServer_method_font_get_glyph_index>`.
+
+----
+
+.. _class_TextServer_method_font_draw_glyph_outline:
+
+- :ref:`Vector2<class_Vector2>` **font_draw_glyph_outline** **(** :ref:`RID<class_RID>` font, :ref:`RID<class_RID>` canvas, :ref:`int<class_int>` size, :ref:`int<class_int>` outline_size, :ref:`Vector2<class_Vector2>` pos, :ref:`int<class_int>` index, :ref:`Color<class_Color>` color=Color( 1, 1, 1, 1 ) **)** |const|
+
+Draws single glyph outline of size ``outline_size`` into a canvas item at the position, using ``font`` at the size ``size``.
+
+Note: Glyph index is specific to the font, use glyphs indices returned by :ref:`shaped_text_get_glyphs<class_TextServer_method_shaped_text_get_glyphs>` or :ref:`font_get_glyph_index<class_TextServer_method_font_get_glyph_index>`.
+
+----
+
+.. _class_TextServer_method_font_get_antialiased:
+
+- :ref:`bool<class_bool>` **font_get_antialiased** **(** :ref:`RID<class_RID>` font **)** |const|
+
+Returns ``true``, if font anti-aliasing is supported and enabled.
+
+----
+
+.. _class_TextServer_method_font_get_ascent:
+
+- :ref:`float<class_float>` **font_get_ascent** **(** :ref:`RID<class_RID>` font, :ref:`int<class_int>` size **)** |const|
+
+Returns the font ascent (number of pixels above the baseline).
+
+----
+
+.. _class_TextServer_method_font_get_base_size:
+
+- :ref:`float<class_float>` **font_get_base_size** **(** :ref:`RID<class_RID>` font **)** |const|
+
+Returns the default size of the font.
+
+----
+
+.. _class_TextServer_method_font_get_descent:
+
+- :ref:`float<class_float>` **font_get_descent** **(** :ref:`RID<class_RID>` font, :ref:`int<class_int>` size **)** |const|
+
+Returns the font descent (number of pixels below the baseline).
+
+----
+
+.. _class_TextServer_method_font_get_distance_field_hint:
+
+- :ref:`bool<class_bool>` **font_get_distance_field_hint** **(** :ref:`RID<class_RID>` font **)** |const|
+
+Returns ``true``, if distance field hint is enabled.
+
+----
+
+.. _class_TextServer_method_font_get_force_autohinter:
+
+- :ref:`bool<class_bool>` **font_get_force_autohinter** **(** :ref:`RID<class_RID>` font **)** |const|
+
+Returns ``true``, if autohinter is supported and enabled.
+
+----
+
+.. _class_TextServer_method_font_get_glyph_advance:
+
+- :ref:`Vector2<class_Vector2>` **font_get_glyph_advance** **(** :ref:`RID<class_RID>` font, :ref:`int<class_int>` index, :ref:`int<class_int>` size **)** |const|
+
+Returns advance of the glyph.
+
+----
+
+.. _class_TextServer_method_font_get_glyph_index:
+
+- :ref:`int<class_int>` **font_get_glyph_index** **(** :ref:`RID<class_RID>` font, :ref:`int<class_int>` char, :ref:`int<class_int>` variation_selector=0 **)** |const|
+
+Returns the glyph index of a ``char``, optionally modified by the ``variation_selector``.
+
+----
+
+.. _class_TextServer_method_font_get_glyph_kerning:
+
+- :ref:`Vector2<class_Vector2>` **font_get_glyph_kerning** **(** :ref:`RID<class_RID>` font, :ref:`int<class_int>` index_a, :ref:`int<class_int>` index_b, :ref:`int<class_int>` size **)** |const|
+
+Returns a kerning of the pair of glyphs.
+
+----
+
+.. _class_TextServer_method_font_get_height:
+
+- :ref:`float<class_float>` **font_get_height** **(** :ref:`RID<class_RID>` font, :ref:`int<class_int>` size **)** |const|
+
+Returns the total font height (ascent plus descent) in pixels.
+
+----
+
+.. _class_TextServer_method_font_get_hinting:
+
+- :ref:`Hinting<enum_TextServer_Hinting>` **font_get_hinting** **(** :ref:`RID<class_RID>` font **)** |const|
+
+Returns the font hinting.
+
+----
+
+.. _class_TextServer_method_font_get_language_support_override:
+
+- :ref:`bool<class_bool>` **font_get_language_support_override** **(** :ref:`RID<class_RID>` font, :ref:`String<class_String>` language **)**
+
+Returns ``true`` if support override is enabled for the ``language``.
+
+----
+
+.. _class_TextServer_method_font_get_language_support_overrides:
+
+- :ref:`PackedStringArray<class_PackedStringArray>` **font_get_language_support_overrides** **(** :ref:`RID<class_RID>` font **)**
+
+Returns list of language support overrides.
+
+----
+
+.. _class_TextServer_method_font_get_oversampling:
+
+- :ref:`float<class_float>` **font_get_oversampling** **(** **)** |const|
+
+Returns the font oversampling factor, shared by all fonts in the TextServer.
+
+----
+
+.. _class_TextServer_method_font_get_script_support_override:
+
+- :ref:`bool<class_bool>` **font_get_script_support_override** **(** :ref:`RID<class_RID>` font, :ref:`String<class_String>` script **)**
+
+Returns ``true`` if support override is enabled for the ``script``.
+
+----
+
+.. _class_TextServer_method_font_get_script_support_overrides:
+
+- :ref:`PackedStringArray<class_PackedStringArray>` **font_get_script_support_overrides** **(** :ref:`RID<class_RID>` font **)**
+
+Returns list of script support overrides.
+
+----
+
+.. _class_TextServer_method_font_get_supported_chars:
+
+- :ref:`String<class_String>` **font_get_supported_chars** **(** :ref:`RID<class_RID>` font **)** |const|
+
+Returns a string containing all the characters available in the font.
+
+----
+
+.. _class_TextServer_method_font_get_underline_position:
+
+- :ref:`float<class_float>` **font_get_underline_position** **(** :ref:`RID<class_RID>` font, :ref:`int<class_int>` size **)** |const|
+
+Returns underline offset (number of pixels below the baseline).
+
+----
+
+.. _class_TextServer_method_font_get_underline_thickness:
+
+- :ref:`float<class_float>` **font_get_underline_thickness** **(** :ref:`RID<class_RID>` font, :ref:`int<class_int>` size **)** |const|
+
+Returns underline thickness in pixels.
+
+----
+
+.. _class_TextServer_method_font_get_variation_list:
+
+- :ref:`String<class_String>` **font_get_variation_list** **(** :ref:`RID<class_RID>` fonte **)** |const|
+
+Returns ``";"`` separated list of supported variation coordinates, each coordinate is returned in the following format: ``"tag,min_value,max_value,default_value"``.
+
+----
+
+.. _class_TextServer_method_font_get_variations:
+
+- :ref:`String<class_String>` **font_get_variations** **(** :ref:`RID<class_RID>` font **)** |const|
+
+Returns variation coordinates. Returned string is identical to the string set by :ref:`font_set_variations<class_TextServer_method_font_set_variations>`, to get default values use :ref:`font_get_variation_list<class_TextServer_method_font_get_variation_list>` instead.
+
+----
+
+.. _class_TextServer_method_font_has_char:
+
+- :ref:`bool<class_bool>` **font_has_char** **(** :ref:`RID<class_RID>` font, :ref:`int<class_int>` char **)** |const|
+
+Returns ``true`` if ``char`` is available in the font.
+
+----
+
+.. _class_TextServer_method_font_has_outline:
+
+- :ref:`bool<class_bool>` **font_has_outline** **(** :ref:`RID<class_RID>` font **)** |const|
+
+Returns ``true``, if font supports glyph outlines.
+
+----
+
+.. _class_TextServer_method_font_is_language_supported:
+
+- :ref:`bool<class_bool>` **font_is_language_supported** **(** :ref:`RID<class_RID>` font, :ref:`String<class_String>` language **)** |const|
+
+Returns ``true``, if font supports given language (ISO 639 code).
+
+----
+
+.. _class_TextServer_method_font_is_script_supported:
+
+- :ref:`bool<class_bool>` **font_is_script_supported** **(** :ref:`RID<class_RID>` font, :ref:`String<class_String>` script **)** |const|
+
+Returns ``true``, if font supports given script (ISO 15924 code).
+
+----
+
+.. _class_TextServer_method_font_remove_language_support_override:
+
+- void **font_remove_language_support_override** **(** :ref:`RID<class_RID>` font, :ref:`String<class_String>` language **)**
+
+Remove language support override.
+
+----
+
+.. _class_TextServer_method_font_remove_script_support_override:
+
+- void **font_remove_script_support_override** **(** :ref:`RID<class_RID>` font, :ref:`String<class_String>` script **)**
+
+Removes script support override.
+
+----
+
+.. _class_TextServer_method_font_set_antialiased:
+
+- void **font_set_antialiased** **(** :ref:`RID<class_RID>` font, :ref:`bool<class_bool>` antialiased **)**
+
+Sets font anti-aliasing.
+
+----
+
+.. _class_TextServer_method_font_set_distance_field_hint:
+
+- void **font_set_distance_field_hint** **(** :ref:`RID<class_RID>` font, :ref:`bool<class_bool>` distance_field **)**
+
+Sets font distance field hint.
+
+----
+
+.. _class_TextServer_method_font_set_force_autohinter:
+
+- void **font_set_force_autohinter** **(** :ref:`RID<class_RID>` font, :ref:`bool<class_bool>` enabeld **)**
+
+----
+
+.. _class_TextServer_method_font_set_hinting:
+
+- void **font_set_hinting** **(** :ref:`RID<class_RID>` font, :ref:`Hinting<enum_TextServer_Hinting>` hinting **)**
+
+Sets font hinting.
+
+----
+
+.. _class_TextServer_method_font_set_language_support_override:
+
+- void **font_set_language_support_override** **(** :ref:`RID<class_RID>` font, :ref:`String<class_String>` language, :ref:`bool<class_bool>` supported **)**
+
+Adds override for :ref:`font_is_language_supported<class_TextServer_method_font_is_language_supported>`.
+
+----
+
+.. _class_TextServer_method_font_set_oversampling:
+
+- void **font_set_oversampling** **(** :ref:`float<class_float>` oversampling **)**
+
+Sets oversampling factor, shared by all font in the TextServer.
+
+----
+
+.. _class_TextServer_method_font_set_script_support_override:
+
+- void **font_set_script_support_override** **(** :ref:`RID<class_RID>` font, :ref:`String<class_String>` script, :ref:`bool<class_bool>` supported **)**
+
+Adds override for :ref:`font_is_script_supported<class_TextServer_method_font_is_script_supported>`.
+
+----
+
+.. _class_TextServer_method_font_set_variations:
+
+- void **font_set_variations** **(** :ref:`RID<class_RID>` font, :ref:`String<class_String>` value **)**
+
+Sets variation coordinates, ``value`` is a comma separated list of the in the ``"tag=value"`` format. Tags are case-sensitive. Unsupported or incorrectly formatted coordinates will be silently ignored.
+
+----
+
+.. _class_TextServer_method_format_number:
+
+- :ref:`String<class_String>` **format_number** **(** :ref:`String<class_String>` number, :ref:`String<class_String>` language="" **)** |const|
+
+Convert a number from the Western Arabic (0..9) to the numeral systems used in ``language``.
+
+----
+
+.. _class_TextServer_method_free_rid:
+
+- void **free_rid** **(** :ref:`RID<class_RID>` rid **)**
+
+Frees an object created by this ``TextServer``.
+
+----
+
+.. _class_TextServer_method_get_hex_code_box_size:
+
+- :ref:`Vector2<class_Vector2>` **get_hex_code_box_size** **(** :ref:`int<class_int>` size, :ref:`int<class_int>` index **)** |const|
+
+----
+
+.. _class_TextServer_method_get_name:
+
+- :ref:`String<class_String>` **get_name** **(** **)** |const|
+
+Returns the name of the server interface.
+
+----
+
+.. _class_TextServer_method_get_system_fonts:
+
+- :ref:`PackedStringArray<class_PackedStringArray>` **get_system_fonts** **(** **)** |const|
+
+Returns list of available system fonts.
+
+Note: This method is supported by servers with the ``FEATURE_FONT_SYSTEM`` feature.
+
+----
+
+.. _class_TextServer_method_has:
+
+- :ref:`bool<class_bool>` **has** **(** :ref:`RID<class_RID>` rid **)**
+
+Returns ``true`` if ``rid`` is valid resource owned by this text server.
+
+----
+
+.. _class_TextServer_method_has_feature:
+
+- :ref:`bool<class_bool>` **has_feature** **(** :ref:`Feature<enum_TextServer_Feature>` feature **)**
+
+Returns ``true`` if the server supports a feature.
+
+----
+
+.. _class_TextServer_method_is_locale_right_to_left:
+
+- :ref:`bool<class_bool>` **is_locale_right_to_left** **(** :ref:`String<class_String>` locale **)**
+
+Returns ``true`` if locale is right-to-left.
+
+----
+
+.. _class_TextServer_method_load_support_data:
+
+- :ref:`bool<class_bool>` **load_support_data** **(** :ref:`String<class_String>` filename **)**
+
+Loads optional TextServer database (e.g. ICU break iterators and dictionaries).
+
+Note: This function should be called before any other TextServer functions used, otherwise it won't have any effect.
+
+----
+
+.. _class_TextServer_method_parse_number:
+
+- :ref:`String<class_String>` **parse_number** **(** :ref:`String<class_String>` number, :ref:`String<class_String>` language="" **)** |const|
+
+Convert a number from the numeral systems used in ``language`` to Western Arabic (0..9).
+
+----
+
+.. _class_TextServer_method_percent_sign:
+
+- :ref:`String<class_String>` **percent_sign** **(** :ref:`String<class_String>` language="" **)** |const|
+
+Returns percent sign used in the ``language``.
+
+----
+
+.. _class_TextServer_method_shaped_text_add_object:
+
+- :ref:`bool<class_bool>` **shaped_text_add_object** **(** :ref:`RID<class_RID>` shaped, :ref:`Variant<class_Variant>` key, :ref:`Vector2<class_Vector2>` size, :ref:`VAlign<enum_@GlobalScope_VAlign>` inline_align=1 **)**
+
+Adds inline object to the text buffer, ``key`` must be unique.
+
+----
+
+.. _class_TextServer_method_shaped_text_add_string:
+
+- :ref:`bool<class_bool>` **shaped_text_add_string** **(** :ref:`RID<class_RID>` shaped, :ref:`String<class_String>` text, :ref:`Array<class_Array>` fonts, :ref:`int<class_int>` size, :ref:`String<class_String>` opentype_features="", :ref:`String<class_String>` language="" **)**
+
+Adds text span and font to draw it to the text buffer.
+
+----
+
+.. _class_TextServer_method_shaped_text_clear:
+
+- void **shaped_text_clear** **(** :ref:`RID<class_RID>` arg0 **)**
+
+Clears text buffer (removes text and inline objects).
+
+----
+
+.. _class_TextServer_method_shaped_text_draw:
+
+- void **shaped_text_draw** **(** :ref:`RID<class_RID>` shaped, :ref:`RID<class_RID>` canvas, :ref:`Vector2<class_Vector2>` pos, :ref:`float<class_float>` clip_w=-1, :ref:`Color<class_Color>` color=Color( 1, 1, 1, 1 ) **)** |const|
+
+Draw shaped text into a canvas item at a given position, with ``color``. ``pos`` specifies the leftmost point of the baseline (for horizontal layout) or topmost point of the baseline (for vertical layout).
+
+----
+
+.. _class_TextServer_method_shaped_text_draw_outline:
+
+- void **shaped_text_draw_outline** **(** :ref:`RID<class_RID>` shaped, :ref:`RID<class_RID>` canvas, :ref:`Vector2<class_Vector2>` pos, :ref:`float<class_float>` clip_w=-1, :ref:`int<class_int>` outline_size=1, :ref:`Color<class_Color>` color=Color( 1, 1, 1, 1 ) **)** |const|
+
+Draw the outline of the shaped text into a canvas item at a given position, with ``color``. ``pos`` specifies the leftmost point of the baseline (for horizontal layout) or topmost point of the baseline (for vertical layout).
+
+----
+
+.. _class_TextServer_method_shaped_text_fit_to_width:
+
+- :ref:`float<class_float>` **shaped_text_fit_to_width** **(** :ref:`RID<class_RID>` shaped, :ref:`float<class_float>` width, :ref:`int<class_int>` jst_flags=48 **)**
+
+Adjusts text with to fit to specified width, returns new text width.
+
+----
+
+.. _class_TextServer_method_shaped_text_get_ascent:
+
+- :ref:`float<class_float>` **shaped_text_get_ascent** **(** :ref:`RID<class_RID>` shaped **)** |const|
+
+Returns the text ascent (number of pixels above the baseline for horizontal layout or to the left of baseline for vertical).
+
+Note: overall ascent can be higher than font ascent, if some glyphs are displaced from the baseline.
+
+----
+
+.. _class_TextServer_method_shaped_text_get_carets:
+
+- :ref:`Dictionary<class_Dictionary>` **shaped_text_get_carets** **(** :ref:`RID<class_RID>` shaped, :ref:`int<class_int>` position **)** |const|
+
+Returns shapes of the carets corresponding to the character offset ``position`` in the text. Returned caret shape is 1 pixel wide rectangle.
+
+----
+
+.. _class_TextServer_method_shaped_text_get_descent:
+
+- :ref:`float<class_float>` **shaped_text_get_descent** **(** :ref:`RID<class_RID>` shaped **)** |const|
+
+Returns the text descent (number of pixels below the baseline for horizontal layout or to the right of baseline for vertical).
+
+Note: overall descent can be higher than font descent, if some glyphs are displaced from the baseline.
+
+----
+
+.. _class_TextServer_method_shaped_text_get_direction:
+
+- :ref:`Direction<enum_TextServer_Direction>` **shaped_text_get_direction** **(** :ref:`RID<class_RID>` shaped **)** |const|
+
+Returns direction of the text.
+
+----
+
+.. _class_TextServer_method_shaped_text_get_dominant_direciton_in_range:
+
+- :ref:`Direction<enum_TextServer_Direction>` **shaped_text_get_dominant_direciton_in_range** **(** :ref:`RID<class_RID>` shaped, :ref:`int<class_int>` start, :ref:`int<class_int>` end **)** |const|
+
+Returns dominant direction of in the range of text.
+
+----
+
+.. _class_TextServer_method_shaped_text_get_glyphs:
+
+- :ref:`Array<class_Array>` **shaped_text_get_glyphs** **(** :ref:`RID<class_RID>` shaped **)** |const|
+
+Returns text glyphs.
+
+----
+
+.. _class_TextServer_method_shaped_text_get_line_breaks:
+
+- :ref:`Array<class_Array>` **shaped_text_get_line_breaks** **(** :ref:`RID<class_RID>` shaped, :ref:`float<class_float>` width, :ref:`int<class_int>` start=0, :ref:`int<class_int>` break_flags=3 **)** |const|
+
+Breaks text to the lines and returns character ranges for each line.
+
+----
+
+.. _class_TextServer_method_shaped_text_get_line_breaks_adv:
+
+- :ref:`Array<class_Array>` **shaped_text_get_line_breaks_adv** **(** :ref:`RID<class_RID>` shaped, :ref:`PackedFloat32Array<class_PackedFloat32Array>` width, :ref:`int<class_int>` start=0, :ref:`bool<class_bool>` once=true, :ref:`int<class_int>` break_flags=3 **)** |const|
+
+Breaks text to the lines and columns. Returns character ranges for each segment.
+
+----
+
+.. _class_TextServer_method_shaped_text_get_object_rect:
+
+- :ref:`Rect2<class_Rect2>` **shaped_text_get_object_rect** **(** :ref:`RID<class_RID>` shaped, :ref:`Variant<class_Variant>` key **)** |const|
+
+Returns bounding rectangle of the inline object.
+
+----
+
+.. _class_TextServer_method_shaped_text_get_objects:
+
+- :ref:`Array<class_Array>` **shaped_text_get_objects** **(** :ref:`RID<class_RID>` shaped **)** |const|
+
+Returns array of inline objects.
+
+----
+
+.. _class_TextServer_method_shaped_text_get_orientation:
+
+- :ref:`Orientation<enum_TextServer_Orientation>` **shaped_text_get_orientation** **(** :ref:`RID<class_RID>` shaped **)** |const|
+
+Returns text orientation.
+
+----
+
+.. _class_TextServer_method_shaped_text_get_parent:
+
+- :ref:`RID<class_RID>` **shaped_text_get_parent** **(** :ref:`RID<class_RID>` shaped **)** |const|
+
+Sets text orientation.
+
+----
+
+.. _class_TextServer_method_shaped_text_get_preserve_control:
+
+- :ref:`bool<class_bool>` **shaped_text_get_preserve_control** **(** :ref:`RID<class_RID>` shaped **)** |const|
+
+Returns ``true`` if text buffer is configured to display control characters.
+
+----
+
+.. _class_TextServer_method_shaped_text_get_preserve_invalid:
+
+- :ref:`bool<class_bool>` **shaped_text_get_preserve_invalid** **(** :ref:`RID<class_RID>` shaped **)** |const|
+
+Returns ``true`` if text buffer is configured to display hexadecimal codes in place of invalid characters.
+
+Note: If set to ``false``, nothing is displayed  in place of invalid characters.
+
+----
+
+.. _class_TextServer_method_shaped_text_get_range:
+
+- :ref:`Vector2i<class_Vector2i>` **shaped_text_get_range** **(** :ref:`RID<class_RID>` shaped **)** |const|
+
+Returns substring buffer character range in the parent buffer.
+
+----
+
+.. _class_TextServer_method_shaped_text_get_selection:
+
+- :ref:`Array<class_Array>` **shaped_text_get_selection** **(** :ref:`RID<class_RID>` shaped, :ref:`int<class_int>` start, :ref:`int<class_int>` end **)** |const|
+
+Returns selection rectangles for the specified character range.
+
+----
+
+.. _class_TextServer_method_shaped_text_get_size:
+
+- :ref:`Vector2<class_Vector2>` **shaped_text_get_size** **(** :ref:`RID<class_RID>` shaped **)** |const|
+
+Returns size of the text.
+
+----
+
+.. _class_TextServer_method_shaped_text_get_underline_position:
+
+- :ref:`float<class_float>` **shaped_text_get_underline_position** **(** :ref:`RID<class_RID>` shaped **)** |const|
+
+Returns pixel offset of the underline below the baseline.
+
+----
+
+.. _class_TextServer_method_shaped_text_get_underline_thickness:
+
+- :ref:`float<class_float>` **shaped_text_get_underline_thickness** **(** :ref:`RID<class_RID>` shaped **)** |const|
+
+Returns thickness of the underline.
+
+----
+
+.. _class_TextServer_method_shaped_text_get_width:
+
+- :ref:`float<class_float>` **shaped_text_get_width** **(** :ref:`RID<class_RID>` shaped **)** |const|
+
+Returns width (for horizontal layout) or height (for vertical) of the text.
+
+----
+
+.. _class_TextServer_method_shaped_text_get_word_breaks:
+
+- :ref:`Array<class_Array>` **shaped_text_get_word_breaks** **(** :ref:`RID<class_RID>` shaped **)** |const|
+
+Breaks text into words and returns array of character ranges.
+
+----
+
+.. _class_TextServer_method_shaped_text_hit_test_grapheme:
+
+- :ref:`int<class_int>` **shaped_text_hit_test_grapheme** **(** :ref:`RID<class_RID>` shaped, :ref:`float<class_float>` coords **)** |const|
+
+Returns grapheme index at the specified pixel offset at the baseline, or ``-1`` if none is found.
+
+----
+
+.. _class_TextServer_method_shaped_text_hit_test_position:
+
+- :ref:`int<class_int>` **shaped_text_hit_test_position** **(** :ref:`RID<class_RID>` shaped, :ref:`float<class_float>` coords **)** |const|
+
+Returns caret character offset at the specified pixel offset at the baseline. This function always returns a valid position.
+
+----
+
+.. _class_TextServer_method_shaped_text_is_ready:
+
+- :ref:`bool<class_bool>` **shaped_text_is_ready** **(** :ref:`RID<class_RID>` shaped **)** |const|
+
+Returns ``true`` if buffer is successfully shaped.
+
+----
+
+.. _class_TextServer_method_shaped_text_next_grapheme_pos:
+
+- :ref:`int<class_int>` **shaped_text_next_grapheme_pos** **(** :ref:`RID<class_RID>` shaped, :ref:`int<class_int>` pos **)**
+
+Returns composite character end position closest to the ``pos``.
+
+----
+
+.. _class_TextServer_method_shaped_text_prev_grapheme_pos:
+
+- :ref:`int<class_int>` **shaped_text_prev_grapheme_pos** **(** :ref:`RID<class_RID>` shaped, :ref:`int<class_int>` pos **)**
+
+Returns composite character start position closest to the ``pos``.
+
+----
+
+.. _class_TextServer_method_shaped_text_set_bidi_override:
+
+- void **shaped_text_set_bidi_override** **(** :ref:`RID<class_RID>` shaped, :ref:`Array<class_Array>` override **)**
+
+Overrides BiDi for the structured text.
+
+Override ranges should cover full source text without overlaps. BiDi algorithm will be used on each range separately.
+
+----
+
+.. _class_TextServer_method_shaped_text_set_direction:
+
+- void **shaped_text_set_direction** **(** :ref:`RID<class_RID>` shaped, :ref:`Direction<enum_TextServer_Direction>` direction=0 **)**
+
+Sets desired text direction. If set to ``TEXT_DIRECTION_AUTO``, direction will be detected based on the buffer contents and current locale.
+
+Note: Direction is ignored if server does not support ``FEATURE_BIDI_LAYOUT`` feature.
+
+----
+
+.. _class_TextServer_method_shaped_text_set_orientation:
+
+- void **shaped_text_set_orientation** **(** :ref:`RID<class_RID>` shaped, :ref:`Orientation<enum_TextServer_Orientation>` orientation=0 **)**
+
+Sets desired text orientation.
+
+Note: Orientation is ignored if server does not support ``FEATURE_VERTICAL_LAYOUT`` feature.
+
+----
+
+.. _class_TextServer_method_shaped_text_set_preserve_control:
+
+- void **shaped_text_set_preserve_control** **(** :ref:`RID<class_RID>` shaped, :ref:`bool<class_bool>` enabled **)**
+
+If set to ``true`` text buffer will display control characters.
+
+----
+
+.. _class_TextServer_method_shaped_text_set_preserve_invalid:
+
+- void **shaped_text_set_preserve_invalid** **(** :ref:`RID<class_RID>` shaped, :ref:`bool<class_bool>` enabled **)**
+
+If set to ``true`` text buffer will display invalid characters as hexadecimal codes, otherwise nothing is displayed.
+
+----
+
+.. _class_TextServer_method_shaped_text_shape:
+
+- :ref:`bool<class_bool>` **shaped_text_shape** **(** :ref:`RID<class_RID>` shaped **)**
+
+Shapes buffer if it's not shaped. Returns ``true`` if the string is shaped successfully.
+
+Note: It is not necessary to call this function manually, buffer will be shaped automatically as soon as any of its output data is requested.
+
+----
+
+.. _class_TextServer_method_shaped_text_substr:
+
+- :ref:`RID<class_RID>` **shaped_text_substr** **(** :ref:`RID<class_RID>` shaped, :ref:`int<class_int>` start, :ref:`int<class_int>` length **)** |const|
+
+Returns text buffer for the substring of the text in the ``shaped`` text buffer (including inline objects).
+
+----
+
+.. _class_TextServer_method_shaped_text_tab_align:
+
+- :ref:`float<class_float>` **shaped_text_tab_align** **(** :ref:`RID<class_RID>` shaped, :ref:`PackedFloat32Array<class_PackedFloat32Array>` tab_stops **)**
+
+Aligns shaped text to the given tab-stops.
+
+.. |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.)`

+ 111 - 0
classes/class_textservermanager.rst

@@ -0,0 +1,111 @@
+:github_url: hide
+
+.. Generated automatically by doc/tools/makerst.py in Godot's source tree.
+.. DO NOT EDIT THIS FILE, but the TextServerManager.xml source instead.
+.. The source is found in doc/classes or modules/<name>/doc_classes.
+
+.. _class_TextServerManager:
+
+TextServerManager
+=================
+
+**Inherits:** :ref:`Object<class_Object>`
+
+Manager for the font and complex text layout servers.
+
+Description
+-----------
+
+``TextServerManager`` is the API backend for loading, enumeration and switching :ref:`TextServer<class_TextServer>`\ s.
+
+Note: Switching text server at runtime is possible, but will invalidate all fonts and text buffers. Make sure to unload all controls, fonts, and themes before doing so.
+
+Methods
+-------
+
++-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`TextServer<class_TextServer>` | :ref:`find_interface<class_TextServerManager_method_find_interface>` **(** :ref:`String<class_String>` name **)** |const|            |
++-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`TextServer<class_TextServer>` | :ref:`get_interface<class_TextServerManager_method_get_interface>` **(** :ref:`int<class_int>` index **)** |const|                   |
++-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`int<class_int>`               | :ref:`get_interface_count<class_TextServerManager_method_get_interface_count>` **(** **)** |const|                                   |
++-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`int<class_int>`               | :ref:`get_interface_features<class_TextServerManager_method_get_interface_features>` **(** :ref:`int<class_int>` index **)** |const| |
++-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`String<class_String>`         | :ref:`get_interface_name<class_TextServerManager_method_get_interface_name>` **(** :ref:`int<class_int>` index **)** |const|         |
++-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`Array<class_Array>`           | :ref:`get_interfaces<class_TextServerManager_method_get_interfaces>` **(** **)** |const|                                             |
++-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`TextServer<class_TextServer>` | :ref:`get_primary_interface<class_TextServerManager_method_get_primary_interface>` **(** **)** |const|                               |
++-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------+
+| :ref:`bool<class_bool>`             | :ref:`set_primary_interface<class_TextServerManager_method_set_primary_interface>` **(** :ref:`int<class_int>` index **)**           |
++-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------+
+
+Method Descriptions
+-------------------
+
+.. _class_TextServerManager_method_find_interface:
+
+- :ref:`TextServer<class_TextServer>` **find_interface** **(** :ref:`String<class_String>` name **)** |const|
+
+Finds an interface by its name.
+
+----
+
+.. _class_TextServerManager_method_get_interface:
+
+- :ref:`TextServer<class_TextServer>` **get_interface** **(** :ref:`int<class_int>` index **)** |const|
+
+Returns the interface registered at a given index.
+
+----
+
+.. _class_TextServerManager_method_get_interface_count:
+
+- :ref:`int<class_int>` **get_interface_count** **(** **)** |const|
+
+Returns the number of interfaces currently registered.
+
+----
+
+.. _class_TextServerManager_method_get_interface_features:
+
+- :ref:`int<class_int>` **get_interface_features** **(** :ref:`int<class_int>` index **)** |const|
+
+Returns text server supported features (binary OR).
+
+----
+
+.. _class_TextServerManager_method_get_interface_name:
+
+- :ref:`String<class_String>` **get_interface_name** **(** :ref:`int<class_int>` index **)** |const|
+
+Returns the interface name registered at a given index.
+
+----
+
+.. _class_TextServerManager_method_get_interfaces:
+
+- :ref:`Array<class_Array>` **get_interfaces** **(** **)** |const|
+
+Returns a list of available interfaces the index and name of each interface.
+
+----
+
+.. _class_TextServerManager_method_get_primary_interface:
+
+- :ref:`TextServer<class_TextServer>` **get_primary_interface** **(** **)** |const|
+
+Returns the primary :ref:`TextServer<class_TextServer>` interface.
+
+----
+
+.. _class_TextServerManager_method_set_primary_interface:
+
+- :ref:`bool<class_bool>` **set_primary_interface** **(** :ref:`int<class_int>` index **)**
+
+Sets (and initializes it if required) interface registered at a given index as the primary. Invalidates all references to the fonts and text buffers.
+
+.. |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.)`

+ 4 - 0
community/contributing/editor_and_docs_localization.rst

@@ -243,6 +243,10 @@ The editor translations originate from C++ strings, and may use:
     Scene '%s' is currently being edited.↵
     Changes will only take effect when reloaded.
 
+.. note::
+  Only logical order of the characters matters, in the right-to-left text, format
+  specifiers may be displayed as ``s%``.
+
 Online documentation (RST)
 ^^^^^^^^^^^^^^^^^^^^^^^^^^
 

+ 7 - 5
getting_started/first_2d_game/06.heads_up_display.rst

@@ -36,19 +36,21 @@ Inspector. The default font for ``Control`` nodes is small and doesn't scale
 well. There is a font file included in the game assets called
 "Xolonium-Regular.ttf". To use this font, do the following:
 
-1. Under "Custom Fonts", choose "New DynamicFont"
+1. Under "Custom Fonts", choose "New Font"
 
 .. image:: img/custom_font1.png
 
-2. Click on the "DynamicFont" you added, and under "Font/Font Data", choose
-   "Load" and select the "Xolonium-Regular.ttf" file. You must also set the
-   font's ``Size``. A setting of ``64`` works well.
+2. Click on the "Font" you added, and under "Font/Data/0",
+   choose "Load" and select the "Xolonium-Regular.ttf" file.
 
 .. image:: img/custom_font2.png
 
 Once you've done this on the ``ScoreLabel``, you can click the down arrow next
-to the DynamicFont property and choose "Copy", then "Paste" it in the same place
+to the Font property and choose "Copy", then "Paste" it in the same place
 on the other two Control nodes.
+Set "Custom Font Size" property of the ``ScoreLabel``. A setting of ``64`` works well.
+
+.. image:: img/custom_font3.png
 
 .. note:: **Anchors and Margins:** ``Control`` nodes have a position and size,
           but they also have anchors and margins. Anchors define the origin -

BIN
getting_started/first_2d_game/img/custom_font1.png


BIN
getting_started/first_2d_game/img/custom_font2.png


BIN
getting_started/first_2d_game/img/custom_font3.png


BIN
getting_started/step_by_step/img/custom_font3.png


BIN
tutorials/i18n/img/bidi_override.png


BIN
tutorials/i18n/img/icu_data.png


BIN
tutorials/i18n/img/ui_mirror.png


+ 69 - 0
tutorials/i18n/internationalizing_games.rst

@@ -109,6 +109,75 @@ called the :ref:`TranslationServer <class_TranslationServer>`.
 Translations can be added or removed during run-time;
 the current language can also be changed at run-time.
 
+Bidirectional text and UI Mirroring
+-----------------------------------
+
+Arabic and Hebrew are written from right to left (except for the numbers and Latin
+words mixed in), and the user interface for these languages should be mirrored as well.
+In some languages the shape of a glyph changes depending on the surrounding characters.
+
+Support for bidirectional writing systems and UI mirroring is transparent, you don't
+usually need to change anything or have any knowledge of the specific writing system.
+
+For RTL languages, Godot will automatically do the following changes to the UI:
+
+-  Mirrors left/right anchors and margins.
+-  Swaps left and right text alignment.
+-  Mirrors horizontal order of the child controls in the containers, and items in Tree/ItemList controls.
+-  Uses mirrored order of the internal control elements (e.g. OptionButton dropdown button, checkbox alignment, List column order, Tree item icons and connecting line alignment, e.t.c.), in some cases mirrored controls use separate theme styles.
+-  Coordinate system is not mirrored, and non-UI nodes (sprites, e.t.c) are not affected.x
+
+It is possible to override text and control layout direction by using the following control properties:
+
+-  ``text_direction``, sets the base text direction. When set to "auto", direction depends on the first strong directional character in the text according to the Unicode Bidirectional Algorithm,
+-  ``language``, overrides current project locale.
+-  ``structured_text_bidi_override property`` and ``_structured_text_parser callback``, enables special handling for structured text.
+-  ``layout_direction``, overrides control mirroring.
+
+.. image:: img/ui_mirror.png
+
+Adding break iterator data to exported project
+----------------------------------------------
+
+Some languages are written without spaces, and word and line breaking requires more than rules over character sequences.
+Godot includes ICU rule and dictionary based, break iterator data, but this data is not included into exported projects by default.
+To include it go to **Project → Project Settings → Localization → Text Server Data** and click **Install support data...**. Break iterator data is about 4 MB large.
+
+.. image:: img/icu_data.png
+
+Structured text BiDi override
+-----------------------------
+
+Unicode BiDi algorithm is designed to work with natural text and it's incapable of
+handling text with the higher level order, like file names, URIs, email addresses,
+regular expressions or source code.
+
+.. image:: img/bidi_override.png
+
+For example, the path for this shown directory structure will be displayed incorrectly
+(top "LineEdit" control). "File" type structured text override splits text into segments,
+then BiDi algorithm is applied to each of them individually to correctly display directory
+names in any language and preserve correct order of the folders (bottom "LineEdit" control).
+
+Custom callbacks provide a way to override BiDi for the other types of structured text.
+
+Localizing numbers
+------------------
+
+Controls specifically designed for number input or output (e.g. ProgressBar, SpinBox)
+will use localized numbering system automatically, for the other control
+:ref:`TextServer.format_number(string, language) <class_TextServer_method_format_number>`
+can be used to convert Western Arabic numbers (0..9) to the localized numbering system
+and :ref:`TextServer.parse_number(string, language) <class_TextServer_method_parse_number>`
+to convert it back.
+
+Localizing icons and images
+---------------------------
+
+Icons with left and right pointing arrows which may need to be reversed for Arabic
+and Hebrew locales, in case they indicate movement or direction (e.g. back/forward
+buttons), otherwise they can remain the same.
+
 Command line
 ------------
 

+ 124 - 59
tutorials/ui/bbcode_in_richtextlabel.rst

@@ -50,45 +50,116 @@ markup. All changes to the text must be done in the BBCode parameter.
 Reference
 ---------
 
-+-------------------+--------------------------------------------+-----------------------------------------------------------------+
-| Command           | Tag                                        | Description                                                     |
-+-------------------+--------------------------------------------+-----------------------------------------------------------------+
-| **bold**          | ``[b]{text}[/b]``                          | Makes {text} bold.                                              |
-+-------------------+--------------------------------------------+-----------------------------------------------------------------+
-| **italics**       | ``[i]{text}[/i]``                          | Makes {text} italics.                                           |
-+-------------------+--------------------------------------------+-----------------------------------------------------------------+
-| **underline**     | ``[u]{text}[/u]``                          | Makes {text} underline.                                         |
-+-------------------+--------------------------------------------+-----------------------------------------------------------------+
-| **strikethrough** | ``[s]{text}[/s]``                          | Makes {text} strikethrough.                                     |
-+-------------------+--------------------------------------------+-----------------------------------------------------------------+
-| **code**          | ``[code]{text}[/code]``                    | Makes {text} use the code font (which is typically monospace).  |
-+-------------------+--------------------------------------------+-----------------------------------------------------------------+
-| **center**        | ``[center]{text}[/center]``                | Makes {text} horizontally centered.                             |
-+-------------------+--------------------------------------------+-----------------------------------------------------------------+
-| **right**         | ``[right]{text}[/right]``                  | Makes {text} horizontally right-aligned.                        |
-+-------------------+--------------------------------------------+-----------------------------------------------------------------+
-| **fill**          | ``[fill]{text}[/fill]``                    | Makes {text} fill the RichTextLabel's width.                    |
-+-------------------+--------------------------------------------+-----------------------------------------------------------------+
-| **indent**        | ``[indent]{text}[/indent]``                | Increase the indentation level of {text}.                       |
-+-------------------+--------------------------------------------+-----------------------------------------------------------------+
-| **url**           | ``[url]{url}[/url]``                       | Show {url} as such, underline it and make it clickable.         |
-+-------------------+--------------------------------------------+-----------------------------------------------------------------+
-| **url (ref)**     | ``[url=<url>]{text}[/url]``                | Makes {text} reference <url> (underlined and clickable).        |
-+-------------------+--------------------------------------------+-----------------------------------------------------------------+
-| **image**         | ``[img]{path}[/img]``                      | Insert image at resource {path}.                                |
-+-------------------+--------------------------------------------+-----------------------------------------------------------------+
-| **resized image** | ``[img=<width>]{path}[/img]``              | Insert image at resource {path} using <width> (keeps ratio).    |
-+-------------------+--------------------------------------------+-----------------------------------------------------------------+
-| **resized image** | ``[img=<width>x<height>]{path}[/img]``     | Insert image at resource {path} using <width>×<height>.         |
-+-------------------+--------------------------------------------+-----------------------------------------------------------------+
-| **font**          | ``[font=<path>]{text}[/font]``             | Use custom font at <path> for {text}.                           |
-+-------------------+--------------------------------------------+-----------------------------------------------------------------+
-| **color**         | ``[color=<code/name>]{text}[/color]``      | Change {text} color; use name or # format, such as ``#ff00ff``. |
-+-------------------+--------------------------------------------+-----------------------------------------------------------------+
-| **table**         | ``[table=<number>]{cells}[/table]``        | Creates a table with <number> of columns.                       |
-+-------------------+--------------------------------------------+-----------------------------------------------------------------+
-| **cell**          | ``[cell]{text}[/cell]``                    | Adds cells with the {text} to the table.                        |
-+-------------------+--------------------------------------------+-----------------------------------------------------------------+
++-----------------------+-----------------------------------------------------------+--------------------------------------------------------------------------+
+| Command               | Tag                                                       | Description                                                              |
++-----------------------+-----------------------------------------------------------+--------------------------------------------------------------------------+
+| **bold**              | ``[b]{text}[/b]``                                         | Makes {text} bold.                                                       |
++-----------------------+-----------------------------------------------------------+--------------------------------------------------------------------------+
+| **italics**           | ``[i]{text}[/i]``                                         | Makes {text} italics.                                                    |
++-----------------------+-----------------------------------------------------------+--------------------------------------------------------------------------+
+| **underline**         | ``[u]{text}[/u]``                                         | Makes {text} underline.                                                  |
++-----------------------+-----------------------------------------------------------+--------------------------------------------------------------------------+
+| **strikethrough**     | ``[s]{text}[/s]``                                         | Makes {text} strikethrough.                                              |
++-----------------------+-----------------------------------------------------------+--------------------------------------------------------------------------+
+| **code**              | ``[code]{text}[/code]``                                   | Makes {text} use the code font (which is typically monospace).           |
++-----------------------+-----------------------------------------------------------+--------------------------------------------------------------------------+
+| **p**                 | ``[p {options}]{text}[/p]``                               | Adds new paragraph with {text}. See paragraph options for more info.     |
++-----------------------+-----------------------------------------------------------+--------------------------------------------------------------------------+
+| **center**            | ``[center]{text}[/center]``                               | Makes {text} horizontally centered. Same as ``[p align=center]``.        |
++-----------------------+-----------------------------------------------------------+--------------------------------------------------------------------------+
+| **left**              | ``[left]{text}[/left]``                                   | Makes {text} horizontally right-aligned. Same as ``[p align=left]``.     |
++-----------------------+-----------------------------------------------------------+--------------------------------------------------------------------------+
+| **right**             | ``[right]{text}[/right]``                                 | Makes {text} horizontally right-aligned. Same as ``[p align=right]``.    |
++-----------------------+-----------------------------------------------------------+--------------------------------------------------------------------------+
+| **fill**              | ``[fill]{text}[/fill]``                                   | Makes {text} fill the RichTextLabel's width. Same as ``[p align=fill]``. |
++-----------------------+-----------------------------------------------------------+--------------------------------------------------------------------------+
+| **indent**            | ``[indent]{text}[/indent]``                               | Increase the indentation level of {text}.                                |
++-----------------------+-----------------------------------------------------------+--------------------------------------------------------------------------+
+| **url**               | ``[url]{url}[/url]``                                      | Show {url} as such, underline it and make it clickable.                  |
++-----------------------+-----------------------------------------------------------+--------------------------------------------------------------------------+
+| **url (ref)**         | ``[url=<url>]{text}[/url]``                               | Makes {text} reference <url> (underlined and clickable).                 |
++-----------------------+-----------------------------------------------------------+--------------------------------------------------------------------------+
+| **image**             | ``[img]{path}[/img]``                                     | Insert image at resource {path}.                                         |
++-----------------------+-----------------------------------------------------------+--------------------------------------------------------------------------+
+| **resized image**     | ``[img=<width>]{path}[/img]``                             | Insert image at resource {path} using <width> (keeps ratio).             |
++-----------------------+-----------------------------------------------------------+--------------------------------------------------------------------------+
+| **resized image**     | ``[img=<width>x<height>]{path}[/img]``                    | Insert image at resource {path} using <width>×<height>.                  |
++-----------------------+-----------------------------------------------------------+--------------------------------------------------------------------------+
+| **aligned image**     | ``[img align=<valign>]{path}[/img]``                      | Insert image at resource {path} using <valign> vertical alignment.       |
++-----------------------+-----------------------------------------------------------+--------------------------------------------------------------------------+
+| **font**              | ``[font=<path>]{text}[/font]``                            | Use custom font at <path> for {text}.                                    |
++-----------------------+-----------------------------------------------------------+--------------------------------------------------------------------------+
+| **font options**      | ``[font {options}]{text}[/font]``                         | Use custom font options for the {text}. See font options for more info.  |
++-----------------------+-----------------------------------------------------------+--------------------------------------------------------------------------+
+| **font size**         | ``[font_size=nn]{text}[/font_size]``                      | Use custom font size for {text}.                                         |
++-----------------------+-----------------------------------------------------------+--------------------------------------------------------------------------+
+| **opentype features** | ``[opentype_features=ftr,ftr]{text}[/opentype_features]`` | Use custom OpenType font features (comma separated list) for {text}.     |
++-----------------------+-----------------------------------------------------------+--------------------------------------------------------------------------+
+| **outline size**      | ``[outline_size=<size>]{text}[/outline_size]``            | Use custom font outline size for {text}.                                 |
++-----------------------+-----------------------------------------------------------+--------------------------------------------------------------------------+
+| **outline color**     | ``[outline_color=<color>]{text}[/outline_color]``         | Use custom outline color for {text}.                                     |
++-----------------------+-----------------------------------------------------------+--------------------------------------------------------------------------+
+| **color**             | ``[color=<code/name>]{text}[/color]``                     | Change {text} color; use name or # format, such as ``#ff00ff``.          |
++-----------------------+-----------------------------------------------------------+--------------------------------------------------------------------------+
+| **table**             | ``[table=<number>]{cells}[/table]``                       | Creates a table with <number> of columns.                                |
++-----------------------+-----------------------------------------------------------+--------------------------------------------------------------------------+
+| **cell**              | ``[cell=<expand ratio>]{text}[/cell]``                    | Adds cells with the {text} to the table.                                 |
++-----------------------+-----------------------------------------------------------+--------------------------------------------------------------------------+
+| **cell**              | ``[cell {options}]{text}[/cell]``                         | Adds cells with the {text} to the table. See cell options for more info. |
++-----------------------+-----------------------------------------------------------+--------------------------------------------------------------------------+
+| **list**              | ``[ul]{one item per line}[/ul]``                          | Add unnumbered list.                                                     |
++-----------------------+-----------------------------------------------------------+--------------------------------------------------------------------------+
+| **list**              | ``[ol type=<type>]{one item per line}[/ol]``              | Add numbered list. See list types for more info.                         |
++-----------------------+-----------------------------------------------------------+--------------------------------------------------------------------------+
+| **unicode control**   | ``[lrm]``, ``[rlm]``, ``[lre]``, ``[rle]``, ``[lro]``,    | Adds Unicode control character.                                          |
+|                       | ``[rlo]``, ``[pdf]``, ``[alm]``, ``[lri]``, ``[rli]``,    |                                                                          |
+|                       | ``[fsi]``, ``[pdi]``, ``[zwj]``, ``[zwnj]``, ``[wj]``     |                                                                          |
++-----------------------+-----------------------------------------------------------+--------------------------------------------------------------------------+
+
+Note: Options are optional for all tags.
+
+Paragraph options
+~~~~~~~~~~~~~~~~~
+
++----------------------------+---------------------------------------------------------------------------+----------------------------+
+| Option                     | Supported Values                                                          | Description                |
++----------------------------+---------------------------------------------------------------------------+----------------------------+
+| ``align``                  | ``left``, ``center``, ``right``, ``fill``                                 | Text horizontal alignment. |
++----------------------------+---------------------------------------------------------------------------+----------------------------+
+| ``direction`` or ``dir``   | ``ltr``, ``rtl``, ``auto``                                                | Base BiDi direction.       |
++----------------------------+---------------------------------------------------------------------------+----------------------------+
+| ``language`` or ``lang``   | ISO language codes                                                        | Locale override.           |
++----------------------------+---------------------------------------------------------------------------+----------------------------+
+| ``bidi_override`` or `st`  | ``default``, ``uri``, ``file``, ``email``, ``list``, ``none``, ``custom`` | Structured text override.  |
++----------------------------+---------------------------------------------------------------------------+----------------------------+
+
+
+Font options
+~~~~~~~~~~~~
+
++----------------------------+-------------------------------------------------+
+| Option                     | Description                                     |
++----------------------------+-------------------------------------------------+
+| ``name`` or ``n``          | Font resource path.                             |
++----------------------------+-------------------------------------------------+
+| ``size`` or ``s``          | Font size.                                      |
++----------------------------+-------------------------------------------------+
+
+Cell options
+~~~~~~~~~~~~
+
+-  ``expand`` - Column expansion ratio, the column expands in proportion to its expansion ratio versus the other columns' ratios.
+-  ``border`` -  Sets cell border color.
+-  ``bg`` - Sets cell background color, for alternating odd/even row backgrounds use ``bg=odd_color,even_color``.
+
+List types
+~~~~~~~~~~
+
+Supported list types:
+
+-  ``1`` - Numbers, using language specific numbering system if possible.
+-  ``a`` and ``A`` - Lower and upper case Latin letters.
+-  ``i`` and ``I`` - Lower and upper case Roman numerals.
 
 Named colors
 ~~~~~~~~~~~~
@@ -107,11 +178,7 @@ In this case, note that the alpha channel is the **first** component of the colo
 Image vertical offset
 ~~~~~~~~~~~~~~~~~~~~~
 
-You use a custom font for your image in order to align it vertically.
-
-1. Create a ``BitmapFont`` resource
-2. Set this bitmap font with a positive value for the ``ascent`` property, that's your height offset
-3. Set the BBCode tag this way: ``[font=<font-path>][img]{image-path}[/img][/font]``
+Use ``[img=align]...[/img]`` to set vertical alignment of the image, where ``align`` is ``t`` (top), ``c`` (center) or ``b`` (bottom).
 
 Animation effects
 -----------------
@@ -186,21 +253,22 @@ use the name of the file to determine what the BBCode tag should be.
 ``_process_custom_fx``
 ~~~~~~~~~~~~~~~~~~~~~~
 
-This is where the logic of each effect takes place and is called once per character
+This is where the logic of each effect takes place and is called once per glyph
 during the draw phase of text rendering. This passes in a :ref:`class_CharFXTransform`
-object, which holds a few variables to control how the associated character is rendered:
+object, which holds a few variables to control how the associated glyph is rendered:
 
 - ``identity`` specifies which custom effect is being processed. You should use that for
   code flow control.
-- ``relative_index`` tells you how far into a given custom effect block you are in as an
+- ``outline`` is ``true`` if effect is called for drawing text outline.
+- ``range`` tells you how far into a given custom effect block you are in as an
   index.
-- ``absolute_index`` tells you how far into the entire text you are as an index.
 - ``elapsed_time`` is the total amount of time the text effect has been running.
-- ``visible`` will tell you whether the character is visible or not and will also allow you
+- ``visible`` will tell you whether the glyph is visible or not and will also allow you
   to hide a given portion of text.
-- ``offset`` is an offset position relative to where the given character should render under
+- ``offset`` is an offset position relative to where the given glyph should render under
   normal circumstances.
-- ``color`` is the color of a given character.
+- ``color`` is the color of a given glyph.
+- ``glyph_index`` and ``font`` is glyph being drawn and font data resource used to draw it.
 - Finally, ``env`` is a :ref:`class_Dictionary` of parameters assigned to a given custom
   effect. You can use :ref:`get() <class_Dictionary_method_get>` with an optional default value
   to retrieve each parameter, if specified by the user. For example ``[custom_fx spread=0.5
@@ -209,7 +277,7 @@ object, which holds a few variables to control how the associated character is r
 
 The last thing to note about this function is that it is necessary to return a boolean
 ``true`` value to verify that the effect processed correctly. This way, if there's a problem
-with rendering a given character, it will back out of rendering custom effects entirely until
+with rendering a given glyph, it will back out of rendering custom effects entirely until
 the user fixes whatever error cropped up in their custom effect logic.
 
 Here are some examples of custom effects:
@@ -284,20 +352,17 @@ Matrix
         var dirty_time = char_fx.env.get("dirty", 1.0)
         var text_span = char_fx.env.get("span", 50)
 
-        var value = char_fx.character
-
-        var matrix_time = fmod(char_fx.elapsed_time + (char_fx.absolute_index / float(text_span)), \
+        var matrix_time = fmod(char_fx.elapsed_time + (char_fx.range.x / float(text_span)), \
                                clear_time + dirty_time)
 
         matrix_time = 0.0 if matrix_time < clear_time else \
                       (matrix_time - clear_time) / dirty_time
 
-        if value >= 65 && value < 126 && matrix_time > 0.0:
-            value -= 65
-            value = value + int(1 * matrix_time * (126 - 65))
+        if matrix_time > 0.0:
+            value = int(1 * matrix_time * (126 - 65))
             value %= (126 - 65)
             value += 65
-        char_fx.character = value
+        char_fx.glyph_index = TextServer.font_get_glyph_index(char_fx.font, value)
         return true
 
 This will add a few new BBCode commands, which can be used like so: