Uploaded image for project: 'OFBiz'
  1. OFBiz
  2. OFBIZ-311

Upgrade the Apache FOP rendering engine from .20.5 to .92


    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: framework
    • Labels:
    • Environment:

      Windows / Java 1.5


      Working on upgrading the FOP (http://xmlgraphics.apache.org/fop/) rendering engine used in ofBiz to generate PDF documents.

      We had the need to use more advanced layout functionality than what 0.20.5 offered. Version 0.92 offers a lot of improvements. From the apache site:

      • More than half of the codebase has been rewritten over the last three years. The code is relatively new and possibly not as stable as version 0.20.5 in every regard. But the code is quickly approaching production level, especially when you're happy with only PDF and PostScript output.
      • The API of FOP has changed considerably and is not backwards-compatible with version 0.20.5.
      • There have been changes to the end-user API between 0.91 beta and 0.92 beta. With version 0.92, the API is now considered stable. Some methods have been deprecated and will be removed with the next release. If you upgrade from 0.91 beta, you will need to adjust your Java code.
      • The new code is much more strict about the interpretation of the XSL-FO 1.0 specification. Things that worked fine in version 0.20.5 might start to produce warnings or even errors now. FOP 0.20.5 contains many bugs which have been corrected in the new code.


      • The last bullet point was accurate and some of the fo.ftl templates were broken (i.e. invoicePDF.fo.ftl). <fo:table-row> must contain <fo:table-column> and <fo:table-column> must contain <fo:block>.
      • Rendering of images are now done at their "natural" size unless you use the properties content-width or content-height. The height and width attributes don't seem to have any effect on the rendering.
      • Some of the XSL-FO documentation that I read also recommended avoiding the use of 'px' (pixels) to define the size of objects since pixels is a screen resolution and may not translate well to other devices. They recommend using mm or in for dimensions.


        1. fop-0.92-upgrade-patch.zip
          4.21 MB
          John Martin
        2. patch_ofbiz_fop-0.92upgrade-fix_xslfo.diff
          11 kB
          Christian Geisert
        3. patch_ofbiz_fop-0.92upgrade.diff
          45 kB
          Christian Geisert



            • Assignee:
              jacopoc Jacopo Cappellato
              pbwebguy John Martin
            • Votes:
              1 Vote for this issue
              0 Start watching this issue


              • Created: