| The ColorParser class parses CSS 2 color values as
defined in the SVG specification for SVG Tiny:
color: hex3Color | hex6Color | rgbColor | predefinedColor
hex3Color: '#' hexDigit hexDigit hexDigit
hexDigit: 0|1|2|3|4|5|6|7|8|9|A|a|B|b|C|c|D|d|E|e|F|f
hex6Color: '#' hexDigit hexDigit hexDigi hexDigit hexDigit hexDigit
rgbColor: rgbColorInt | rgbColorPercent
rgbColorInt: rgbPrefix wsp* colInt wsp* comma wsp* colInt wsp*
comma wsp* colInt wsp* rgbSuffix
rgbPrefix: 'rgb('
wsp: ' '
comma: ','
colInt: int[0-255]
rgbColorPercent: rgbPrefix wsp* colPct wsp* comma wsp* colPct wsp*
comma wsp* colPct wsp* rgbSuffix
colPct: pctInt '%'
pctInt: int[0-100]
predefinedColor: 'black' | 'silver' | 'gray' | 'white' | 'maroon' | 'red'
| 'purple' | 'fuchia' | 'green' | 'lime' | 'olive'
| 'yellow' | 'navy' | 'blue' | 'teal' | 'aqua'
The above captures the verbal description of the CSS 2 specification
for CSS 2
Color Values.
version: $Id: ColorParser.java,v 1.2 2006/04/21 06:40:26 st125089 Exp $ |