Allow configuring which translation domain Object.tr uses

This commit is contained in:
Haoyu Qiu
2024-08-16 17:25:24 +08:00
parent 68d494e24e
commit c5d147b9b5
6 changed files with 94 additions and 2 deletions

View File

@ -818,6 +818,12 @@
[b]Note:[/b] Due of the implementation, each [Dictionary] is formatted very similarly to the returned values of [method get_method_list].
</description>
</method>
<method name="get_translation_domain" qualifiers="const">
<return type="StringName" />
<description>
Returns the name of the translation domain used by [method tr] and [method tr_n]. See also [TranslationServer].
</description>
</method>
<method name="has_meta" qualifiers="const">
<return type="bool" />
<param index="0" name="name" type="StringName" />
@ -1070,6 +1076,13 @@
If a script already exists, its instance is detached, and its property values and state are lost. Built-in property values are still kept.
</description>
</method>
<method name="set_translation_domain">
<return type="void" />
<param index="0" name="domain" type="StringName" />
<description>
Sets the name of the translation domain used by [method tr] and [method tr_n]. See also [TranslationServer].
</description>
</method>
<method name="to_string">
<return type="String" />
<description>