]> granicus.if.org Git - docbook-dsssl/commitdiff
Fix bug where toc.section.depth=0 causes a book toc to ignore
authorBob Stayton <bobs@sagehill.net>
Tue, 1 Nov 2011 00:21:48 +0000 (00:21 +0000)
committerBob Stayton <bobs@sagehill.net>
Tue, 1 Nov 2011 00:21:48 +0000 (00:21 +0000)
chapters and appendixes.

xsl/fo/autotoc.xsl

index 2c9c83c5a14c2de7cb95198eddb89b424edd8c46..6261e157c55ce72a1ce2ff3e027105569a6a69f4 100644 (file)
 
   <xsl:variable name="depth.from.context" select="count(ancestor::*)-count($toc-context/ancestor::*)"/>
 
-  <xsl:if test="$toc.section.depth > 0 
-                and $toc.max.depth > $depth.from.context
+  <xsl:if test="$toc.max.depth > $depth.from.context
                 and $nodes">
     <fo:block id="toc.{$cid}.{$id}">
       <xsl:attribute name="margin-{$direction.align.start}">
 
   <xsl:variable name="depth.from.context" select="count(ancestor::*)-count($toc-context/ancestor::*)"/>
 
-  <xsl:if test="$toc.section.depth > 0 
-                and $toc.max.depth > $depth.from.context
+  <xsl:if test="$toc.max.depth > $depth.from.context
                 and $nodes">
     <fo:block id="toc.{$cid}.{$id}">
       <xsl:attribute name="margin-{$direction.align.start}">
 
   <xsl:variable name="depth.from.context" select="count(ancestor::*)-count($toc-context/ancestor::*)"/>
 
-  <xsl:if test="$toc.section.depth > 0 
-                and $toc.max.depth > $depth.from.context
+  <xsl:if test="$toc.max.depth > $depth.from.context
                 and $nodes">
     <fo:block id="toc.{$cid}.{$id}">
       <xsl:attribute name="margin-{$direction.align.start}">