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

How to correct display Chinese? #19

Closed
KenteJohn opened this issue Nov 18, 2020 · 19 comments
Closed

How to correct display Chinese? #19

KenteJohn opened this issue Nov 18, 2020 · 19 comments
Assignees
Labels

Comments

@KenteJohn
Copy link

I get some "?" characters when I write a sentense in Chinese. I have tried almost all the fonts, but it didn't work. I hope to get your response as soon as possible,thank you.

@phax phax self-assigned this Nov 18, 2020
@phax phax added the question label Nov 18, 2020
@phax
Copy link
Owner

phax commented Nov 18, 2020

Hi, try selecting a font at https://fonts.google.com/?subset=chinese-simplified - that should give you a quite broad range.

If you find something suitable, I may be able to add it to https://github.com/phax/ph-fonts to have it available in a more suitable way.

hth

@KenteJohn
Copy link
Author

Thank you for your help, but due to some policy reasons, I can't visit google.com in China. Everything in your project fits me but fonts, I need Chinese support very much and don't want to give it up.

@KenteJohn
Copy link
Author

Maybe 'Noto Sans HK' can work?

@phax
Copy link
Owner

phax commented Nov 19, 2020

Hi. It only has "Noto Sans SC":
grafik

If you like, you can paste an example text here and I send you the screenshot.

@phax
Copy link
Owner

phax commented Nov 19, 2020

My bad. I also found the "Noto Sans HK"

@phax
Copy link
Owner

phax commented Nov 19, 2020

Glyphs of Noto Sans HK:
grafik

Is that what you are looking for?

@KenteJohn
Copy link
Author

Wow, 'Noto Sans SC' is ok.

@phax
Copy link
Owner

phax commented Nov 19, 2020

Just for comparison, these are the glyphs of "Noto Sans SC":
grafik

@KenteJohn
Copy link
Author

HK is complex font, SC is simplified font. I want the simplified font.

@KenteJohn
Copy link
Author

Maybe 'SC' is simplified Chinese, I guess.

@phax
Copy link
Owner

phax commented Nov 19, 2020

Yes exactly. There is also a version "TC" for "Traditional Chinese"

@KenteJohn
Copy link
Author

So, I can use this font at some point in the future, maybe after a few days or months?

@phax
Copy link
Owner

phax commented Nov 19, 2020

Yes, I am just trying it out in https://github.com/phax/ph-fonts - if it works, I will release 4.1.2 and create an example in here.

Is this is a reasonable test text:

他们所有的设备和仪器彷佛都是有生命的。

???

@KenteJohn
Copy link
Author

Yes and thank you for your support.

@phax
Copy link
Owner

phax commented Nov 19, 2020

Unfortunately it doesn't work. pdfbox has problems with the OTF font. Any conversion tool from OTF to TTF I tried so far failed :(

@KenteJohn
Copy link
Author

I believe you can resolve this problem. 加油!

@phax phax closed this as completed Nov 19, 2020
@phax
Copy link
Owner

phax commented Nov 19, 2020

So I found a solution.
Please see the attached PDF examples.
Do they look good for you?

font-noto-sans-hk.pdf
font-noto-sans-sc.pdf

@KenteJohn
Copy link
Author

I can not see them. The hyperlinks are invalid. Could you give me the directory path about your output?

@KenteJohn
Copy link
Author

oh, I get the path: pdf/pltext/font-noto-sans-sc.pdf.
Thank you.

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

No branches or pull requests

2 participants