Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

About i18n #112

Closed
marlkiller opened this issue Mar 9, 2022 · 1 comment
Closed

About i18n #112

marlkiller opened this issue Mar 9, 2022 · 1 comment

Comments

@marlkiller
Copy link

How to add a new language support ??

@hkrn
Copy link
Owner

hkrn commented Mar 12, 2022

Short Answer (but not enough)

Editing the following file and add the phrase corresponding to the language and country code (e.g. en_US) to phrase repeatly.
emapp/resources/translations/translations.yml

Unfortunately, this is not enough. There is another problem as described in the Long Answer.

Long Answer

nanoem uses ImGui for most parts. Therefore, nanoem have to handle the parts that the OS does for it. Among them, fonts are particularly problematic.

nanoem uses the Genei font as its built-in font. This is a good option if you are only using English or Japanese. However, in most cases, other languages cannot be displayed because they do not contain the corresponding characters.

For example, the confirmation dialog before loading official Genshin Impact's MMD models uses Simplified Chinese, which nanoem cannot display correctly due to as describe above. This is a known problem (一部文字が「?」と出て表示されない), but we have not been able to solve it. 

nanoem internally implements font loading for fonts other than the built-in fonts (but there is no place where it is used), but it effectively assumes the use of Genei font. The layout is designed in such a way that the use of non-Genei fonts may result in layout corruption. Therefore, the translator must check and decide which font is best. In addition, because of the use of embedded fonts, it may be necessary to modify the fonts, specifically, to add glyphs.

From the above, the answer is that adding languages is such a difficult issue that it affects the design depending on the target language, and it does not end with simply adding translations.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants