xmlgraphics-fop-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From javakthar <javakt...@gmail.com>
Subject FOP : PDF Rendering Issue
Date Tue, 16 Apr 2013 07:23:11 GMT
HI 
I am having an issue converting an XML file to PDF using FOP 1.1.

I get the following error when executing my code. 
“java.lang.UnsupportedOperationException: Don't know how to handle
"application/pdf" as an output format. Neither an FOEventHandler, nor a
Renderer could be found for this output format.”

There was a similar issue listed for Lotus Notes in the archives and a
solution recommended was to overwrite the renderer. The following code was
recommended

 FOUserAgent useragent = fopFactory.newFOUserAgent();
 PDFRenderer pdfrenderer = new PDFRenderer();
 pdfrenderer.setUserAgent(useragent);
 useragent.setRendererOverride(pdfrenderer);
 fop = fopFactory.newFop(MimeConstants.MIME_PDF, useragent,out);

When I include the line  PDFRenderer pdfrenderer = new PDFRenderer(); the
following error shows up  

“PDF Renderer cannot be resolved to a type”. Kindly let me know what needs
to done here.

I do not see PDFRendered under org.apache.fop.render.



Thanks & Regards 
============= 
Javed Akthar Khan 




--
View this message in context: http://apache-fop.1065347.n5.nabble.com/FOP-PDF-Rendering-Issue-tp38316.html
Sent from the FOP - Users mailing list archive at Nabble.com.

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