With FOP 0.93 you can skip the step with the TTFReader and remove
"metrics-url" in your configuration file. I've just tested it with the
K3.ttf font and it works if you don't use a metrics file. Note: This is
a new feature in 0.93 and may not yet work as expected. Feedback on this
is welcome (positive and negative).

I'll check why the TTFReader stumbles over this file.

On 16.01.2007 13:16:03 Joerg Heinrich wrote:
> Hello,
> I want use a Barcode font to create barcodes in my documents, I've
> started with
> the example examples/fo/advanced/barcode.fo .
> So I've got the 3of9barcode font file from:
> http://www.geocities.com/keith_dimmock/
> And I tried to create the font metric with following command:
> 
> java -cp
> /opt/fop/build/fop.jar:/opt/fop/lib/avalon-framework-4.2.0.jar:/opt/fop/lib/commons-logging-1.0.4.jar:/opt/fop/lib/commons-io-1.1.jar
> org.apache.fop.fonts.apps.TTFReader -d k3.ttf k3.xml
> TTF Reader for Apache FOP 0.93
> 
> Parsing font...
> Reading k3.ttf...
> Reading 10 dir tables
> dir tables: [cmap, hhea, OS/2, maxp, head, glyf, hmtx, name, loca, post]
> unit per em: 2048
> Number of glyphs in font: 48
> hhea.Ascender: 800 390
> hhea.Descender: 0 0
> Number of horizontal metrics: 2
> Error while building XML font metrics file.
> java.io.EOFException: Reached EOF, file size=5104 offset=5104
>         at
> org.apache.fop.fonts.truetype.FontFileReader.seekSet(FontFileReader.java:86)
>         at
> org.apache.fop.fonts.truetype.FontFileReader.seekAdd(FontFileReader.java:99)
>         at
> org.apache.fop.fonts.truetype.FontFileReader.skip(FontFileReader.java:109)
>         at
> org.apache.fop.fonts.truetype.TTFFile.readPostScript(TTFFile.java:854)
>         at org.apache.fop.fonts.truetype.TTFFile.readFont(TTFFile.java:479)
>         at org.apache.fop.fonts.apps.TTFReader.loadTTF(TTFReader.java:206)
>         at org.apache.fop.fonts.apps.TTFReader.main(TTFReader.java:161)
> 
> If I try to use the metric file that's within the folder
> examples/fo/advanced
> I've got the following error:
> Failed to read font metrics file /opt/fop/fonts/k3.xml
> org.xml.sax.SAXException: Missing metrics-version attribute - please
> regenerate the font metrics file with a more recent version of FOP
> 
> I'm using FOP Version 0.93
> 
> Can anyone help me?
> 
> -- 
> Mit freundlichem Gruß
> Jörg Heinrich
> Westermann GmbH
> media solutions
> 
> Am Gaswerk 3 | 27305 Bruchhausen-Vilsen
> Telefon (04252) 399-54 | Fax (04252) 399-45
> [EMAIL PROTECTED] | http://www.wol.de



Jeremias Maerki


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to