Move localized number formatting methods to TranslationServer

Co-Authored-By: Pāvels Nadtočajevs <7645683+bruvzg@users.noreply.github.com>
This commit is contained in:
Haoyu Qiu
2025-10-27 21:48:09 +08:00
parent 6fd949a6dc
commit 72d437c030
27 changed files with 348 additions and 394 deletions

View File

@@ -1075,13 +1075,13 @@
Returns the dictionary of the supported OpenType variation coordinates.
</description>
</method>
<method name="format_number" qualifiers="const">
<method name="format_number" qualifiers="const" deprecated="Use [method TranslationServer.format_number] instead.">
<return type="String" />
<param index="0" name="number" type="String" />
<param index="1" name="language" type="String" default="&quot;&quot;" />
<description>
Converts a number from the Western Arabic (0..9) to the numeral systems used in [param language].
If [param language] is omitted, the active locale will be used.
Converts a number from Western Arabic (0..9) to the numeral system used in the given [param language].
If [param language] is an empty string, the active locale will be used.
</description>
</method>
<method name="free_rid">
@@ -1197,12 +1197,13 @@
Converts readable feature, variation, script, or language name to OpenType tag.
</description>
</method>
<method name="parse_number" qualifiers="const">
<method name="parse_number" qualifiers="const" deprecated="Use [method TranslationServer.parse_number] instead.">
<return type="String" />
<param index="0" name="number" type="String" />
<param index="1" name="language" type="String" default="&quot;&quot;" />
<description>
Converts [param number] from the numeral systems used in [param language] to Western Arabic (0..9).
Converts [param number] from the numeral system used in the given [param language] to Western Arabic (0..9).
If [param language] is an empty string, the active locale will be used.
</description>
</method>
<method name="parse_structured_text" qualifiers="const">
@@ -1214,11 +1215,12 @@
Default implementation of the BiDi algorithm override function.
</description>
</method>
<method name="percent_sign" qualifiers="const">
<method name="percent_sign" qualifiers="const" deprecated="Use [method TranslationServer.get_percent_sign] instead.">
<return type="String" />
<param index="0" name="language" type="String" default="&quot;&quot;" />
<description>
Returns percent sign used in the [param language].
Returns the percent sign used in the given [param language].
If [param language] is an empty string, the active locale will be used.
</description>
</method>
<method name="save_support_data" qualifiers="const">