Bug fixes and improvements
* Fixed renpy.input not working with Chinese translation * Improved language handling for preferences
This commit is contained in:
parent
8af7186c97
commit
1b1bc53759
@ -2,3 +2,7 @@
|
|||||||
define CHARACTERS = {"hermione", "tonks", "astoria", "cho", "luna", "susan", "hooch"}
|
define CHARACTERS = {"hermione", "tonks", "astoria", "cho", "luna", "susan", "hooch"}
|
||||||
define SAYERS = {i[:3]:i for i in CHARACTERS}
|
define SAYERS = {i[:3]:i for i in CHARACTERS}
|
||||||
define ALLOWED_CHARACTERS = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz "
|
define ALLOWED_CHARACTERS = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz "
|
||||||
|
define LANGUAGE_TRANSCRIPTS = {
|
||||||
|
"english": "{font=gui/CreativeBlockRegular.ttf}English{/font}",
|
||||||
|
"chinese": "{font=tl/chinese/NotoSansSC-Bold.otf}汉语{/font}",
|
||||||
|
}
|
||||||
|
@ -120,9 +120,13 @@ screen preferences_general():
|
|||||||
hbox:
|
hbox:
|
||||||
spacing 2
|
spacing 2
|
||||||
|
|
||||||
textbutton "English" action Language(None)
|
textbutton LANGUAGE_TRANSCRIPTS.get("english") action Language(None)
|
||||||
for i in languages:
|
|
||||||
textbutton i.capitalize() action Language(i)
|
# Each language should be displayed in its native tongue.
|
||||||
|
# Please do not translate other language names.
|
||||||
|
for lang in languages:
|
||||||
|
$ transcript = LANGUAGE_TRANSCRIPTS.get(lang, lang)
|
||||||
|
textbutton transcript action Language(lang)
|
||||||
|
|
||||||
screen preferences_visuals():
|
screen preferences_visuals():
|
||||||
hbox:
|
hbox:
|
||||||
|
@ -4,3 +4,5 @@ translate chinese style default:
|
|||||||
translate chinese python:
|
translate chinese python:
|
||||||
gui.text_font = "tl/chinese/NotoSansSC-Bold.otf"
|
gui.text_font = "tl/chinese/NotoSansSC-Bold.otf"
|
||||||
gui.bold_font = "tl/chinese/NotoSansSC-Black.otf"
|
gui.bold_font = "tl/chinese/NotoSansSC-Black.otf"
|
||||||
|
# Note: This is required for non-alphabetic scripts to support inputs.
|
||||||
|
ALLOWED_CHARACTERS = None
|
||||||
|
Loading…
Reference in New Issue
Block a user