my dog learned polymorphism*
The moose likes Other Open Source Projects and the fly likes XSL-FO to PDF using fop Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » Other Open Source Projects
Bookmark "XSL-FO to PDF using fop" Watch "XSL-FO to PDF using fop" New topic
Author

XSL-FO to PDF using fop

Andrea Rodriguez
Greenhorn

Joined: Jul 04, 2008
Posts: 3
Hello,
I have a XML file, and a XSL-FO file created with XF Designer 2008, and a XSL file created with XF Designer 2008 too. I tried to transform the XSL-FO using apache fop 0.94 version to PDF or PCL, but I have errors.
The xsl-fo document have graphs, and bar code, and so much text, some error is some like de border and padding must be 0, from de body configuration.
Someone could help me?
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41114
    
  45
Welcome to JavaRanch.

It would be helpful to see a minimal example of the XML and XSL-FO in question. That means excerpts that show exactly the problem and nothing else.

Be aware that FOP does not implement all of XSL-FO. Have you checked its documentation if this is maybe a feature that's (partly) missing?


Ping & DNS - my free Android networking tools app
William Brogden
Author and all-around good cowpoke
Rancher

Joined: Mar 22, 2000
Posts: 12761
    
    5
I have found the FOP users mailing list to be very responsive on problems like this. They will also be interested in seeing a minimum example that demonstrates the problem.

Bill
Andrea Rodriguez
Greenhorn

Joined: Jul 04, 2008
Posts: 3
Thank you for your help, I described a litle more my problem:

My XSL-FO file generated from my XML and the XSL generated with XF Designer 2008:


When I want process this XSL-FO file, with apache fop I have the following error:
07-07-08 12:17:59mainERROisf.domain.gcpr.XMLTransformHelperFOTrasform199transform(): org.apache.fop.fo.expr.PropertyException: Border and padding for region "xsl-region-body" must be '0' (See 6.4.13 in XSL 1.0).

To solve this problem, I put the the border and padding for region "xsl-region-body" in '0', but I have the following error:
07-07-08 12:45:10mainERROisf.domain.gcpr.XMLTransformHelperFOTrasform199transform(): org.apache.fop.fo.ValidationException: Error(Unknown location): For fo:simple-page-master, only one fo:region-start may be declared.

The lines that I�m running there are:


[ UD: removed the inline images to preserve the layout ]
[ July 07, 2008: Message edited by: Ulf Dittmer ]
Andrea Rodriguez
Greenhorn

Joined: Jul 04, 2008
Posts: 3
It could be that XSL file, generated with XF Designer 2008, is not apache fop compatible? Exist some other tools to process the XSL-FO file to generete PDF and PCL files?
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41114
    
  45
This is too much code to go through and try to understand. What William and I were asking for is a minimal example of the problem. That means to remove as much code as possible, so that you can't remove anything from the rest and still have it exhibit the problem. In other words, an SSCCE.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: XSL-FO to PDF using fop
 
Similar Threads
OpenOffice File Conversion formats
looking for tool to convert xml to pdf
Requirements for XSLT version 2.0 (Charts and Graphics)
Apache FOP to PDF Arabic display problem
rendering a xsl fo file to html and pdf