Single value for a CSS style.
Platform Support
IE | Mozilla | Netscape | Opera | Safari | no | 1.0+ | no | 9.0+ | 1.0+ |
---|
Constructors
Constructor | Action | IE | Mozilla | Netscape | Opera | Safari | ||
---|---|---|---|---|---|---|---|---|
CSSPrimitiveValue Constructor() : CSSPrimitiveValue
Single value for a CSS style.
|
Show Details | no | 1.0+ | no | 9.0+ | 1.0+ | ||
CSSPrimitiveValue() : CSSPrimitiveValueSingle value for a CSS style. Returns
|
Inherited Properties
Property | Action | IE | Mozilla | Netscape | Opera | Safari |
---|---|---|---|---|---|---|
cssText
: String
Text representing the CSS value.
|
Show Details | no | 1.0+ | no | no | no |
|
||||||
cssValueType
: Number
Type of CSS value represented by the object. See remarks for possible values.
|
Show Details | no | 1.0+ | no | no | no |
|
Properties
Property | Action | IE | Mozilla | Netscape | Opera | Safari |
---|---|---|---|---|---|---|
primitiveType
: Number
Holds the value of a constant. See Remarks for possible values.
|
Show Details | no | 1.0+ | no | 9.0+ | 1.0+ |
|
Functions
Method | Action | IE | Mozilla | Netscape | Opera | Safari | ||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
static getCounterValue() : Counter
Returns the counter object that represents the value of a CSS counter.
|
Show Details | no | 1.0+ | no | no | no | ||||||||
Returns
|
||||||||||||||
getFloatValue(Number unitType) : Number
The value of a number, converted to the appropriate units, if applicable.
|
Show Details | no | 1.0+ | no | no | no | ||||||||
Parameters
Returns
|
||||||||||||||
static getRectValue() : Rect
Returns a Rect object representing the value of a CSS_RECT.
|
Show Details | no | 1.0+ | no | no | no | ||||||||
Returns
|
||||||||||||||
static getRGBColorValue() : RGBColor
Returns a RGBColor object representing the value of a CSS_RGBCOLOR.
|
Show Details | no | 1.0+ | no | no | no | ||||||||
Returns
|
||||||||||||||
static getStringValue() : String
Returns the value of a string.
|
Show Details | no | 1.0+ | no | no | no | ||||||||
Returns
|
||||||||||||||
setFloatValue(Number unitType, Number floatValue) : void
Sets the value of a number to the specified value for the specified units.
|
Show Details | no | 1.0+ | no | no | no | ||||||||
Parameters
Returns
|
||||||||||||||
setStringValue(Number stringType, String stringValue) : void
Sets a string to the specified value and type.
|
Show Details | no | 1.0+ | no | no | no | ||||||||
Parameters
Returns
|
References
Counter|CSSValue|CSSValueList|Rect|RGBColor
Availability
HTML DOM Level 2|W3C