Firebird Documentation IndexUsing non-Western fonts → 2: Override stylesheet fonts
Firebird Home Firebird Home Prev: 1: Find the fonts you needFirebird Documentation IndexUp: Using non-Western fontsNext: 3: Create metrics files

Step 2: Override the stylesheet fonts

Any font configuration stuff is placed in the folder config/xx, where xx is your language code. If the folder doesn't exist yet, create it. Now edit the file fo-params.txt in this folder (if it doesn't exist, copy it from config). Suppose you are working on a Japanese setup and you've chosen the following fonts: MSGothic for titles, MSMincho for normal body text, and WPJapanese to replace monospaced text. You would then edit the relevant portion of manual/config/ja/fo-params.txt as follows:

body.font.family=MSMincho
title.font.family=MSGothic
monospace.font.family=WPJapanese

Make sure you uncomment each altered line, if necessary.

Now when the intermediate XSL-FO output is built for a Japanese document, it will contain references to these fonts instead of the default ones in the stylesheets. A piece of the .fo file may look like this:

<fo:block keep-together="always" margin-left="0pc"
          font-family="MSMincho,Symbol,ZapfDingbats">
  <fo:block font-family="MSMincho" font-weight="bold" 
            keep-with-next.within-column="always"
            space-before.minimum="0.8em" space-before.optimum="1.0em"
            space-before.maximum="1.2em" 
            color="darkblue" text-align="start">
    <fo:block font-size="19.8pt">...Japanese text here...</fo:block>
  </fo:block>
</fo:block>

The next two steps will deal with the following stage: the creation of the PDF itself.

Prev: 1: Find the fonts you needFirebird Documentation IndexUp: Using non-Western fontsNext: 3: Create metrics files
Firebird Documentation IndexUsing non-Western fonts → 2: Override stylesheet fonts