Packagecom.adobe.csxs.types
Classpublic class GradientColor

Stores gradient color information.



Public Properties
 PropertyDefined by
  direction : Point
Retrieves a vector that describes the direction of the gradient.
GradientColor
  gradientStopList : Array
Retrieves the stops that define the gradient.
GradientColor
  type : String
Retrieves the type of gradient.
GradientColor
Public Methods
 MethodDefined by
  
GradientColor(type:String = "linear", direction:Point = null, gradientStopList:Array = null)
Creates a gradient color object.
GradientColor
  
toString():String
Creates a string that contains all the properties of this object.
GradientColor
Property detail
directionproperty
direction:Point  [read-write]

Retrieves a vector that describes the direction of the gradient. Only the direction of the vector is considered, magnitude is not. For maximum forward compatibility, use a unit vector (such as length == 1.0). Four directions are supported: left or right (x != 0, y = 0), and up or down (x = 0, y != 0).

Implementation
    public function get direction():Point
    public function set direction(value:Point):void
gradientStopListproperty 
gradientStopList:Array  [read-write]

Retrieves the stops that define the gradient.

Implementation
    public function get gradientStopList():Array
    public function set gradientStopList(value:Array):void
typeproperty 
type:String  [read-write]

Retrieves the type of gradient.

Implementation
    public function get type():String
    public function set type(value:String):void
Constructor detail
GradientColor()constructor
public function GradientColor(type:String = "linear", direction:Point = null, gradientStopList:Array = null)

Creates a gradient color object.

Parameters
type:String (default = "linear") — Optional. The gradient type, a flash.display.GradientType constant. The only valid value is "linear".
 
direction:Point (default = null) — A vector describing the direction of the gradient. A point value, in which the y component is 0 and the x component is positive or negative for a right or left direction, or the x component is 0 and the y component is positive or negative for an up or down direction.
 
gradientStopList:Array (default = null) — Optional. An array of gradient-stop objects.
Method detail
toString()method
public function toString():String

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

Returns
String — The properties string.