← Prev in month ← Prev in thread

RE: [docbook-apps] No border between multiple tgroups in a single cals table for fo output.

From
Mauritz Jeanson <>
Date
2009-02-06T18:12:12+00:00
ID
6497C53D20494F7BBA779D7AF32B0952@D7MZ171J
Thread
RE: [docbook-apps] No border between multiple tgroups in a single cals table for fo output.
|  -----Original Message-----
|  From: Dale Smith 
|  
|  The calsTable template in fo/table.xsl has (edited):
|  
|    <xsl:for-each select="tgroup">
|  
|      <fo:table xsl:use-attribute-sets="table.table.properties">
|        <xsl:call-template name="table.frame"/>
|  
|        <xsl:if test="following-sibling::tgroup">
|          <xsl:attribute name="border-bottom-width">0pt</xsl:attribute>
|          <xsl:attribute name="border-bottom-style">none</xsl:attribute>
|        </xsl:if>
|  
|        <xsl:if test="preceding-sibling::tgroup">
|          <xsl:attribute name="border-top-width">0pt</xsl:attribute>
|          <xsl:attribute name="border-top-style">none</xsl:attribute>
|        </xsl:if>
|  
|        <xsl:apply-templates select="."/>
|      </fo:table>
|    </xsl:for-each>
|  
|  I suspect that only *one* of those xsl:if's are needed, not 
|  both.  And
|  in fact, commenting out the first xsl:if gives me borders between my
|  tgroups.


It's probably not very common, but anyone who wants to style the
border-bottom of a not-last tgroup differently from the border-top of the
last tgroup needs both xsl:ifs.

Commenting out the first xsl:if makes tgroup no 1 use the border values
assigned in the table.frame template, including a border-bottom-style of
"solid" (and this value comes from the table.frame.border.style
attribute-set).

Instead of commenting out, you can change the first xsl:if to use (for
example)

  <xsl:attribute name="border-bottom-width">0.5pt</xsl:attribute>
  <xsl:attribute name="border-bottom-style">solid</xsl:attribute>

Mauritz
← Prev in month ← Prev in thread