OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

docbook-apps message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]


Subject: Re: [docbook-apps] Table 'thead' cell Color


I assume you mean FO output, not HTML output.
 
For FO output, you can put the properties you want in the fo:table-header object by modifying the match="thead" template.  You can use xsl:attribute to add two properties:
 
<xsl:template match="thead">
  <xsl:variable name="tgroup" select="parent::*"/>
 
  <fo:table-header>
    <!-- ADD THESE TWO PROPERTIES -->
    <xsl:attribute name="background-color">#E0E0E0</xsl:attribute>
    <xsl:attribute name="font-weight">bold</xsl:attribute>
    <xsl:apply-templates select="row[1]">
      <xsl:with-param name="spans">
        <xsl:call-template name="blank.spans">
          <xsl:with-param name="cols" select="../@cols"/>
        </xsl:call-template>
      </xsl:with-param>
    </xsl:apply-templates>
  </fo:table-header>
</xsl:template>
Those properties will be inherited by all the cells in the thead.
 
Bob Stayton
Sagehill Enterprises
DocBook Consulting
bobs@sagehill.net
 
 
----- Original Message -----
Sent: Wednesday, March 24, 2004 12:11 AM
Subject: [docbook-apps] Table 'thead' cell Color

Good morning All,
 
I have been using DocBook to create a report generation system and thanks to all the help I have recieved on this site I have go there a lot quicker than I would have done on my own.
 
I have one last thing (before the next phase anyway) that I would like some help on.
 
I have created a customisation layer that outputs the reports in our company standard format and I would like to be able to specify how the table heading cells are formatted.  I do not want to have to hard code it into the application as I believe this should be done in the stylesheet.
 
However although I can match the template for thead in the customistation layer I cannot work out how to change the cell color and the font weight (and color).
 
If anyone has any ideas that would be great.
 
Thanks lots,

Russell


[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]