Eclipse BIRTメモ - PDFで日本語出力

  1. font metricsファイルと設定ファイルを準備(参考:http://muimi.com/j/fop/fop2.html)
  2. -DFOP_CONFIG_FILEオプションで設定ファイルの場所を指定(参考:http://dev.eclipse.org/newslists/news.eclipse.birt/msg01069.html)
  3. 以上

注意点はBIRTのフォント名とFOPのフォント名を同一にすること。
例えばMS明朝だと以下のようになります。

<configuration>
  <fonts>
    <font metrics-file="c:/msmincho.xml" embed-file="c:/windows/fonts/msmincho.ttc" kerning="yes">
      <font-triplet name="&#xff4d;&#xff53; &#x660e;&#x671d;" style="normal" weight="normal"/>
      <font-triplet name="&#xff4d;&#xff53; &#x660e;&#x671d;" style="normal" weight="bold"/>
      <font-triplet name="&#xff4d;&#xff53; &#x660e;&#x671d;" style="italic" weight="normal"/>
      <font-triplet name="&#xff4d;&#xff53; &#x660e;&#x671d;" style="italic" weight="bold"/>
    </font>
  </fonts>
</configuration>