FO hyphenate.verbatim not working
Here should go questions about transforming XML with XSLT and FOP.
-
- Posts: 5
- Joined: Mon Sep 24, 2012 6:54 pm
FO hyphenate.verbatim not working
When I enable it I get an exception:
So I found another thread which tells me to download some old FOP libs (which I did).
Now there are just hyphens littering my programlisting elements.
I just want programlisting elements to wrap on the page instead of running of the page.
Any help would be very much appreciated.
Code: Select all
ERROR - Couldn't find hyphenation pattern en
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)
Now there are just hyphens littering my programlisting elements.
I just want programlisting elements to wrap on the page instead of running of the page.
Any help would be very much appreciated.
-
- Posts: 5
- Joined: Mon Sep 24, 2012 6:54 pm
Re: FO hyphenate.verbatim not working
Here is the best solution I came up with in case anyone else is having this problem:
Please this code in your docbook_custom.xsl
Please this code in your docbook_custom.xsl
Code: Select all
<xsl:template match="d:programlisting">
<fo:block language="en"
wrap-option="wrap"
linefeed-treatment="preserve"
font-family="monospace"
white-space-collapse="false"
white-space-treatment="preserve">
<xsl:apply-templates></xsl:apply-templates>
</fo:block>
</xsl:template>
-
- Posts: 4141
- Joined: Fri Mar 28, 2003 2:12 pm
Re: FO hyphenate.verbatim not working
Post by sorin_ristache »
Hi,
Thank you for letting us know the workaround that you found. The FO transformation should not end with an IllegalArgumentException. This is a bug in the Apache FOP processor. By forcing a wrap inside the fo:block corresponding to a programlisting element you avoided the bug.
Regards,
Sorin
Thank you for letting us know the workaround that you found. The FO transformation should not end with an IllegalArgumentException. This is a bug in the Apache FOP processor. By forcing a wrap inside the fo:block corresponding to a programlisting element you avoided the bug.
Regards,
Sorin
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service