While FOP 0.93 is better in many respects, it is still being actively developed, and has some problems that should be fixed before it reaches version 1.0.

This particular error is due to the use of empty fo:wrapper elements to position markers for indexterms in the content. The current fop does not like fo:wrapper outside of a block (although it is permitted in the standard). If you put your indexterm elements inside your title or para elements, then it will work.

You might also set the DocBook stylesheet parameter fop1.extensions to 1 in your customization file.

Bob Stayton
Sagehill Enterprises
DocBook Consulting
[EMAIL PROTECTED]


----- Original Message ----- From: "T.G. Mutato" <[EMAIL PROTECTED]>
To: <[email protected]>
Sent: Wednesday, April 11, 2007 12:32 PM
Subject: [docbook-apps] DocBook 4.5, XSL 1.72.0 and FOP 0.93 all working together?


Hello,

Anyone had any luck getting DocBook 4.5, XSL 1.72.0 and FOP 0.93 all
working together to produce PDF output? I've found that even a very
simple DocBook file won't compile properly with the 0.93 version of
FOP from apache.org.

Here's the sample:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE book SYSTEM "dtd/4.5/docbookx.dtd">
<book>
<bookinfo>
<title>My First Book</title>
<author><firstname>Jane</firstname><surname>Doe</surname></author>
<copyright><year>1998</year><holder>Jane Doe</holder></copyright>
</bookinfo>
<chapter id="chapterone">
<title id="atitleid">Here's our Chapter Title</title>
<indexterm>
<primary>a nice index entry</primary>
</indexterm>
<sect1 id="sectionone">
<title>Here's our Section Title</title>
<indexterm>
<primary>anothter nice index entry</primary>
</indexterm>
<para>
Lorem ipsum dolor sit amet, consectetuer adipiscing elit. In
tortor nibh, facilisis ac, consectetuer eget, malesuada
molestie, augue. Etiam non nibh eget elit tincidunt commodo.
</para>
</sect1>
</chapter>
<index id="index"/>
</book>

I'm building the fo file (on Windows) with the command:
xsltproc --nonet --xinclude --output testbook.fo pdfdoc.xsl testbook.xml

and then building (trying to) the pdf file with the command:
fop\fop.bat -fo testbook.fo -pdf testbook.pdf

FOP seems to have trouble with hyphenation so the pdfdoc.xsl file used
when building testbook.fo looks like:

<xsl:stylesheet
xmlns:xsl="http://www.w3.org/1999/XSL/Transform";
xmlns:fo="http://www.w3.org/1999/XSL/Format";
version="1.0">

<xsl:import href="xsl/1.72.0/fo/docbook.xsl"/>

<xsl:param name="hyphenate" select="'false'"/>

</xsl:stylesheet>

Running fop produces:
SEVERE: Exception
java.lang.ClassCastException:
org.apache.fop.layoutmgr.inline.WrapperLayoutManager

The new FOP processor (0.93) is supposed to be quite a bit better than
the old 0.25 version but not if it doesn't work!

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]






---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to