[oXygen-user] DocBook 'hyphenate.verbatiem' parameter and FOP

Sorin Ristache sorin at sync.ro
Mon Jan 23 07:22:50 CST 2012


Hello,

I tried the following workaround and it works: revert to the previous FOP version used in Oxygen, that is FOP 0.95. Only 2 files should be copied in the [Oxygen-13.2-folder]/lib folder: fop.jar (0.95) and xmlgraphics-commons-1.3.1.jar. The file xmlgraphics-commons-1.4.jar must be removed.

If you don't have Oxygen 11.2 installed (the last version with FOP 0.95) please download the 2 files from:

http://www.oxygenxml.com/userFiles/fop.jar.zip

http://www.oxygenxml.com/userFiles/xmlgraphics-commons-1.3.1.jar.zip

The bug that you mentioned was fixed in Apache FOP and will be included in FOP 1.1. The current stable version is FOP 1.0.

Error 3 from Claudio Tubertini's message was caused by a character from a Unicode range not supported correctly by Apache FOP. Looking at your XML document I think that was a different problem.


Regards,
Sorin


Tony Graham wrote:
> Using oXygen 13.2's DocBook FO stylesheets and FOP and the
> <programlisting> in the document below (hopefully the long lines didn't
> get wrapped by my mailer), when the 'hyphenate.verbatim' parameter is set
> to '1' in the transformation scenario, the transformation fails with the
> following message:
> 
> ------------------------------------
> System ID: Untitled1.xml
> Scenario: Docbook PDF duplicate
> XML file: Untitled1.xml
> XSL file: C:\Program Files\Oxygen XML Editor
> 13\frameworks\docbook\xsl\fo\docbook_custom.xsl
> Engine name: Apache FOP
> Severity: error
> Description: The process 'Apache FOP' ended with code: 1.
> The error was:
> ERROR - Exception
> java.lang.IllegalArgumentException: factor < 0; was: -1
> 	at org.apache.fop.cli.InputHandlerFOP.transformTo(Unknown Source)
> 	at org.apache.fop.cli.InputHandlerFOP.renderTo(Unknown Source)
> 	at org.apache.fop.cli.Main.startFOP(Main.java:174)
> 	at org.apache.fop.cli.Main.main(Main.java:205)
> Caused by: java.lang.IllegalArgumentException: factor < 0; was: -1
> 	at org.apache.fop.traits.MinOptMax.mult(MinOptMax.java:251)
> 	at
> org.apache.fop.layoutmgr.inline.TextLayoutManager.processWord(TextLayoutManager.java:825)
> ------------------------------------------------
> 
> This appears to be the same stack trace as error 3 in:
> 
> http://www.oxygenxml.com/pipermail/oxygen-user/2011-December/003951.html
> 
> and also appears to be fixed in FOP post-1.0:
> 
> https://issues.apache.org/bugzilla/show_bug.cgi?id=49837
> 
> Installing a development version of FOP isn't really an option, so are
> there any other ideas for how to solve this?
> 
> Regards,
> 
> 
> Tony Graham                                   tgraham at mentea.net
> Consultant                                 http://www.mentea.net
> Mentea       13 Kelly's Bay Beach, Skerries, Co. Dublin, Ireland
>  --  --  --  --  --  --  --  --  --  --  --  --  --  --  --  --
>     XML, XSL-FO and XSLT consulting, training and programming
> 
> 
> <article xmlns="http://docbook.org/ns/docbook"
>     xmlns:xlink="http://www.w3.org/1999/xlink" version="5.0">
>     <title><tag>code</tag> Breaking</title>
>     <programlisting>     There was movement at the station, for the word
> had passed around
>      That the colt from old Regret had got away,
>      And had joined the wild bush horses -- he was worth a thousand pound,
>      So all the cracks had gathered to the fray.
>      All the tried and noted riders from the stations near and far
>      Had mustered at the homestead overnight,
>      For the bushmen love hard riding where the wild bush horses are,
>      And the stock-horse snuffs the battle with delight.
> </programlisting>
> </article>


More information about the oXygen-user mailing list