Jeremias Maerki wrote:

On 18.02.2005 11:18:21 Chris Bowditch wrote:

Java 1.5, also has support for printing PDFs. Although other users on this list have reported problems rendering XSL-FO using FOP on JDK 1.5

Others may know of other tools that can be used to print a PDF....


That Java 1.5 has PDF printing support is only a rumour, I'm afraid.
I've heard that myself and went looking for it. Found nothing. Some of
the packages found following the link above claim to support a JPS (Java
Printing System) plug-in that allows to print PDF, however.

D'oh! You are right. I saw someone post some code a while ago and just assumed it would work on 1.5, I never actually tried it.



JPS allows to print arbitrary objects, although each print service only supports a certain subset of "DocFlavors". See the attached jdk15JPSEnum.txt which is a log of the JPSEnum.java I've also attached. It shows what JPS printing services (streaming and non-streaming) are available on my system under JDK 1.5. BTW, JPS is included in JDK 1.4!

Yes I know JPS is available on 1.4, I just thought the PDF print service had been provided in 1.5.


<snip/>

Further down you can see the streaming print services. JDK 1.4 and 1.5
support generation of PostScript files. Sun created a Graphics2D
subclass which allows that. Similar to FOP's PSGraphics2D. Speaking of
which: Just below that entry you can see two print services that I wrote
as a proof of concept which add PDF and PS output support to JPS by
delegating to FOP's PSGraphics2D and PDFGraphics2D. This would allow any
Java application to generate PDF files via JPS with FOP.

Thanks for the info/code, Jeremias.

Chris




--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to