xmlgraphics-fop-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Eric Douglas" <edoug...@blockhouse.com>
Subject RE: Invalid PDF Created
Date Fri, 20 Aug 2010 16:27:13 GMT
As I said, it appears the PDF is missing something.  I think the 1.0
isn't embedding like it should.
I changed absolutely nothing just now in my code, aside from changing
the create back on the EmbedFontInfo object I'm using to remove the
extra parameter (the 1.0 required a string value subFontName, I'm just
passing an empty string), and just switching the fop.jar back to the
0.95 jar I get a square in my PDF (where the 1.0 is printing #).
Attached is the font file I'm using.
 

-----Original Message-----
From: Chris Bowditch [mailto:bowditch_chris@hotmail.com] 
Sent: Friday, August 20, 2010 12:10 PM
To: fop-users@xmlgraphics.apache.org
Subject: Re: Invalid PDF Created

Eric Douglas wrote:
> I resolved this.  After the transform I didn't close the output
stream.  
> Apparently that left some bytes hanging.

Hi Eric,

I'm glad you solved your corrupted PDF issue I was going to ask if had
closed the stream as a BufferedStream will hold onto a few bytes until
you either flush or close.

>  
> I still haven't heard anything about my other problem.  Should I send 
> to fop-dev when I get no response from fop-users?  I need to know why 
> the code for a character &#x25A1 comes out as # in PDF when it should 
> be displaying a square.  Print preview gets the square.  The font, 
> using the file ltype.ttf found in the windows xp fonts folder, does 
> appear to contain this character.  The Java doesn't log any messages I
can see.

No, please only post to fop-dev regarding issues related to FOP internal
code. The developers monitor this list anyway and are most likely just
under time pressure on other projects.

# in the PDF normally means FOP can't find the glyph for the code point
(x25A1 in this case) Does the TTF file have a CMAP table? Could be FOP
doesn't fully understand the TTF File.

Thanks,

Chris

> 
> ----------------------------------------------------------------------
> --
> *From:* Eric Douglas [mailto:edouglas@blockhouse.com]
> *Sent:* Thursday, August 19, 2010 11:43 AM
> *To:* fop-users@xmlgraphics.apache.org
> *Subject:* Invalid PDF Created
> 
> If I try to create a PDF directly from the transform with FOP 1.0, by 
> passing a BufferedOutputStream created from a FileOutputStream into 
> the FopFactory.newFop, it's creating an incomplete PDF.  Am I missing 
> something or where should this come from?
> 
> If I view the PDF it creates in a text editor and compare it to an old

> PDF they look similar.  The old one has this text at the end.  If you 
> open them in Adobe Reader the new one gives a message invalid because 
> it doesn't have the eof.  I don't know what the rest of this means but

> I know it needs the eof.
> 
> 
> xref
> 0 35
> 0000000000 65535 f
> 0000052745 00000 n
> 0000052810 00000 n
> 0000052902 00000 n
> 0000000015 00000 n
> 0000000215 00000 n
> 0000002897 00000 n
> 0000002930 00000 n
> 0000023169 00000 n
> 0000053041 00000 n
> 0000012421 00000 n
> 0000003860 00000 n
> 0000012614 00000 n
> 0000012635 00000 n
> 0000012655 00000 n
> 0000012676 00000 n
> 0000023361 00000 n
> 0000023383 00000 n
> 0000023645 00000 n
> 0000037932 00000 n
> 0000038021 00000 n
> 0000038190 00000 n
> 0000038701 00000 n
> 0000039305 00000 n
> 0000039572 00000 n
> 0000051325 00000 n
> 0000051414 00000 n
> 0000051587 00000 n
> 0000052058 00000 n
> 0000052623 00000 n
> 0000052645 00000 n
> 0000052664 00000 n
> 0000052684 00000 n
> 0000052706 00000 n
> 0000052725 00000 n
> trailer
> <<
> /Size 35
> /Root 2 0 R
> /Info 4 0 R
> /ID [<D9A085D4D66F41067F4196C54E0386EA> 
> <D9A085D4D66F41067F4196C54E0386EA>]
>  >>
> startxref
> 53103
> %%EOF
> 


---------------------------------------------------------------------
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