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


Help: OASIS Mailing Lists Help | MarkMail Help

docbook message

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

Subject: background colour and font of the table.


Problem 1:
I wanted alternate rows of my table to be differently colored.
So, i added a template to my customization layer i found at 
<xsl:template name="table.row.properties">

  <xsl:variable name="tabstyle">
    <xsl:call-template name="tabstyle"/>

  <xsl:variable name="bgcolor">
    <xsl:call-template name="dbfo-attribute">
      <xsl:with-param name="pis" select="processing-instruction('dbfo')"/>
      <xsl:with-param name="attribute" select="'bgcolor'"/>
  <xsl:variable name="rownum">
    <xsl:number from="tgroup" count="row"/>

    <xsl:when test="$bgcolor != ''">
      <xsl:attribute name="background-color">
        <xsl:value-of select="$bgcolor"/>
    <xsl:when test="$tabstyle = 'striped'">
      <xsl:if test="$rownum mod 2 = 0">
        <xsl:attribute name="background-color">#EEEEEE</xsl:attribute>
After this i set the tabstyle attribute of the table to "striped".
But nothing happened. What am i doing wrong? Also What colour does #EEEEEE represent?
Problem 2:
In the table suppose in cell there is a lot of text with long words, then alignment of text gets disturbed. I can see lot of spaces between two small words to accommodate the big word from next line like
| abd     ads         sbd |
| AnmolGupta ads as  |
It should have been like
| abd ads sbd             |
| AnmolGupta ads as  |
How can i do this?

Thanks and Regards,

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