Hi Heather,
   Thanks.
Yes the output.xmap needs to be used because the Forrest 0.8 now uses plugins for fo2pdf generation.

The step 5 which you mentioned is correct as the skins are not ready for Japanese, so MS gothic needs to inserted.

I will look into your files, and what I had done, to see if I can help you further. Will get back to you later on that.

best wishes
Praveen
----- Original Message ----- From: "Heather Phipps" <hmphi...@gmail.com> To: <user@forrest.apache.org>; "Dr. Bhatia Praveen" <praveen.bha...@sumpurn.com>
Sent: Thursday, April 23, 2009 3:19 PM
Subject: Re: Japanese PDF rendering


Hi Praveen,

I very much appreciate your prompt response, as I have been struggling
with this issue for quite some time now.

Unfortunately, even after editing
$FORREST/apache-forrest-0.8/plugins/org.apache.forrest.plugin.output.pdf/output.xmap,
I am unable to get the font to display correctly in the PDF file.

I have a few questions.  First...how did you know that Forrest is
using output.xmap instead of sitemap.xmap for this step?  Second, do
you know if step number 5 in the instructions from
http://www.terra-intl.com/agel/2005/11/forrest_japanese.html is
correct for Forrest 0.8?

Here is an excerpt from my output.xmap file:

...
   <map:serializers default="fo2pdf">
     <map:serializer name="fo2pdf"
src="org.apache.cocoon.serialization.FOPSerializer"
mime-type="application/pdf">
       <user-config
src="/Users/Heather/apache-forrest-0.8/main/webapp/resources/fonts/config.xml"
/>
     </map:serializer>
...

(Currently, this is in both my sitemap.xmap file and output.xmap)

I downloaded the .ttf and corresponding font-metric xml files from
http://www.terra-intl.com/agel/2005/11/forrest_japanese.html and
placed them in /Users/Heather/apache-forrest-0.8/main/webapp/resources/fonts/,
alongside config.xml, which contains the following:

<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<fonts>
<font metrics-file="/Users/Heather/apache-forrest-0.8/main/webapp/resources/fonts/sazanami-gothic.xml"
embed-file="/Users/Heather/apache-forrest-0.8/main/webapp/resources/fonts/sazanami-gothic.ttf"
kerning="yes">
  <font-triplet name="Gothic" style="normal" weight="normal"/>
  <font-triplet name="Gothic" style="normal" weight="bold"/>
  <font-triplet name="Gothic" style="italic" weight="normal"/>
  <font-triplet name="Gothic" style="italic" weight="bold"/>
</font>
<font metrics-file="/Users/Heather/apache-forrest-0.8/main/webapp/resources/fonts/sazanami-mincho.xml"
embed-file="/Users/Heather/apache-forrest-0.8/main/webapp/resources/fonts/sazanami-mincho.ttf"
kerning="yes">
  <font-triplet name="Mincho" style="normal" weight="normal"/>
  <font-triplet name="Mincho" style="normal" weight="bold"/>
  <font-triplet name="Mincho" style="italic" weight="normal"/>
  <font-triplet name="Mincho" style="italic" weight="bold"/>
 </font>
</fonts>
</configuration>

I also tried using different .ttf files and generating the font-metric
files myself, and it appeared that the font-metric files were
generated properly, but the PDF still did not display the Japanese
text correctly.

Any further thoughts?

-Heather



--------------------------------------------------------------------------------



No virus found in this incoming message.
Checked by AVG - www.avg.com
Version: 8.0.238 / Virus Database: 270.12.3/2075 - Release Date: 04/22/09 17:25:00