Embedding font in pdf
Posted: Sun Apr 26, 2009 1:33 am
Hi,
I'm trying to change the default font used to create a PDF from a DITAMap using Idiom FO Plugin (with Apache FOP processor). I've scanned and read all previous posts regarding this issue and none of them help.
As much as I enjoy using Oxygen, I bemoan the lack of proper documentation for this issue. In fact, the instructions contained in the http://www.oxygenxml.com/doc/articles/A ... tToFOP.pdf document do not work! I am using Mac OS X 10.5 with Oxygen 10.2. The following line
export CMD=java -cp "$LIB/fop.jar:$LIB/avalon-framework-4.2.0.jar:$LIB/xe is only partially rendered and hence I've had to fill in the rest of the blanks. It then throws an 'illegal option -cp' error on the command line!.
After, figuring this out I managed to create a XML font metrics file in my OXYGEN_INSTALLATION_DIRECTORY. I then created a fopConfiguration.xml file as per the instructions. I then added the font name as parameters to the transformation scenario.
However I still keep getting the following error and there is no change to the font.
[fop] 1044 WARN [ main ] org.apache.fop.fonts.FontInfo - Font 'GentiumBookBasic,normal,400' not found. Substituting with 'any,normal,400'.
My configuration file looks like this:
<fop version="1.0">
<base>file:/Applications/oxygen/</base>
<source-resolution>72</source-resolution>
<target-resolution>72</target-resolution>
<default-page-settings height="11in" width="8.26in"/>
<renderers>
<renderer mime="application/pdf">
<filterList>
<value>flate</value>
</filterList>
<fonts>
<font metrics-url="GentiumBookBasic.xml" kerning="yes"
embed-url="file:/Users/jay/Library/Fonts/GenBkBasR.ttf">
<font-triplet name="GentiumBookBasic" style="normal"
weight="normal"/>
</font>
</fonts>
</renderer>
</renderers>
</fop>
Any help will be greatly appreciated ...
Thanks,
Jay
I'm trying to change the default font used to create a PDF from a DITAMap using Idiom FO Plugin (with Apache FOP processor). I've scanned and read all previous posts regarding this issue and none of them help.
As much as I enjoy using Oxygen, I bemoan the lack of proper documentation for this issue. In fact, the instructions contained in the http://www.oxygenxml.com/doc/articles/A ... tToFOP.pdf document do not work! I am using Mac OS X 10.5 with Oxygen 10.2. The following line
export CMD=java -cp "$LIB/fop.jar:$LIB/avalon-framework-4.2.0.jar:$LIB/xe is only partially rendered and hence I've had to fill in the rest of the blanks. It then throws an 'illegal option -cp' error on the command line!.
After, figuring this out I managed to create a XML font metrics file in my OXYGEN_INSTALLATION_DIRECTORY. I then created a fopConfiguration.xml file as per the instructions. I then added the font name as parameters to the transformation scenario.
However I still keep getting the following error and there is no change to the font.
[fop] 1044 WARN [ main ] org.apache.fop.fonts.FontInfo - Font 'GentiumBookBasic,normal,400' not found. Substituting with 'any,normal,400'.
My configuration file looks like this:
<fop version="1.0">
<base>file:/Applications/oxygen/</base>
<source-resolution>72</source-resolution>
<target-resolution>72</target-resolution>
<default-page-settings height="11in" width="8.26in"/>
<renderers>
<renderer mime="application/pdf">
<filterList>
<value>flate</value>
</filterList>
<fonts>
<font metrics-url="GentiumBookBasic.xml" kerning="yes"
embed-url="file:/Users/jay/Library/Fonts/GenBkBasR.ttf">
<font-triplet name="GentiumBookBasic" style="normal"
weight="normal"/>
</font>
</fonts>
</renderer>
</renderers>
</fop>
Any help will be greatly appreciated ...

Thanks,
Jay