DocBook to HTML chunk - Table of figures

K

K.Simon

Hello,
I'm converting books from Docbook to HTML-chunk. For my needs it is
necessary to append the list of figures at the end instead the
beginning of the book as it is default in docbook.
After many different attempts I'm stumped :-(.
So i could really need any help.
My last attempt which didn't work:

<!-- Thought that I can call the list of figures when there is an
appendix-tag
which now will be overridden -->
<xsl:template match="appendix">
<!- I'm calling the template which generates the list of figures -->
<xsl:apply-templates select="/book//figure" mode="test"/>
</xsl:template>

<xsl:template match="figure" mode="test">
<xsl:param name="toc-context" select="."/>

<xsl:element name="{$toc.listitem.type}"-->
<xsl:variable name="label">
<xsl:apply-templates select="." mode="label.markup"/>
</xsl:variable>
<xsl:copy-of select="$label"/>
<xsl:if test="$label != ''">
<xsl:value-of select="$autotoc.label.separator"/>
</xsl:if>
<a>
<xsl:attribute name="href">
<xsl:call-template name="href.target"/>
</xsl:attribute>
<xsl:apply-templates select="." mode="title.markup"/>
</a>
<!--/xsl:element>
</xsl:template>

The result is as follow:
The list of figures is generated but placed at the first site (chunk)
instead of the last site (chunk) as it was before :-(.
At the last site stands: Chapter 6
List of Figures (without any gnerated toc
only the heading)

So please, can anybody out there assist?
It seems so easy to place the generated list of figures to another
place of the document but I couldn't find out how :-(.

Conny
 
M

Michael Wiedmann

K.Simon said:
I'm converting books from Docbook to HTML-chunk. For my needs it is
necessary to append the list of figures at the end instead the
beginning of the book as it is default in docbook.

I don't have a quick answer for you, but the following hints:

- read carefully Bob Stayton's excellent "DocBook XSL: The Complete Guide",
especially the chapter "Tables of contents (TOC)"
(http://www.sagehill.net/docbookxsl/TOCcontrol.html)

- ask at the DocBook Apps ML, usually you'll get a very quick response

Michael
 
K

K.Simon

I don't have a quick answer for you, but the following hints:
- read carefully Bob Stayton's excellent "DocBook XSL: The Complete Guide",
especially the chapter "Tables of contents (TOC)"
(http://www.sagehill.net/docbookxsl/TOCcontrol.html)

I know this book but there is no solution for the described problem
inside.
- ask at the DocBook Apps ML, usually you'll get a very quick response

Unfortunately, I've got no answer in this group. Inapprehensible
because it seems to me that my problem is not exceptional. Is there
anybody out there who has ever seen a book with the list of figures on
the first site? So why is there no solution to fix that?
I'm arriving to the conclusion that docbook sucks. Take a look at the
converting of the tag acronym for example. Did they ever note that
there exists a tag acronym in html and that this should be used to
ensure access for disabled people? Have they ever heard that there
exists a title attribute? Isn't it awful to use crutches like
attribute condition instead?

But worst there is no help from the docbbook group and even Norman W.
didn't give any response to the list of figure problem. Either he
can't overlook over his own code anymore or he is unhelpful. In the
last case it must be very time-consuming to give a hint which template
should be modified.
I'm really disappointed :-((.

Thanks for your answer. It was the only one.

Conny
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,055
Latest member
SlimSparkKetoACVReview

Latest Threads

Top