]> granicus.if.org Git - docbook-dsssl/commitdiff
Now HTML tables have their id attribute so links from
authorBob Stayton <bobs@sagehill.net>
Mon, 12 Apr 2004 02:51:55 +0000 (02:51 +0000)
committerBob Stayton <bobs@sagehill.net>
Mon, 12 Apr 2004 02:51:55 +0000 (02:51 +0000)
the list of tables and xrefs to the tables work.

xsl/fo/htmltbl.xsl

index 975e94757a24e57225fafd2d0eb3073cab889b0f..e6d54a687524cd37dd55902af693280c45668f80 100644 (file)
       <xsl:message terminate="yes">Broken table: row descendent of HTML table.</xsl:message>
     </xsl:if>
 
+    <xsl:variable name="id">
+      <xsl:call-template name="object.id"/>
+    </xsl:variable>
+
     <xsl:variable name="numcols">
       <xsl:call-template name="widest-html-row">
         <xsl:with-param name="rows" select=".//tr"/>
@@ -34,7 +38,7 @@
 
     <xsl:choose>
       <xsl:when test="caption">
-        <fo:table-and-caption>
+        <fo:table-and-caption id="{$id}">
           <xsl:apply-templates select="caption" mode="htmlTable"/>
           <fo:table table-layout="fixed">
             <xsl:attribute name="width">
@@ -53,7 +57,7 @@
         </fo:table-and-caption>
       </xsl:when>
       <xsl:otherwise>
-        <fo:table table-layout="fixed">
+        <fo:table table-layout="fixed" id="{$id}">
           <xsl:attribute name="width">
             <xsl:choose>
               <xsl:when test="@width">