Method Parse

Namespace TallComponents.PDF.Colors
Class Color

Parse a string to extract a color.

The string representation of a color can be on of the following:

FormatDescription#RRGGBB Web color. Each component is a 2-digit hexadecimal number (00 - FF). For example: #9963FAgray Gray color. gray is a value in the range 0 - 255. For example: 128r,g,b RGB color. Each component is a value in the range 0 - 255. For example: 128,5,233c,m,y,k CMYK color. Each component is a value in the range 0 - 255. For example: 12,255,6,128ColorName A named color. Currently supported are all named colors available in System.Drawing.Color. For example: SkyBlue

In addition to fixed values (0-255), a relative percentage value (0%-100%) is also allowed. This is converted to 0-255.

Syntax

public  Color  Parse( String  color )

Returns

Color

A Color.

Parameters


String color
A string describing a color.