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] Different attribute-sets for note, caution, info, etc.


Joel,
 
Yes, here is my layer that I use.
 
    <!-- Admonitions -->
 
    <xsl:param name="admon.graphics" select="'1'"/>
    <xsl:param name="admon.textlabel" select="'1'"/>
    <xsl:param name="admon.graphics.extension" select="'.svg'"/>
    <xsl:param name="admon.graphics.path" select="'http://docbook.sourceforge.net/release/xsl/current/images/'"/>
 
    <!--  Normal -->
    <xsl:attribute-set name="admonition.properties">
        <xsl:attribute name="background-color">
            <xsl:choose>
                <xsl:when test="ancestor-or-self::tip"      >#FFFFFF</xsl:when>
                <xsl:when test="ancestor-or-self::note"     >#FFFFFF</xsl:when>
                <xsl:when test="ancestor-or-self::important">#B5FFB5</xsl:when>
                <xsl:when test="ancestor-or-self::caution"  >#FAFA8C</xsl:when>
                <xsl:when test="ancestor-or-self::warning"  >#FFADAD</xsl:when>
                <xsl:otherwise>#000000</xsl:otherwise>
            </xsl:choose>
        </xsl:attribute>
        <xsl:attribute name="keep-together.within-column">always</xsl:attribute>
        <xsl:attribute name="padding">5pt</xsl:attribute>
        <xsl:attribute name="padding-top">-1pt</xsl:attribute>
        <xsl:attribute name="border">1pt solid blue</xsl:attribute>
     </xsl:attribute-set>
 
    <xsl:attribute-set name="admonition.title.properties">
        <xsl:attribute name="keep-together.within-column">always</xsl:attribute>
        <xsl:attribute name="background-color">#E0E0E0</xsl:attribute>
        <xsl:attribute name="text-align">left</xsl:attribute>
        <xsl:attribute name="padding">5pt</xsl:attribute>
          <!-- <xsl:attribute name="border">1pt solid blue</xsl:attribute> removed to avoid double line -->
        <xsl:attribute name="border-top">1pt solid blue</xsl:attribute>
        <xsl:attribute name="border-left">1pt solid blue</xsl:attribute>
        <xsl:attribute name="border-right">1pt solid blue</xsl:attribute>
    </xsl:attribute-set>
  
 
Regards,
Dean Nelson
 
In a message dated 11/2/2011 1:12:54 P.M. Pacific Daylight Time, joel.j.k.parker@nasa.gov writes:
Is there an easy canned way to get different attribute-sets for the different admonitions (note, caution, info, ...)?

Specifically, I want each to have a shaded box, and I'd like to alter the color based on the "severity" of the admonition.

Thanks,

--
Joel J. K. Parker


---------------------------------------------------------------------
To unsubscribe, e-mail: docbook-apps-unsubscribe@lists.oasis-open.org
For additional commands, e-mail: docbook-apps-help@lists.oasis-open.org


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