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

Chinese simplified have rong display #63

Open
momikiii opened this issue Apr 16, 2022 · 9 comments
Open

Chinese simplified have rong display #63

momikiii opened this issue Apr 16, 2022 · 9 comments

Comments

@momikiii
Copy link

momikiii commented Apr 16, 2022

Hi,XITRIX

I have some problem in your app

Chinese simplified have rong display , and I can't alter language to English, hope you can fix it , and add an options to change language

Thanks a lot!

@XITRIX
Copy link
Owner

XITRIX commented Apr 16, 2022

What do you mean "wrong display"? I don't know Chinese and this language was added by community, so I cannot confirm is it ok or not. Anyway option to change inapp language is planning.

@Alioth2000
Copy link

Some Chinese character are not displayed correctly, they are vacant. In my experience this is not a translation problem, this should be a lack of corresponding fonts
image

@momikiii
Copy link
Author

momikiii commented Apr 17, 2022

Some Chinese character are not displayed correctly, they are vacant. In my experience this is not a translation problem, this should be a lack of corresponding fonts image

This is what I mean , and I am trying to add Microsoft Yahei font in this project , but I can't execute "meson build" correctly when I finished adding font.

I'll be appreciate ,if you can check my another issue and provide some help.(●'◡'●)

@18271211
Copy link

for my self, just copy en-us language file into hans to pass this bug...

@zmk5566
Copy link

zmk5566 commented Aug 4, 2022

Some Chinese character are not displayed correctly, they are vacant. In my experience this is not a translation problem, this should be a lack of corresponding fonts image

This is what I mean , and I am trying to add Microsoft Yahei font in this project , but I can't execute "meson build" correctly when I finished adding font.

I'll be appreciate ,if you can check my another issue and provide some help.(●'◡'●)

Thing is, I am NOT even sure this is caused by font issue.

I have tested the font embeded in the ./resources/font folder, install the font on ubuntu and here is the font test result:
screen-shot

So either:

  1. The font in the resource folder is not used atm , or
  2. some other kinda problem

@zmk5566
Copy link

zmk5566 commented Aug 4, 2022

As a follow up, I suspect it might be an encoding issue. To be more specific, something to do with CJK issue that is why some of the characters are missing but some of them are able to display. The reference is here : https://en.wikipedia.org/wiki/CJK_characters I ll try to start a build myself to see how it goes.

@CaiMiao
Copy link

CaiMiao commented Aug 8, 2022

@XITRIX this is because you did not load chinese shared font in your codes.

i have written a solution of early stage of yoga borelis here but did not have time look into latest changes as i aready using legacy. you can integrate a similar solution but i would suggest you just copy most of my code.

@CaiMiao
Copy link

CaiMiao commented Aug 9, 2022

2022081002382700

I made a build to add shared font support.
Moonlight-Switch.zip

Note: loading additional shared font consumes a few RAM, which may cause potential performance impact. if you are okay with that, just cherry-pick my commit with commenting line out from 43 to 50 (consume less RAM).

(这个build添加了中文字体支持,但是会额外占用部分内存,因此有可能出现性能问题。如果你在意可用内存,请放弃使用简体中文,直接全部改成日文汉字。下面上传的main.json是繁体中文转日文汉字。)

if you concern about those RAM, i will suggest delete the chinese translation, or use this malformed main.json (for tofus use Japanese Kanji instead) for both Hans and Hant.
https://gist.github.com/CaiMiao/f38d274e4d413700374c6173065c65b9

@CaiMiao
Copy link

CaiMiao commented Aug 9, 2022

2022081002434500

no additional shared font but main.json edited build.

save some RAM.

Moonlight-Switch-zhKanji.zip

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

7 participants
@CaiMiao @XITRIX @momikiii @Alioth2000 @18271211 @zmk5566 and others