]> granicus.if.org Git - docbook-dsssl/commitdiff
Add anchor for xml:id for listitem in varlistentry.
authorBob Stayton <bobs@sagehill.net>
Mon, 26 Feb 2007 07:53:03 +0000 (07:53 +0000)
committerBob Stayton <bobs@sagehill.net>
Mon, 26 Feb 2007 07:53:03 +0000 (07:53 +0000)
xsl/html/lists.xsl

index 9b8599cb233963e040f80a46b87f768e4a2352d8..5e9f36203a49eb5e3033adf9f48d1930b9b17617 100644 (file)
 </xsl:template>
 
 <xsl:template match="varlistentry/listitem">
+  <!-- we can't just drop the anchor in since some browsers (Opera)
+       get confused about line breaks if we do. So if the first child
+       is a para, assume the para will put in the anchor. Otherwise,
+       put the anchor in anyway. -->
+  <xsl:if test="local-name(child::*[1]) != 'para'">
+    <xsl:call-template name="anchor"/>
+  </xsl:if>
+
   <xsl:choose>
     <xsl:when test="$show.revisionflag != 0 and @revisionflag">
       <div class="{@revisionflag}">