问题描述
我有以下 xsl-fo 代码,试图生成外来字符.
I have the following xsl-fo code, attempting to produce foreign characters.
<?xml version="1.0" encoding="UTF-8"?>
<fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format">
...
<fo:block font-size="11pt" font-family="calibri" language="pl">
Odwrotna strona tego pisma zawiera ważne informacje. jeżeli potrzebuje Pan/i pomocy, aby je zrozumieć, proszę
zadzwonić pod numer X-XXX-XXX-XXXX po bezpłatne usługi językowe.
</fo:block>
我已经尝试了我能想到的所有字体类型来访问所需的 unicode 字符,但到目前为止都没有成功.
I've tried every font-type I can think of to access the required unicode characters, but have had no success so far.
我的格式有问题吗?或者我正在使用的unicode?或者我没有正确声明我的 XML?
Is there something wrong with my formatting? Or the unicode I'm using? Or perhaps I haven't declared my XML properly?
这个,以及我的韩文、中文和俄文 unicode 字符是目前唯一给我带来麻烦的字符.而我的西班牙语和克罗地亚语 unicode 字符工作正常.
This, and my Korean, Chinese, and Russian unicode characters are the only ones giving me trouble at the moment. Whereas my Spanish and Croatian unicode characters are working fine.
推荐答案
如果您在文件中显示特殊字符时遇到问题,您可以尝试在配置文件中定义它们.这里 http://xmlgraphics.apache.org/fop/trunk/output.html#afp-configuration 你可能会发现如何去做.还要确保正确指定了字体目录的路径.在 Windows 中,它应该看起来像这样:
If you are having problems displaying special characters in your file you can try defining them in configuration file.Here http://xmlgraphics.apache.org/fop/trunk/output.html#afp-configuration you might find how to do it.Also make sure you have path to your fonts directory correctly specified. In Windows it should look something like that:
<fonts>
<directory recursive="true">C:\Windows\Fonts</directory>
<auto-detect/>
</fonts>
这篇关于APACHE FOP 中的 XSL-FO 外来字符(波兰语)Unicode (V. 1.1)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!