You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-dev@xmlgraphics.apache.org by "Clute, Andrew" <AC...@iccohio.com> on 2001/11/05 21:35:19 UTC
How do I fix the CMap? (WAS: Embed barcode fonts in FOP output)
I have tried your technique with about 3 different fonts and all of them do
not have a CMap in them. Someone suggested using VOLT, which I downloaded,
but I can't figure out how to fix it.
Anyone have any idea as to how to use it, or has anyone had any success is
emedding a barcode font into a pdf? If so, can you send me the font? (or
point me in the direction of a font that doesn't need fixed).
Thanks
-----Original Message-----
From: Chuck Paussa
To: fop-dev@xml.apache.org
Sent: 11/5/2001 2:22 PM
Subject: Embed barcode fonts in FOP output
This does work. I had to go through several different font families to
find a good one. Paying the $100 for the font is worth it for the higher
quality fonts.
We embed barcodes into our documents in the following manner:
1. Choose a barcode font... Here's a list I got from Google
http://www.adams1.com/pub/russadam/fonts.html
2. Use the FOP process to generate the font.xml file
For TTF:
java -cp
build\fop.jar;lib\xerces-1.2.3.jar;lib\xalan-2.0.0.jar;lib\batik.jar
org.apache.fop.fonts.apps.TTFReader %1.ttf %1.xml
For postscript:
java -cp
build\fop.jar;lib\xerces-1.2.3.jar;lib\xalan-2.0.0.jar;lib\batik.jar
org.apache.fop.fonts.apps.PFMReader %1.PFM %1.xml
Add the font definition to your conf/userconfig.xml file
(replacing the word "skan39r" with your file name)
(replacing the word "code39" with the name of your font)
<fonts>
<font metrics-file="skan39r.xml" kerning="no" embed-file="skan39r.ttf">
<font-triplet name="code39" style="normal" weight="normal"/>
</font>
</fonts
Now use fo:block font-family="code39" to embed the bar-codes.
Note: The tool will construct some values (FontBBox, StemV and
ItalicAngle) based on assumptions and calculations which are only an
approximation to the real values. FontBBox and Italic Angle can be found
in the human-readable part of the PFB file. The PFMReader tool does not
yet interpret PFB files, so if you want to be correct, you may have to
adjust the values in the XML file manually.
There is more information here:
http://xml.apache.org/fop/fonts.html
Chuck
---------------------------------------------------------------------
To unsubscribe, e-mail: fop-dev-unsubscribe@xml.apache.org
For additional commands, email: fop-dev-help@xml.apache.org