xmlgraphics-fop-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Rob Sargent <rsarg...@xmission.com>
Subject Re: fop not handling svn rotated text on linux
Date Thu, 07 Jul 2011 14:36:15 GMT
I have to drop this for a bit: We've just release new software and we
all know how much fun that is...

Unfortunately I've had no luck with a substitution block in my fop
config file _comme ca_:

        <renderer mime="application/pdf">
                <!-- provides compression using zlib flate (default is
on) -->

                        <from font-family="Helvetica"
font-weight="normal" font-style="normal"/>
                        <to font-family="FreeSans" font-weight="normal"
                        <from font-family="Helvetica" font-weight="bold"
                        <to font-family="FreeSans" font-weight="bold"

where my svg file calls for Helvetica and I have placed the
FreeSans*.ttf and corresponding xml files (self generated locally using
org.apache.fop.fonts.apps.TTFReader) in my listed fonts and in the jar.

I'll try to pick this up again when thing settle down here,


On 07/04/2011 04:44 PM, Rob Sargent wrote:
> Andreas L. Delmelle wrote:
>> On 01 Jul 2011, at 18:20, Rob Sargent wrote:
>> Hi Rob
>> <snip />
>>> I'm coming to the conclusion that to guarantee all platforms use the
>>> same font I must include it in the distribution of the client.  As I've
>>> said, we're already including non-standard fonts (e.g. Optima), but my
>>> naive assumption that, since it's part and parcel of PDF, simply naming
>>> Helvetica was enough is clearly wrong.
>> Given the fact that (a substitute for) Helvetica may not be available
>> (or just is slightly different) on the client... It is not entirely
>> true that it's "part and parcel" of PDF. The PDF Specification states
>> only that viewer applications can assume the Base14 fonts to always
>> be available, so as not to force said viewers to include them in the
>> application package.
>> Not necessarily naive, but you're just bitten by the fact that, at
>> the end of the day, there simply is no such thing as true
>> platform-independency, especially where it concerns interoperability
>> between two basically separate Java apps. Some things depend on the
>> implementation of the Java runtime and the actual configuration of
>> the OS it runs on.
>> Assuming that you know which font is actually selected by the JVM/OS,
>> then you could try creating a substitution mapping in FOP's config,
>> like:
>> <substitution>
>>   <from font-family="Helvetica" />
>>   <to font-family="..."/>
>> </substitution>
> This give me some hope, thanks.
>> see: http://xmlgraphics.apache.org/fop/1.0/fonts.html#substitution
>> That will force FOP to use the metrics for that font, rather than the
>> default Base14 Helvetica (also for your FO, so there will be
>> consistency, if that is what you are looking for). Incidentally,
>> trying to use literal "SansSerif" in SVG triggered the same issue on
>> OS X. The reason is that, for the Apple JVM "SansSerif" is an alias
>> for "Lucida Grande".
>> I can confirm that I see change when adding a mapping such as above,
>> however, the appropriate font-file cannot be parsed by FOP currently...
>> Still, you might be able to resolve it this way on your end.
>>> Now can I just use the truetype
>>> arial which _is_ on my box (but does not rectify the current situation)
>>> and would presumably be what the pc users are getting. Or am I better
>>> off getting a commercial truetype Helvetica?
>> That depends on what you want to do with it. Keep in mind that buying
>> the Helvetica font would only grant you personal use. It comes
>> pre-installed on most common systems, but that license does not
>> permit the user-developers to just include it in their own projects.
>> That is very likely precisely the reason why it is left out of Linux,
>> as a matter of principle.
>> What when you happen to run into a colleague that has the same issue?
>> He/she should then have to buy it as well. If the vendor gets wind of
>> you redistributing the font in your own software, or just copying it
>> to multiple clients within your organization, he may not like it, and
>> force you to pay more. There is a reason FOP can only redistribute
>> the *metrics* for the Base14 fonts, not the fonts themselves.
>> Since you're already including other fonts, in case you have not done
>> so yet, be sure to check for those as well whether or not you are
>> permitted to include them.
>> Regards,
>> Andreas
>> ---
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org

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

View raw message