1
0
Fork 0
mirror of https://github.com/Orama-Interactive/Pixelorama.git synced 2025-01-31 07:29:49 +00:00

Fixed Noto font not being used for Chinese characters, when the user's System Language is not "zh_TW"

This commit is contained in:
OverloadedOrama 2020-01-02 16:46:31 +02:00
parent 1e58fb6911
commit cf8229a4ae
2 changed files with 2 additions and 2 deletions

View file

@ -66,7 +66,7 @@ func _on_Language_pressed(button : Button) -> void:
else:
TranslationServer.set_locale(Global.loaded_locales[index])
if TranslationServer.get_locale() == "zh_TW":
if "zh" in TranslationServer.get_locale():
Global.control.theme.default_font = preload("res://Assets/Fonts/NotoSansCJKtc-Regular.tres")
else:
Global.control.theme.default_font = preload("res://Assets/Fonts/Roboto-Regular.tres")

View file

@ -93,7 +93,7 @@ func _ready() -> void:
else: # If the user doesn't have a language preference, set it to their OS' locale
TranslationServer.set_locale(OS.get_locale())
if TranslationServer.get_locale() == "zh_TW":
if "zh" in TranslationServer.get_locale():
theme.default_font = preload("res://Assets/Fonts/NotoSansCJKtc-Regular.tres")
else:
theme.default_font = preload("res://Assets/Fonts/Roboto-Regular.tres")