YUI recommends YUI 3.

YUI 2 has been deprecated since 2011. This site acts as an archive for files and documentation.

Yahoo! UI Library

dom  2.8.2r1

Yahoo! UI Library > dom > YAHOO.util.Dom.Color
Search:
 
Filters

Class YAHOO.util.Dom.Color

Add style management functionality to DOM.

Properties

KEYWORDS - Object

Color keywords used when converting to Hex

re_hex - private Regex

Regex to parse #123456 formatted strings

re_hex3 - private Regex

Regex to parse #123 formatted strings

re_RGB - private Regex

Regex to parse rgb(0,0,0) formatted strings

Methods

toHex

void toHex ( val )
Converts an rgb or color string to a hex string: #123456
Parameters:
val <String> The string to convert to hex notation.

toRGB

void toRGB ( val )
Converts a hex or color string to an rgb string: rgb(0,0,0)
Parameters:
val <String> The string to convert to RGB notation.


Copyright © 2010 Yahoo! Inc. All rights reserved.