]> granicus.if.org Git - docbook-dsssl/commitdiff
Don't generate ToC links if there's nothing to go in the ToC
authorNorman Walsh <ndw@nwalsh.com>
Mon, 18 Mar 2002 20:42:35 +0000 (20:42 +0000)
committerNorman Walsh <ndw@nwalsh.com>
Mon, 18 Mar 2002 20:42:35 +0000 (20:42 +0000)
xsl/fo/fop.xsl
xsl/fo/xep.xsl

index 1cebdd3ed2eed147cc28487cc8fafeec77832ed7..545998f35598486a542fbebf3d43b8a3b0a1d88f 100644 (file)
@@ -62,7 +62,10 @@ translates characters with code>255 back to ASCII.
           <xsl:with-param name="table" select="normalize-space($generate.toc)"/>
         </xsl:call-template>
       </xsl:variable>
-      <xsl:if test="contains($toc.params, 'toc')">
+      <xsl:if test="contains($toc.params, 'toc')
+                    and section|sect1|refentry
+                        |article|bibliography|glossary
+                        |appendix">
         <fox:outline internal-destination="toc...{$id}">
           <fox:label>
             <xsl:call-template name="gentext">
index 391bbff7a4854265883efcbf9c4111edfc87ab5b..757466c8378fdd0efff479029085531d681ee985 100644 (file)
           <xsl:with-param name="table" select="normalize-space($generate.toc)"/>
         </xsl:call-template>
       </xsl:variable>
-      <xsl:if test="contains($toc.params, 'toc')">
+      <xsl:if test="contains($toc.params, 'toc')
+                    and section|sect1|refentry
+                        |article|bibliography|glossary
+                        |appendix">
         <rx:bookmark internal-destination="toc...{$id}">
           <rx:bookmark-label>
             <xsl:call-template name="gentext">