You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-users@xmlgraphics.apache.org by Adam Skowronski <ad...@pl.ibm.com> on 2007/02/08 12:31:48 UTC

Bad pdf document with embedded Times New Roman font

I tried to create PDF document and embed Times New roman font (because I need
some character from ISO-8859-2 codepage). 

I included Times New Roman into configuration as follows
   <font metrics-file="times.xml"  kerning="yes" embed-url="times.ttf">
   <font-triplet name="Times" style="normal" weight="normal"/>

In XML-FO I have:
<fo:inline font-family="Times Roman, serif" font-size="12.0pt">Zawarta w dniu
#datazawarcia# między wszystkimi a wszystkimi, że nie będzie nigdy niczego i
nigdzie. Tak nam dopomóż Krzysztof Kononowicz.</fo:inline>

FOP executes without errors, pdf file is created, but acrobat reader (Windows or
Linux version) crashes with message:
 There was an error processing a page. There was a problem reading this document
(135). 
xpdf from Linux displays document correctly. 

If I remove from configuration this particular font (but still embed others),
acroread can read document. 

Do anyone know solution or maybe right questions to ask?

-----
I'm using FOP 0,93
java version "1.4.2"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2)
Classic VM (build 1.4.2, J2RE 1.4.2 IBM build cxia32142-20060824 (SR6) (JIT
enabled: jitc))







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


Re: Bad pdf document with embedded Times New Roman font

Posted by Andreas L Delmelle <a_...@pandora.be>.
On Feb 8, 2007, at 12:31, Adam Skowronski wrote:

> I tried to create PDF document and embed Times New roman font  
> (because I need
> some character from ISO-8859-2 codepage).
> <snip />
> FOP executes without errors, pdf file is created, but acrobat  
> reader (Windows or
> Linux version) crashes with message:
>  There was an error processing a page. There was a problem reading  
> this document
> (135).
> xpdf from Linux displays document correctly.
>
> If I remove from configuration this particular font (but still  
> embed others),
> acroread can read document.
>
> Do anyone know solution or maybe right questions to ask?

Hmm. Not sure.
Have you tried different versions of Adobe Reader?
Any other viewers you tried? (GhostScript?)

Since you're multi-platforming, maybe the question of origin of the  
font (Windows/Linux) is also relevant? On what platform does FOP run?  
On what platform were the font files generated?

Just guessing...

Cheers,

Andreas


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


Re: Bad pdf document with embedded Times New Roman font

Posted by Dominic Marcotte <d....@usherbrooke.ca>.
The font-triplet name must match to the font-family.

Change to font-family="Times, serif".


Adam Skowronski wrote:
> I tried to create PDF document and embed Times New roman font (because I need
> some character from ISO-8859-2 codepage). 
>
> I included Times New Roman into configuration as follows
>    <font metrics-file="times.xml"  kerning="yes" embed-url="times.ttf">
>    <font-triplet name="Times" style="normal" weight="normal"/>
>
> In XML-FO I have:
> <fo:inline font-family="Times Roman, serif" font-size="12.0pt">Zawarta w dniu
> #datazawarcia# między wszystkimi a wszystkimi, że nie będzie nigdy niczego i
> nigdzie. Tak nam dopomóż Krzysztof Kononowicz.</fo:inline>
>
> FOP executes without errors, pdf file is created, but acrobat reader (Windows or
> Linux version) crashes with message:
>  There was an error processing a page. There was a problem reading this document
> (135). 
> xpdf from Linux displays document correctly. 
>
> If I remove from configuration this particular font (but still embed others),
> acroread can read document. 
>
> Do anyone know solution or maybe right questions to ask?
>
> -----
> I'm using FOP 0,93
> java version "1.4.2"
> Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2)
> Classic VM (build 1.4.2, J2RE 1.4.2 IBM build cxia32142-20060824 (SR6) (JIT
> enabled: jitc))
>
>
>
>
>
>
>   


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


Re: Bad pdf document with embedded Times New Roman font

Posted by Andreas L Delmelle <a_...@pandora.be>.
On Feb 8, 2007, at 12:31, Adam Skowronski wrote:


> I included Times New Roman into configuration as follows
>    <font metrics-file="times.xml"  kerning="yes" embed- 
> url="times.ttf">
>    <font-triplet name="Times" style="normal" weight="normal"/>
                         ^^^^^^^
Just noticed: maybe this weirdness is caused by this, in combination  
with the below font-family.
Change this to "Times Roman", ...

>
> In XML-FO I have:
> <fo:inline font-family="Times Roman, serif" font-size="12.0pt">

... and this to "'Times Roman', serif" (not necessary with FOP Trunk;  
only with 0.93)

Any changes?

Cheers,

Andreas


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