1234567891011121314151617181920212223242526272829303132333435363738394041424344454647 |
- :github_url: hide
- .. DO NOT EDIT THIS FILE!!!
- .. Generated automatically from Godot engine sources.
- .. Generator: https://github.com/godotengine/godot/tree/master/doc/tools/make_rst.py.
- .. XML source: https://github.com/godotengine/godot/tree/master/doc/classes/TextServerDummy.xml.
- .. _class_TextServerDummy:
- TextServerDummy
- ===============
- **Inherits:** :ref:`TextServerExtension<class_TextServerExtension>` **<** :ref:`TextServer<class_TextServer>` **<** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
- A dummy text server that can't render text or manage fonts.
- .. rst-class:: classref-introduction-group
- Description
- -----------
- A dummy :ref:`TextServer<class_TextServer>` interface that doesn't do anything. Useful for freeing up memory when rendering text is not needed, as text servers are resource-intensive. It can also be used for performance comparisons in complex GUIs to check the impact of text rendering.
- A dummy text server is always available at the start of a project. Here's how to access it:
- ::
- var dummy_text_server = TextServerManager.find_interface("Dummy")
- if dummy_text_server != null:
- TextServerManager.set_primary_interface(dummy_text_server)
- # If the other text servers are unneeded, they can be removed:
- for i in TextServerManager.get_interface_count():
- var text_server = TextServerManager.get_interface(i)
- if text_server != dummy_text_server:
- TextServerManager.remove_interface(text_server)
- The command line argument ``--text-driver Dummy`` (case-sensitive) can be used to force the "Dummy" :ref:`TextServer<class_TextServer>` on any project.
- .. |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.)`
- .. |constructor| replace:: :abbr:`constructor (This method is used to construct a type.)`
- .. |static| replace:: :abbr:`static (This method doesn't need an instance to be called, so it can be called directly using the class name.)`
- .. |operator| replace:: :abbr:`operator (This method describes a valid operator to use with this type as left-hand operand.)`
- .. |bitfield| replace:: :abbr:`BitField (This value is an integer composed as a bitmask of the following flags.)`
- .. |void| replace:: :abbr:`void (No return value.)`
|