On 26/08/2011 05:11, Everson Rogério wrote:
Hello
I am using a Java class to generate PDF from an XSL and XML. Now, I
need to generate PCL with these XSL and XML files.
I read something about this in Graphic Library "fop"
org.apache.fop.render.pcl, but I'm not succeeding.
If you are having a problem, then describing the problem would be
helpful, e.g. if you get an error then posting the stack will help
others to guide you.
Can anyone help me? Send examples?
The FOP distribution includes an example of how to render XML+XSL to PDF
from a Java application in
fop\examples\embedding\java\embedding\ExampleXML2PDF.java.
Changing this example to generate PCL is a simple one line change to the
following line:
Fop fop = fopFactory.newFop(MimeConstants.MIME_PDF, foUserAgent, out);
Changing it to:
Fop fop = fopFactory.newFop(MimeConstants.MIME_PCL, foUserAgent, out);
Note that there is an image in the PDF generated, so I'm using the tag
<fo:external-graphic>. and works good!
Thanks
Regards,
Chris
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]