<?xml version='1.0' encoding='ISO-8859-1'?>

<!-- This file makes part of an XSL Test Suite -->
<!-- Basic formatting test: colors             -->

<plain-doc column-count="2" xmlns:fo="http://www.w3.org/1999/XSL/Format">


  <rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
           xmlns:dcterms="http://purl.org/dc/terms/"
           xmlns:dc="http://purl.org/dc/elements/1.1/"
           xmlns:db="http://www.oasis-open.org/docbook/xml/4.2/">
     <rdf:Description rdf:about="http://xep.xattic.com/testsuite/features/color.xml">
        <dc:title> Basic Formatting Attributes - Color </dc:title>
        <dc:description>
          <db:para>
            Tests RGB color treatment and predefined color keywords
            in various contexts - text, background, and borders.
          </db:para>
        </dc:description>
        <dc:date>2003-07-24</dc:date><dcterms:requires rdf:resource="http://xep.xattic.com/testsuite/features/macro.xsl"/>
    </rdf:Description>
  </rdf:RDF> 

<define-macro name="color-item">
  <fo:list-item>
    <fo:list-item-label end-indent="label-end()">
      <p text-align="center" 
         border="1pt solid white" 
         background-color="$arg"
         padding="3pt" margin-left="0pt" margin-right="0pt"
         color="black"><arg/></p>
    </fo:list-item-label>
    <fo:list-item-body start-indent="body-start()">
      <p text-align="center" 
         border="1pt solid {$arg}" 
         padding="3pt" margin-left="0pt" margin-right="0pt"
         color="$arg"><arg/></p>
    </fo:list-item-body>
  </fo:list-item>
</define-macro>

<define-macro name="two-color-items">
  <ul provisional-distance-between-starts="1.2in"
      provisional-label-separation="18pt"
      padding="2pt"
      border="1pt solid silver"
      keep-together.within-column="always">
    <macro name="color-item" arg="$arg1"/>
    <macro name="color-item" arg="$arg2"/>
  </ul>
</define-macro>


<!--  ======================================================  -->
<!--  Document Body                                           -->

<title>   Basic Formatting Attributes - Color </title>
<text>
  This document aims at testing color treatment in the XSL.
  It tests both numeric RGB colors and predefined system
  colors in various formatting objects - text, background,
  and borders.
</text>


<h2>Numeric RGB Values</h2>
<text>
  We have chosen some arbitrary values for testing. Worth noting
  are tests for case-insensitivity of hex digits.
</text>

<macro name="two-color-items" arg1="#FF0000"
                              arg2="#ff0000"/>

<macro name="two-color-items" arg1="#FFFF00"
                              arg2="#ffff00"/>

<macro name="two-color-items" arg1="#0000FF"
                              arg2="#0000ff"/>

<macro name="two-color-items" arg1="#00FF00"
                              arg2="#00ff00"/>

<macro name="two-color-items" arg1="#A0D0FF"
                              arg2="#a0d0ff"/>

<macro name="two-color-items" arg1="#FdDbAc"
                              arg2="#fDdBaC"/>

<h2>Predefined System Colors</h2>
<text>
  Font colors in XSL are borrowed from CSS, which in turn
  refers to HTML 4.0 color specification. There are 16 predefined
  system colors. Note that, unlike HTML color names, XSL ones
  are case sensitive.
</text>

<macro name="two-color-items" arg1="#000000"
                               arg2="black"/>

<macro name="two-color-items" arg1="#808080"
                               arg2="gray"/>

<macro name="two-color-items" arg1="#C0C0C0"
                               arg2="silver"/>

<macro name="two-color-items" arg1="#FFFFFF"
                               arg2="white"/>

<macro name="two-color-items" arg1="#800000"
                               arg2="maroon"/>

<macro name="two-color-items" arg1="#FF0000"
                               arg2="red"/>

<macro name="two-color-items" arg1="#800080"
                               arg2="purple"/>

<macro name="two-color-items" arg1="#FF00FF"
                               arg2="fuchsia"/>

<macro name="two-color-items" arg1="#008000"
                               arg2="green"/>

<macro name="two-color-items" arg1="#00FF00"
                               arg2="lime"/>

<macro name="two-color-items" arg1="#808000"
                               arg2="olive"/>

<macro name="two-color-items" arg1="#FFFF00"
                               arg2="yellow"/>

<macro name="two-color-items" arg1="#000080"
                               arg2="navy"/>

<macro name="two-color-items" arg1="#0000FF"
                               arg2="blue"/>

<macro name="two-color-items" arg1="#008080"
                               arg2="teal"/>

<macro name="two-color-items" arg1="#00FFFF"
                               arg2="aqua"/>

</plain-doc>

