You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-dev@xmlgraphics.apache.org by James Tauber <jt...@jtauber.com> on 1999/12/03 13:31:43 UTC

tip for change to PDF part of FOP

A gentleman named Bruno Lowagie wrote me an email in which he provides the
following tip about our implementation in org.apache.fop.pdf.

[...]
> You really should store the 'data' of a 'PDFStream'
> as byte[] instead of StringBuffer.
> Otherwise you will get troubles as soon as you
> want to implement compression (FlateDecode).
>
> On UNIX everything works just fine, but on Windows
> the PDF document will open correctly because the
> PDF syntax is OK, however since some bytes of the
> stream will be corrupted by Windows, the stream will
> not be decompressed and the page will remain blank...
>
> This is caused by: DATA TRANSFER PROBLEMS ON WINDOWS
> see: http://java.sun.com/products/jdk/1.1.7B/README
> Just run this code:
> http://allserv.rug.ac.be/~blowagie/java-pdf/Encoding.java
> on a PC (windows) and you'll see what the problem is.
>
> I hope this small contribution will help you to make FOP
> a success. You might want to download my code as well:
> http://allserv.rug.ac.be/~blowagie/java-pdf/
> but as I allready said: it isn't that elaborate as yours...

James