Forum Bugs

no glyphs for character

yong.zhang
Hello there,

We're looking for your help with a font problem when using Prince.

We've deployed Prince on our Linux centOS 5.6, and when we try to convert HTML pages into PDFs, the Chinese font become garbled as below:

The original HTML:
<h2>旅行须知</h2>

What we got in the PDF:
1.jpg


The command we ran:
/usr/local/bin/prince --no-author-style -s http://static.qyer.com/css/guide/guide_preview.css -o http://static.qyer.com/upload/guide/html/11.html /home/u8qyer/qyer/wwwroot/static/upload/guide/pdf/22.pdf

And the error it returned:
2.jpg


We understand that a font is needed to display Chinese fonts properly on Linux, and we've already installed that font and deployed it in "/usr/local/lib/prince/stayle/fonts.css", see below:
Install:
3.jpg

Deploy:
4.jpg


The location we deploy Prince:
5.jpg


--------

Any idea on how to deal with it? Really appreciate your help!



Regards,

yong.zhang
  1. 1.jpg5.7 kB
  2. 2.jpg53.6 kB
  3. 3.jpg110.2 kB
  4. 4.jpg103.4 kB
  5. 5.jpg11.8 kB

Edited by mikeday

mikeday
I don't think Trebuchet MS supports Chinese. Can you use a different font?

If you install the CentOS "fonts-chinese" package you will get two fonts, "AR PL ZenKai Uni" and "AR PL ShanHeiSun Uni", if either of those are suitable you could edit fonts.css to specify these instead of the current defaults for Chinese, which are "AR PL UMing CN" and "AR PL SungtiL GB".
yong.zhang
Hello,

Thank you for your help the other day. We got one more question:

Beside Chinese, we need to display a wider set of languages, worldwide, such as Russian, Japanese and Thai.. (Our company provides travel information and services for global destinations)

So although we deployed the Chinese font, the Japanese characters on the same page still garbled.

Any thought on this?? Do we have to deploy all those fonts in different languages?

Thank you so much
mikeday
Yes, you need all the fonts.