xmlgraphics-fop-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Daniel Noll <dan...@nuix.com>
Subject Re: Problem with custom fonts
Date Fri, 20 Apr 2007 01:24:29 GMT
Chris Bowditch wrote:
>> I thought the command was basically the same for all fonts, except 
>> where .ttc collections were involved.  I was (and still am) 
>> considering writing some magic code which autocreates the metrics when 
>> a new font is discovered.
> 
> No need ;) such code already exists in FOP trunk.

Convenient I guess, assuming you never need to use AWT.  No more writing 
lines and lines of font config. :-)

> The patch for autodetection of Fonts is only for PDF and PS Renderers. 
> The AWT Renderer gets its Fonts from the JDK which in turn gets its 
> fonts from the Operating System. The difference in font metrics between 
> AWT and PS/PDF exists regardless of the new auto font detection patch.

That's a shame.

I wonder if there is some way to grab the autogenerating metrics from 
the PDF code, and somehow push it into the AWT metrics.

At the moment my hack is sitting in the FontMetricsMapper constructor, 
and it overrides the metrics for only the fonts which I've hard-coded. 
It would be much better if I could just delegate to the PDF metrics 
loader for a given font name.  It may even make the code good enough to 
go into trunk, whereas right now it's very much a hack. :-(

Daniel


-- 
Daniel Noll

Nuix Pty Ltd
Suite 79, 89 Jones St, Ultimo NSW 2007, Australia    Ph: +61 2 9280 0699
Web: http://nuix.com/                               Fax: +61 2 9212 6902

This message is intended only for the named recipient. If you are not
the intended recipient you are notified that disclosing, copying,
distributing or taking any action in reliance on the contents of this
message or attachment is strictly prohibited.

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Mime
View raw message