]> granicus.if.org Git - docbook-dsssl/commitdiff
Make funprototype layout table compatible with html5.
authorBob Stayton <bobs@sagehill.net>
Sat, 12 May 2012 23:36:14 +0000 (23:36 +0000)
committerBob Stayton <bobs@sagehill.net>
Sat, 12 May 2012 23:36:14 +0000 (23:36 +0000)
xsl/html/synop.xsl

index bb78badc2276d7290a5ad1baf306c90d28b7fe0f..c92e9c750bca3fa5a61d350553c4e8fae919ce88 100644 (file)
@@ -360,9 +360,13 @@ paramdef      ::= (#PCDATA|type|replaceable|parameter|funcparams)*
 <!-- funcprototype: kr, tabular -->
 
 <xsl:template match="funcprototype" mode="kr-tabular">
-  <table border="0" summary="Function synopsis" cellspacing="0" cellpadding="0"
-    class="funcprototype-table"
-    >
+  <table border="{$table.border.off}" class="funcprototype-table">
+    <xsl:if test="$div.element != 'section'">
+      <xsl:attribute name="summary">Function synopsis</xsl:attribute>
+    </xsl:if>
+    <xsl:if test="$css.decoration != 0">
+      <xsl:attribute name="style">cellspacing: 0; cellpadding: 0;</xsl:attribute>
+    </xsl:if>
     <tr>
       <td>
         <xsl:apply-templates select="funcdef" mode="kr-tabular"/>
@@ -620,9 +624,15 @@ paramdef      ::= (#PCDATA|type|replaceable|parameter|funcparams)*
 <!-- funcprototype: ansi, tabular -->
 
 <xsl:template match="funcprototype" mode="ansi-tabular">
-  <table border="0" summary="Function synopsis" cellspacing="0" cellpadding="0"
+  <table border="{$table.border.off}" 
     class="funcprototype-table"
     >
+    <xsl:if test="$div.element != 'section'">
+      <xsl:attribute name="summary">Function synopsis</xsl:attribute>
+    </xsl:if>
+    <xsl:if test="$css.decoration != 0">
+      <xsl:attribute name="style">cellspacing: 0; cellpadding: 0;</xsl:attribute>
+    </xsl:if>
     <tr>
       <td>
         <xsl:apply-templates select="funcdef" mode="ansi-tabular"/>