Yes, Arial Unicode MS works.
stsong.ttf is also kind of ttf font, but with the font name in Chinese,
I tried it without success.
Thanks, it is much better now, even though a little bit inaesthetic.
P.S. Tables are not displayed quite correctly, some columns lost...
δΊ 2011/10/30 10:34, Sergiu Dumitriu ει:
otf fonts are not supported by FOP, only ttf. A good font that you could
use in your instance, but which can't be distributed by XWiki, is Arial
Unicode MS, distributed by Microsoft with some of their products.
In xhtml2fo you're supposed to write the name (human friendly) of the font,
not the name of the file.
One other problem I noticed is that text in italics will only try to use
the FreeSerif font, since the request for an italic font seems to be
stronger than the request for the presence of a certain character. A
workaround is to only enable one font on the root element, the one that
provides proper support for Chinese. The downside is that English text will
also be displayed in that font face, which personally I find less beautiful
than FreeSerif.
A proper solution would be to use a font that does support bold and italic.
Sergiu Dumitriu
http://purl.org/net/sergiu/
On 2011-10-29 8:05 PM, "yang Li"<[email protected]> wrote:
It still doesn't work :(
I tried Adobe's AdobeSongStd-Light.otf, and simsum.ttc, STSONG.TTF from my
windows, and did the xhtml2fo.xsl job and restart the tomcat but still get
millions of ####...
2011/10/30 Sergiu Dumitriu<[email protected]>
# means that the font used in the pdf does not contain those characters.
You
should find a font that has support for Chinese, copy it in
WEB-INF/fonts,
extract xhtml2fo.xsl from
WEB-INF/libs/xwiki-platform-legacy-oldcore-*.jar
into WEB-INF/classes, edit it and add the name of your font next to
FreeSerif and FreeMono wherever they occur in the file, for example:
<xsl:attribute
name="font-family">FreeSerif,IPAGothic,serif</xsl:attribute>
Restart the server, and everything should work.
A good free font is IPAGothic, which I'll have to check if it can be
redistributed by default.
Sergiu Dumitriu
http://purl.org/net/sergiu/
On 2011-10-28 9:56 PM, "yang Li"<[email protected]> wrote:
Hi,
I tried to export a page with many chinese characters as pdf, but the
resulted pdf has many "#".
There are no encoding problems elsewhere, everything is displayed
correctly
by setting utf8 encoding everywhere (xwiki.cfg, database, tomcat).
I tried to search http://jira.xwiki.org and got no luck...
--
Thanks for reading!
Yang Li
Electronic Engineering, Fudan University
_______________________________________________
users mailing list
[email protected]
http://lists.xwiki.org/mailman/listinfo/users
_______________________________________________
users mailing list
[email protected]
http://lists.xwiki.org/mailman/listinfo/users
--
Thanks for reading!
Yang Li
Electronic Engineering, Fudan University
_______________________________________________
users mailing list
[email protected]
http://lists.xwiki.org/mailman/listinfo/users
_______________________________________________
users mailing list
[email protected]
http://lists.xwiki.org/mailman/listinfo/users
_______________________________________________
users mailing list
[email protected]
http://lists.xwiki.org/mailman/listinfo/users