Hi Stefan,
Actually, this can be done without customizing the book template:

1.  Add an empty <toc/> element after your preface element.

2.  Set these params:

<xsl:param name="process.empty.source.toc" select="1"/>
<xsl:param name="generate.toc">book title</xsl:param>

The first param tells the stylesheet to generate a table of contents where an empty toc element appears.

The second param is needed to get a title on the table of contents.

There is no similar method to be used for List of Tables, etc., because an empty <lot/> element does not have an attribute to indicate what kind of list should be generated. A lot element must have content to be processed, or some customization based on role must be done.

I'll add this information to the next edition of my book.

Bob Stayton
Sagehill Enterprises
[email protected]


----- Original Message ----- From: "Stefan Seefeld" <[email protected]>
To: "DocBook Apps Mailing List" <[email protected]>
Sent: Wednesday, August 17, 2011 4:13 PM
Subject: [docbook-apps] listing the TOC after the preface / foreword


Hello,

I'm in the process of converting a LaTeX document (a specification) to
DocBook. The original had the auto-generated TOC following the preface,
just before the first chapter.

I wonder what the best way is to reproduce that with xsl-docbook. It
seems by default the TOC precedes the preface, and there is no parameter
to tweak.

Is customizing the <xsl:template match="book"> template the only option ?

Thanks,
Stefan

--

     ...ich hab' noch einen Koffer in Berlin...

---------------------------------------------------------------------
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