Packagecom.adobe.csxs.types
Classpublic class RGBColor

Stores an RGB color with red, green, blue, and alpha values. All values are in the range [0.0 to 255.0]. Invalid numeric values are converted to numbers within this range.



Public Properties
 PropertyDefined by
  alpha : Number
Retrieves the alpha (transparency) value.
RGBColor
  blue : Number
Retrieves the blue value.
RGBColor
  green : Number
Retrieves the green value.
RGBColor
  red : Number
Retrieves the red value.
RGBColor
  rgb : uint
[read-only] Retrieves the color value in hexadecimal format.
RGBColor
Public Methods
 MethodDefined by
  
RGBColor(red:Number = 0.0, green:Number = 0.0, blue:Number = 0.0, alpha:Number = 255.0)
Creates an RGB color object.
RGBColor
  
toString():String
Creates a string that contains all the properties of this object.
RGBColor
Property detail
alphaproperty
alpha:Number  [read-write]

Retrieves the alpha (transparency) value. A value of 0.0 means that the color is fully transparent (not visible), and a value of 255.0 means that the color is fully opaque.

Implementation
    public function get alpha():Number
    public function set alpha(value:Number):void
blueproperty 
blue:Number  [read-write]

Retrieves the blue value.

Implementation
    public function get blue():Number
    public function set blue(value:Number):void
greenproperty 
green:Number  [read-write]

Retrieves the green value.

Implementation
    public function get green():Number
    public function set green(value:Number):void
redproperty 
red:Number  [read-write]

Retrieves the red value.

Implementation
    public function get red():Number
    public function set red(value:Number):void
rgbproperty 
rgb:uint  [read-only]

Retrieves the color value in hexadecimal format.

Implementation
    public function get rgb():uint
Constructor detail
RGBColor()constructor
public function RGBColor(red:Number = 0.0, green:Number = 0.0, blue:Number = 0.0, alpha:Number = 255.0)

Creates an RGB color object.

Parameters
red:Number (default = 0.0) — The red value, in the range [0.0 to 255.0].
 
green:Number (default = 0.0) — The green value, in the range [0.0 to 255.0].
 
blue:Number (default = 0.0) — blue value, in the range [0.0 to 255.0].
 
alpha:Number (default = 255.0) — The alpha (transparency) value, in the range [0.0 to 255.0]. The default (255.0) means that the color is fully opaque.
Method detail
toString()method
public function toString():String

Creates a string that contains all the properties of this object.

Returns
String — The properties string.