com.lowagie.text.html

Class WebColors

public class WebColors extends HashMap

This class is a HashMap that contains the names of colors as a key and the corresponding Color as value. (Source: Wikipedia http://en.wikipedia.org/wiki/Web_colors )

Author: blowagie

Field Summary
static WebColorsNAMES
HashMap containing all the names and corresponding color values.
static longserialVersionUID
Method Summary
static ColorgetRGBColor(String name)
Gives you a Color based on a name.

Field Detail

NAMES

public static final WebColors NAMES
HashMap containing all the names and corresponding color values.

serialVersionUID

private static final long serialVersionUID

Method Detail

getRGBColor

public static Color getRGBColor(String name)
Gives you a Color based on a name.

Parameters: name a name such as black, violet, cornflowerblue or #RGB or #RRGGBB or rgb(R,G,B)

Returns: the corresponding Color object

Throws: IllegalArgumentException if the String isn't a know representation of a color.