FOP (Formatting Objects Processor) is the world's first print formatter driven by XSL formatting objects (XSL-FO) and the world's first output independent formatter.
Apache FOP project is a Java application that reads a formatting object (FO) tree and renders the resulting pages to a specified output. Output formats currently supported include PDF, PCL, PS, SVG, XML (area tree representation), Print, AWT, MIF and TXT. The primary output target is PDF.
What's New in This Release: [ read full changelog ]
· Changes to the End-User API
· addAdded a command-line option '-catalog' to use a catalog resolver for the XML and XSLT files Committed by SP.
· Changes to the Code Base
· add Added support for xmlfile and xsltfile parameters in FOP's Ant Task. Committed by AC.
· add Added the possibility to use CachedRenderPagesModel, to conserve memory in case of large documents with a lot of cross-references (area tree will be serialized to disk to avoid keeping it entirely in memory). Committed by AD. Thanks to Dario Laera. See Issue 46828.
· add Added an event handling framework which allows to get better feedback from within FOP with the ability to customize problem management. Committed by JM.
· fix Bugfix: when #CMYK pseudo-profile was used in the rgb-icc() function, always the fallback RGB colors were used instead. Committed by VH. Thanks to Venkat Reddy. See Issue 48167.
· fix White-space handling in markers with inline-content throws a NullPointerException in some cases. Committed by AD. See Issue 47710.
· fix Bugfix: previously retrieved markers were not cleared if the new marker was empty. Committed by AD. See Issue 46960.
· fix Changed meaning of ‘-v’ option to ‘verbose’, which will print FOP’s version and proceed. Added a ‘-version’ option to simply print the version then exit, following Java practices. Committed by VH.
· fix MinOptMaxUtil.toMinOptMax was converting LengthRangeProperty objects into illegal MinOptMax objects (in some cases opt could be inferior to min). Committed by VH. See Issue 46638.
· fix Fixed a memory-leak in Marker.MarkerAttribute, where an instance was used both as key and value in a WeakHashMap, effectively neutralizing the benefit of using WeakReferences. Solved by extending PropertyCache to work for MarkerAttributes as well. Committed by AD. See Issue 46319.
fix Fixed some multi-threading issues in FontCache.java:
· remove the unused private readObject()
· make the changeLock member final (initialization-safety + impossible to reassign)
· perform the HashMap check for a failed font inside the synchronized block to avoid a race condition
· Committed by AD. Thanks to rogov.AT.devexperts.com. See Issue 46211.
· fix Make fop.bat and fop.cmd use the %FOP_OPTS% environment variable. Committed by AD. Thanks to Carsten Siedentop. See Issue 45842.
· fix Quick-fix to avoid a possible NullPointerException when using empty inlines and hyphenation. Committed by AD. See Issue 45667.
· fix Fixed memory leak in property cache (not cleaning stale PropertyCache$CacheEntry instances). Committed by JM.
· fix Fixed a slight error when resolving non-file URLs: avoid altering the original 'href' if the protocol is other than 'file:' Committed by AD. Thanks to Thomas Stieler. See Issue 45490.
· fix Corrected white-space-treatment for situations where an inline-node is the first/last child node of an fo:block, without preceding/following text. Committed by AD. See Issue 45097.
· fix Fixed a logic error in Hyphenator.java: If the source had an associated InputStream, an UnsupportedOperationException was triggered. Committed by AD. See Issue 44203.
· update Changed FONode.addCharacters() parameter to closer match the signature of the standard SAX characters() event (reduces confusion and computations). !! Implementors of extensions that subclass FONode directly, and offer an implementation for addCharacters() should take care to make similar modifications in their code !! Committed by AD.
· Changes to the Bundled Extensions
· add Added support for the #CMYK pseudo-profile supported by some commercial XSL implementations on the rgb-icc() function. Committed by JM.
· Changes to the Font Subsystem
· add Added support for TrueType fonts with symbol character maps (like "Wingdings" and "Symbol"). Character for these fonts are usually found in the 0xF020 to 0xF0FF range (a Unicode private use area). Committed by JM.
· add Added support for specifying referenced fonts per renderer in addition to the general match list. Committed by JM.
· add Added a command-line tool to list all configured fonts (org.apache.fop.tools.fontlist.FontListMain). Committed by JM.
· add AFP Fonts: Added support for full URI resolution on configured AFP fonts. Committed by JM.
· add FOP now creates ToUnicode CMaps for single-byte fonts that don't use built-in encodings to help PDF text extractors interpreting characters. Committed by JM.
· add Added support for forcing single-byte encodings for TrueType fonts without creating an XML font metric file (see "encoding-mode" attribute on "font" element) Committed by JM.
· add For auto-detected fonts it is now possible to specify that a font needs to be referenced rather than embedded (for the output formats that support this distinction). Committed by JM.
· add Add support for font substitution. Committed by AC.
· add Added support for auto-configuring TrueType Collections. XML font metrics files for *.ttc fonts are not required anymore. Committed by JM. Thanks to Jason Harrop. See Issue 44737.
· add Added support for addressing all glyphs available in a Type 1 font, not just the ones in the font's primary encoding. Committed by JM.
· fix Bugfix: Font selection fallbacks did not work in some cases (ex. bold+italic to normal) Committed by JM.
· fix Fixed generation of CIDSet object in PDF output. Committed by JM. Thanks to Nicolas Peninguy. See Issue 47711.
· fix Bugfix: support PFM Files with no extent table. Committed by CB.
· fix Bugfix: for the last character of a Type1 font, always a width of 0 was returned. Committed by VH. Thanks to Maxim Wirt. See Issue 47232.
· fix Use temporary directory for the font cache if the user home directory is not write-accessible. Committed by JM. Thanks to Alok Singh. See Issue 46686.
· fix More robust AFP font parsing, although it is still in need of some rework in the future. Committed by AC.
· fix Fix for PFMReader after bug #43089 changed the behavior of PFMFile. Fixes baseline problems when Type 1 fonts are used in conjunction with XML font metric files. Committed by JM. Thanks to J. Frantzius. See Issue 45734.
· Changes to the Image Support
· add Added customization ability for the image loading framework from FOP's configuration file. Committed by JM.
· add Added support for SVG 1.2 functionality inside fo:instream-foreign-object. Committed by JM. See Issue 41657.
· fix Bugfix: use the effective color profile supplied by the ImageEncodingHelper, instead of the original one. Committed by JM.
· Changes to the Layout Engine
· addImplement internal character classes if the hyphenation pattern file does not contain them Committed by SP.
· add Added limited support for pages of different inline-progression-dimensions within a page-sequence. Committed by VH.
· add Added basic implementation for column-keeps. Committed by AD. See Issue 46905.
· add Added extension to disable column balancing before blocks spanning the whole page, in multiple-column documents. Committed by VH. Thanks to Georg Datterl. See Issue 46315.
· add Added missing generation of areas for empty grid units in tables with collapsing border model. Committed by JM.
· add Allowing non-zero borders and padding on page regions when relaxed validation is turned on. Committed by LF.
· add Implemented word-by-ford font-selection strategy on text. Committed by MB.
· add Support character-by-character font-selection strategy on fo:character element. Committed by MB.
· add Added minimal support for integer keep values on the various keep properties on block-level FOs. For now, all integer values are treated the same (i.e. without strength distinction). Using integers allows to avoid overflows that can happen when "always" is used extensively. Committed by JM.
· fix Bugfix: having a special page-master for the last page caused loss of content when normal blocks were mixed with blocks spanning all columns. Committed by VH. See Issue 46486.
· fix Bugfix: value of conditional space not always taken into account in the calculation of a table’s height. Committed by VH. See Issue 48082.
· fix Fixed handling of percentage values for provisional-label-separation. Committed by VH.
· fix Fixed handling of percentage values for provisional-distance-between-starts. Committed by VH. Thanks to Jonathan Levinson. See Issue 47835.
· fix Bugfix: The cells of a table inside a marker were duplicated at every marker retrieval. Committed by VH. See Issue 47101.
· fix Bugfix: footnotes occurring within the forced height of a table row did not appear on the output Committed by VH.
· fix Fixed a bug when combining a forced break with a "last" page-master. The restart of the algorithm would start at the index of the penalty corresponding to the last page-break. This has been changed to the index of the first element after the last page-break. Committed by AD. See Issue 46489.
· fix Fixed BPD trait and border painting for leaders with leader-pattern="space" (and similar cases). Committed by JM.
· fix Fixed fo:instream-foreign-object inside fo:marker. Committed by JM. See Issue 45306.
· fix Fixed a bug when combining break-before with a span change. Committed by AD. See Issue 46240.
· fix Fixed a problem where the BPD or a block area could be wrong if there is a nested, absolutely positioned area (for example a block-container). Committed by JM.
· fix Bugzilla 40798: A conditional-page-master-reference with page-position="last" qualifies for a first page, if it is also the last. Additionally: also added support for page-position="only". Committed by AD. See Issue 40798.
· fix Fixed the source for a division by zero when the content of an fo:leader with leader-pattern="use-content" collapses to zero width during layout. Committed by JM.
· fix Fixed ID resolution for nested bookmarks with duplicated IDs. Committed by JM.
· fix Added LayoutManagerMapping.registerMaker() to make registration of custom layout managers easier. Committed by JM. See Issue 45470.
· fix Fixed absolute positioning of block-containers when specified using right and bottom instead of left and top. Committed by LF.
· fix Fixed an inconsistency in footnote handling that led to unnecessary empty areas in pages whose last normal line contains footnotes when the page bpd is not the same for all pages. Committed by LF.
· fix Added support for page-number-citation and page-number-citation-last of fo:inline. Corrected behavior for page-number-citation-last of fo:block: forward references now properly resolved. Committed by AD. See Issue 44794.
· fix Added support for the "id" attribute on fo:wrappers when used as a child of the fo:flow. Committed by AD. See Issue 42423.
· fix Fixed a ClassCastException when using an fo:wrapper as a child of an fo:block-container. Committed by AD. See Issue 41500.
· fix Fixed a regression introduced by the fix for Bugzilla 44286. Committed by AD. See Issue 42703.
· fix Activated min-height/max-height and min-width/max-width properties. Committed by AD. See Issue 43591.
· Changes to Renderers (Output Formats)
· add AFP Output: Added enhanced dithering functionality for images that are converted to bi-level images. Committed by JM.
· add Initial support for CID-keyed double-byte fonts (Type 0) in AFP output. Committed by JM. Thanks to Peter Hancock. See Issue 48567.
· add Added possibility to customize PDF tagging via the ‘role’ property. Committed by VH.
· add Added basic accessibility and Tagged PDF support. Committed by JM,VH. Thanks to Jost Klopfstein. See Issue 46705.
· add Added support for encoding CMYK bitmap images (IOCA FS45) and TIFF images as embedded objects. Committed by JM.
· add Added support for positioning Page Overlays in AFP Output Committed by CB.
· add Added support for creating thumbnails or preview bitmaps of fixed size for PNG and TIFF output. Committed by JM.
· add AFP Output: Added support for IMM Extension on fo:simple-page-master. Committed by CB.
· add Added an initial set of extensions for prepress support (fox:bleed, fox:crop-offset, fox:crop-box and fox:scale). This is currently supported only by PDF and Java2D renderers. Committed by JM. Thanks to Peter Coppens. See Issue 47311.
· add PCL Output: Added support for specifying the output bin. Committed by JM.
· add AFP Output: Added support for embedding external AFP form maps (form defs) using the afp:include-form-map extension. Committed by JM.
· add AFP Output: Added support for AFP font embedding. Note: this changes the default behaviour. Like with PDF and PS, all fonts are embedded by default unless matched in the "referenced-fonts" section in the configuration. Committed by JM.
add AFP Renderer Raster Fonts:
· added support for fractional font-sizes in the configuration.
· selection of the smaller font-size, in case two possible fallbacks have the same difference to a requested size.
· Committed by AD.
· add Added setting to enable dithered painting of filled rectangles in AFP and PCL. Committed by JM.
· add Added a custom text painter for rendering SVG text using text operators when rendering to PostScript or EPS. Text is no longer painted as shapes, thus creating much smaller files. Committed by JM. See Issue 47000.
· add AFP Output: Tag Logical Element (TLE) is now also allowed on fo:page-sequence (page group level). Committed by JM.
· add AFP Output: Added support for Invoke Medium Map (IMM). Committed by JM.
· add Introduced a new, additional intermediate format optimized for performance. Please see the intermediate format documentation for details. Committed by JM.
· add AFP Output: Added a configuration option to override the resource level defaults in the code. Committed by JM.
· add AFP Output: Bilevel images in resource groups as generated as hard page segments (instead of image objects) for better interoperability with older IPDS environments and for better printing performance. Committed by JM.
· add AFP Output: An AFPGraphics2D implementation which provides the ability to use Batik to drive the production of AFP Graphics (GOCA) output from SVG. Committed by AC.
· add AFP Output: Resource group leveling, external streaming, and de-duplication of images and graphics using IncludeObject and ResourceGroup. Committed by AC.
· add AFP Output: Native image embedding support (e.g. JPEG, GIF, TIFF) using ObjectContainer and a MOD:CA Registry implementation. Committed by AC.
· add Added PDF /Launch action: references to URIs using the file:// protocol will now generate a /Launch action as opposed to a more general /URI (which doesn't yield the expected result for this protocol). Committed by AD. Thanks to Alexander Stamenov. See Issue 45113.
· add PDF Output: Added support for handling 16-bit alpha channel. They are currently converted to 8 bits. Committed by JM. See Issue 45795.
· add Added PDF encryption parameter support in configuration. Committed by AC.
· add Added a PCL-specific extension attribute on simple-page-master for controlling the simplex/duplex mode. Committed by JM. Thanks to Martin Edge. See Issue 45115.
· add Add partial support for the "show-destination" property on fo:basic-link (PDF output only; see limitations on the compliance page) Committed by AD. See Issue 44634.
· add Added support for rendering pages using JPS (Java Printing System). See new example: examples/embedding/java/ExamplesFO2JPSPrint.java Committed by JM.
· add Restored ability to specify from/to and odd/even pages as well as the number of copies for printing from the command-line. Committed by JM. See Issue 41687.
· add Added ability to pass a preconfigured PrinterJob instance to the PrintRenderer via the rendering options map. Committed by JM. Thanks to Antti Karanta. See Issue 44678.
· add Added a public accessor for reference to the current page to PDFGraphics2D. Committed by JM. Thanks to Yegor Kozlov. See Issue 44743.
· fix AFP Output: Fixed positioning of Java2D-based images (when GOCA is enabled). Committed by JM.
· fix AFP Output: Fix for bitmap images inside an SVG or G2D graphic (printer errors) and positioning fix for bitmaps from G2D graphics. Committed by JM.
· fix Fix for AWT viewer to correctly track page numbers in continuous display mode. Committed by JM. Thanks to Richard Wheeldon. See Issue 42306.
· fix Bugfix for formatting of floating point numbers which could lead to invalid PDFs. Committed by JM.
· fix Added a save/restoreGraphicsState pair for the initial coordinate system in PDF output for easier post-processing. Committed by JM.
· fix Bugfix for color model in IOCA IDE structure parameter for 4- and 8-bit grayscale images. Committed by JM. Thanks to Peter Hancock. See Issue 48696.
· fix Bugfix: AFP Renderer: Respect image color settings for svg Committed by CB. Thanks to Peter Hancock. See Issue 48237.
· fix Bugfix: AFP Renderer: Page Overlays not generated when using Intermediate Format Committed by CB. Thanks to Venkat Reddy. See Issue 48376.
· fix Bugfix: AFP Renderer: Underline is incorrectly placed when reference-orientation != 0 Committed by CB. See Issue 48456.
· fix Bugfix: AFP Renderer: Page Segments not positioned correctly when reference-orientation != 0 Committed by CB. See Issue 48453.
· fix Bugfix: AFP Renderer: AttributeQualifier Triplet occurs before TLE Value. Committed by CB. See Issue 48290.
· fix Bugfix in AFP output: fixed flags in GOCA GBAR order. Committed by JM. Thanks to D.W. Harks. See Issue 48048.
· fix Bugfix in AFP output: rounding error when computing the CMYK components of a color. Committed by VH. Thanks to Harald G. Henne. See Issue 48185.
· fix BugFix: Maintain valid AFP by providing TLE truncation on Attribute Value Triplet values that are greater than 250 chars in length. Committed by AC. See Issue 47941.
· fix Dithered Background Shading can produce illegal AFP if objects are very small Committed by CB. See Issue 47694.
· fix Bugfix: Error while writing TLE's attribute qualifier in the output. Committed by AD. Thanks to Bharat Attaluri. See Issue 47508.
· fix Bugfix: support justified text in AFP Renderer (already working in AFP Painter) Committed by CB.
· fix Bugfix: reset graphic state when a page is finished in PostScript. Committed by JM.
· fix Fixed a bug that left the PrintRenderer unconfigured even if a configuration was specified for "application/X-fop-print". Committed by JM.
· fix Fixed the handling of CMYK colors in PDFGraphics2D. Committed by JM. Thanks to Yegor Kozlov. See Issue 46882.
· fix AFP Fonts: Fixed interpretation of metric for fonts with fixed metrics and made sure all repeating groups in FNP (Font Position) are processed. Committed by JM. Thanks to Emil Maskovsky. See Issue 45342.
· fix Fixed black backgrounds occurring for transparent images in PCL output. Committed by JM.
· fix Fixed bug that caused AFP Renderer Extensions to be ignored. Committed by CB. See Issue 46369.
· fix Fixed a multi-threading issue when rendering SVG. Committed by JM.
· fix PDF Output: Made sure the XMP Metadata stream is never compressed. Committed by JM.
· fix Fix for table handling in RTF output, so the output works with OpenOffice and AbiWord, too. Committed by JM. Thanks to Pavel Kysilka. See Issue 45616.
· fix Fixed text stroking in SVG when the stroke-width is zero. Committed by JM.
· fix Fixed border trait parsing for the area tree XML when CMYK or ICC colors were used. Committed by JM.
· fix Fixed generation of "fonttbl" for RTF output to fix loading problem with AbiWord. Committed by JM. Thanks to Pavel Kysilka. See Issue 45606.
· fix PCL Renderer: Improved page format selection so it doesn't interfere with duplex printing. Committed by JM. See Issue 43650.
· update PDFGraphics2D.writeClip doesn't generate a clip command anymore when the clip path is empty. Committed by JM. Thanks to Francois Fernandes. See Issue 47031.
· update When a JPEG image is embedded, an optionally embedded color profile is filtered out as it's already embedded separately in the PDF file. Committed by JM.