]> granicus.if.org Git - docbook-dsssl/commitdiff
Fix ugly bug: make sure premables to orderedlist and itemizedlist elements are actual...
authorNorman Walsh <ndw@nwalsh.com>
Sun, 7 Jul 2002 23:12:15 +0000 (23:12 +0000)
committerNorman Walsh <ndw@nwalsh.com>
Sun, 7 Jul 2002 23:12:15 +0000 (23:12 +0000)
xsl/fo/lists.xsl
xsl/html/lists.xsl

index 652210081ee684217a34ed54dd439800c6f859bf..a6af5d690848131890c1a4d1c6d10904d25e7b9c 100644 (file)
     <xsl:apply-templates select="title" mode="list.title.mode"/>
   </xsl:if>
 
+  <xsl:apply-templates select="*[not(self::listitem or self::title)]"/>
+
   <fo:list-block id="{$id}" xsl:use-attribute-sets="list.block.spacing"
                  provisional-distance-between-starts="1.5em"
                  provisional-label-separation="0.2em">
-    <xsl:apply-templates/>
+    <xsl:apply-templates select="listitem"/>
   </fo:list-block>
 </xsl:template>
 
     <xsl:apply-templates select="title" mode="list.title.mode"/>
   </xsl:if>
 
+  <xsl:apply-templates select="*[not(self::listitem or self::title)]"/>
+
   <fo:list-block id="{$id}" xsl:use-attribute-sets="list.block.spacing"
                  provisional-distance-between-starts="2em"
                  provisional-label-separation="0.2em">
-    <xsl:apply-templates/>
+    <xsl:apply-templates select="listitem"/>
   </fo:list-block>
 </xsl:template>
 
index 0a9d62b3585a7f15de63909fecb8fad329eb5f10..b2a6445476fd79480da79cd5f7f4c6fe1646a955 100644 (file)
@@ -24,6 +24,9 @@
     <xsl:if test="title">
       <xsl:call-template name="formal.object.heading"/>
     </xsl:if>
+
+    <xsl:apply-templates select="*[not(self::listitem or self::title)]"/>
+
     <ul type="{$itemsymbol}">
       <xsl:if test="@spacing='compact'">
         <xsl:attribute name="compact">
 
   <div class="{name(.)}">
     <xsl:call-template name="anchor"/>
+
     <xsl:if test="title">
       <xsl:call-template name="formal.object.heading"/>
     </xsl:if>
+
+    <xsl:apply-templates select="*[not(self::listitem or self::title)]"/>
+
     <ol>
-    <xsl:if test="$start != '1'">
-      <xsl:attribute name="start">
-        <xsl:value-of select="$start"/>
-      </xsl:attribute>
-    </xsl:if>
-    <xsl:if test="$numeration != ''">
-      <xsl:attribute name="type">
-       <xsl:value-of select="$type"/>
-      </xsl:attribute>
-    </xsl:if>
-    <xsl:if test="@spacing='compact'">
-      <xsl:attribute name="compact">
-       <xsl:value-of select="compact"/>
-      </xsl:attribute>
-    </xsl:if>
-    <xsl:apply-templates select="listitem"/>
+      <xsl:if test="$start != '1'">
+        <xsl:attribute name="start">
+          <xsl:value-of select="$start"/>
+        </xsl:attribute>
+      </xsl:if>
+      <xsl:if test="$numeration != ''">
+        <xsl:attribute name="type">
+          <xsl:value-of select="$type"/>
+        </xsl:attribute>
+      </xsl:if>
+      <xsl:if test="@spacing='compact'">
+        <xsl:attribute name="compact">
+          <xsl:value-of select="compact"/>
+        </xsl:attribute>
+      </xsl:if>
+      <xsl:apply-templates select="listitem"/>
     </ol>
   </div>
 </xsl:template>