xmlgraphics-fop-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Harald Finster ...@topsystem.de>
Subject Re: problem with list of fonts in font-family
Date Wed, 16 Dec 2009 11:34:53 GMT
Hello,

thanks for your response.

Jeremias Maerki wrote:
> Does it help if you remove the "encoding-mode" attribute from the "font"
> element? With "single-byte" you restrict the character set to 256
> characters.
>
>   
Admittedly, I was quite surprised that the fonts seemed to work with Unicode
characters.
(At least the Mincho font is able to display Western+Cyrillic+IPA+Hiragana).
You are right: the "single-byte" attribute ** should ** result in a font 
with
max. 256 characters.
Thus, I  tried to remove the encoding-mode.
But the behaviour is the same as before.

In the meantime I found a very, very ugly workaround:
I use the Charis (Western+Cyrillic+IPA) font and explicitly switch to
Mincho for Japanese text.. The switch is done by abusing the emphasis 
element from
docbook and adding role="hiragana". I added an additional when-clause
in the xslt which transforms docbook to fo. The template
adds font-familly="Mincho". Really ugly I know :-(

Again, thanks a lot for your feedback!

Greetings Harald

> On 15.12.2009 12:13:23 Harald Finster wrote:
>   
>> Hello,
>>
>> could somebody please help me with the following problem:
>>
>> I am trying to create a pdf-document from docbook using the
>> apache fop. The document contains West-European characters,
>> Cyrillic characters, phonetic symbols from the IPA alphabet and
>> Japanese Hiragana characters. (More character sets will most
>> probably follow.)
>>
>> I managed to render Western + Cyrillic + IPA using the
>> Charis font with the following lines:
>>
>> in fop.conf:
>>
>>        <font  kerning="yes"
>>            embed-url="doc/fo/fonts/CharisSILR.ttf"
>>            encoding-mode="single-byte">
>>             <font-triplet name="Charis" style="normal" weight="normal"/>
>>       </font>
>>
>> in the ant-build starting fop:
>>
>>             <param name="symbol.font.family" expression="Charis" />
>>             <param name="body.fontset" expression="Charis" />
>>
>>
>> The same works with the Japanese characters, if I use "Mincho" instead
>> of "Charis". Even the Cyrillic characters are displayed with "Mincho",
>> however the characters are pretty wide and some of the IPA diacritics
>> are incorrect.
>>
>> Following the documentation, I tried to use a comma-separated list of
>> fonts, i.e.
>>             <param name="symbol.font.family" expression="Charis,Mincho" />
>>             <param name="body.fontset" expression="Charis,Mincho" />
>>
>> I understand, that this list is searched for matching characters, i.e. the
>> algorithm should first find the Western,IPA and Cyrillic characters in 
>> "Charis"
>> and look for the Japanese characters in "Mincho".
>> However, the Japanese characters are not displayed in the pdf-document.
>> Instead, they are "displayed" as empty rectangular boxes. (Not hashes (#)!)
>>
>> System information:
>> fop 0.95
>> docbook 1.74
>> ant started from eclipse 3.5.1
>> Win XP
>>
>> The fonts (ttf-files) are installed in the doc/fo/fonts/ directory.
>> As fop seems to have a problem with ttc font collections, I extracted
>> Mincho.ttf from mincho.ttc with breakttc.exe.
>>
>> Any pointer appreciated!
>>
>> Kind regards
>>
>> Harald Finster
>>
>> -- 
>>
>> i. A.
>> Dr.-Ing. Harald Finster 
>>
>> topsystem Systemhaus GmbH
>> Monnetstraße 24
>> D-52146 Würselen
>>
>> Phone : +49 (2405) 4670 - 22
>> Fax   : +49 (2405) 4670 - 10
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>     
>
>
>
>
> Jeremias Maerki
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>
>   


-- 

i. A.
Dr.-Ing. Harald Finster 

topsystem Systemhaus GmbH
Monnetstraße 24
D-52146 Würselen

Phone : +49 (2405) 4670 - 22
Fax   : +49 (2405) 4670 - 10


Mime
View raw message