public static Color web (String colorString)

Creates an RGB color specified with an HTML or CSS attribute string.

This method supports the following formats:

Examples:

Web Format String Equivalent constant or factory call
Color.web("orange"); Color.ORANGE
Color.web("0xff668840"); Color.rgb(255, 102, 136, 0.25)
Color.web("0xff6688"); Color.rgb(255, 102, 136, 1.0)
Color.web("#ff6688"); Color.rgb(255, 102, 136, 1.0)
Color.web("#f68"); Color.rgb(255, 102, 136, 1.0)
Color.web("rgb(255,102,136)"); Color.rgb(255, 102, 136, 1.0)
Color.web("rgb(100%,50%,50%)"); Color.rgb(255, 128, 128, 1.0)
Color.web("rgb(255,50%,50%,0.25)"); Color.rgb(255, 128, 128, 0.25)
Color.web("hsl(240,100%,100%)"); Color.hsb(240.0, 1.0, 1.0, 1.0)
Color.web("hsla(120,0%,0%,0.25)"); Color.hsb(120.0, 0.0, 0.0, 0.25)

Parameters:
colorString    the name or numeric representation of the color in one of the supported formats

Exceptions:
NullPointerException    if colorString is null
IllegalArgumentException    if colorString specifies an unsupported color name or contains an illegal numeric value