| 套件 | mx.graphics |
| 類別 | public class GradientBase |
| 繼承 | GradientBase EventDispatcher Object |
| 子類別 | GradientStroke, LinearGradient, RadialGradient |
| 語言版本: | ActionScript 3.0 |
| 產品版本: | Flex 3 |
| 執行階段版本: | Flash Player 9, AIR 1.1 |
預設 MXML 屬性entries
| 屬性 | 定義自 | ||
|---|---|---|---|
| angle : Number 已不建議使用: 請使用 rotation
By default, the LinearGradientStroke defines a transition
from left to right across the control. | GradientBase | ||
![]() | constructor : Object
類別物件的參照或是特定物件實體的建構函數。 | Object | |
| entries : Array
An Array of GradientEntry objects
defining the fill patterns for the gradient fill. | GradientBase | ||
| interpolationMethod : String
A value from the InterpolationMethod class
that specifies which interpolation method to use. | GradientBase | ||
| matrix : Matrix
An array of values used for matrix transformation. | GradientBase | ||
| rotation : Number
By default, the LinearGradientStroke defines a transition
from left to right across the control. | GradientBase | ||
| spreadMethod : String
A value from the SpreadMethod class
that specifies which spread method to use. | GradientBase | ||
| x : Number
The distance by which to translate each point along the x axis. | GradientBase | ||
| y : Number
The distance by which to translate each point along the y axis. | GradientBase | ||
| 屬性 | 定義自 | ||
|---|---|---|---|
| compoundTransform : mx.geom:CompoundTransform
Holds the matrix and the convenience transform properties (x, y, and rotation). | GradientBase | ||
| 方法 | 定義自 | ||
|---|---|---|---|
Constructor. | GradientBase | ||
![]() | addEventListener(type:String, listener:Function, useCapture:Boolean = false, priority:int = 0, useWeakReference:Boolean = false):void
會在 EventDispatcher 物件註冊事件偵聽程式,以便讓偵聽程式收到事件的通知。 | EventDispatcher | |
![]() |
會將事件傳送到事件流程。 | EventDispatcher | |
![]() |
會檢查 EventDispatcher 物件是否有對特定的事件類型註冊偵聽程式。 | EventDispatcher | |
![]() |
指出物件是否有已定義的指定屬性。 | Object | |
![]() |
指出 Object 類別的實體是否位於指定為參數的物件原型鏈中。 | Object | |
![]() |
指出指定的屬性是否存在,以及是否可列舉。 | Object | |
![]() |
會從 EventDispatcher 物件移除偵聽程式。 | EventDispatcher | |
![]() |
為迴圈作業設定動態屬性的可用性。 | Object | |
![]() |
傳回代表此物件的字串,根據地區特定慣例進行格式化。 | Object | |
![]() |
會傳回指定之物件的字串形式。 | Object | |
![]() |
會傳回指定之物件的基本值。 | Object | |
![]() |
檢查此 EventDispatcher 物件是否已註冊事件偵聽程式,或者此物件的任何祖系已為特定事件類型註冊事件偵聽程式。 | EventDispatcher | |
| 常數 | 定義自 | ||
|---|---|---|---|
| GRADIENT_DIMENSION : Number = 1638.4 [靜態]
Value of the width and height of the untransformed gradient
| GradientBase | ||
angle | 屬性 |
angle:Number| 語言版本: | ActionScript 3.0 |
| 產品版本: | Flex 3 |
| 執行階段版本: | Flash Player 9, AIR 1.1 |
By default, the LinearGradientStroke defines a transition
from left to right across the control.
Use the angle property to control the transition direction.
For example, a value of 180.0 causes the transition
to occur from right to left, rather than from left to right.
預設值為 0.0。
實作
public function get angle():Number public function set angle(value:Number):voidcompoundTransform | 屬性 |
protected var compoundTransform:mx.geom:CompoundTransform| 語言版本: | ActionScript 3.0 |
| 產品版本: | Flex 3 |
| 執行階段版本: | Flash Player 9, AIR 1.1 |
Holds the matrix and the convenience transform properties (x, y, and rotation).
The compoundTransform is only created when the matrix property is set.
entries | 屬性 |
entries:Array| 語言版本: | ActionScript 3.0 |
| 產品版本: | Flex 3 |
| 執行階段版本: | Flash Player 9, AIR 1.1 |
An Array of GradientEntry objects defining the fill patterns for the gradient fill.
預設值為 []。
此屬性可以做為資料繫結的來源。一旦修改此屬性,將傳送 propertyChange 事件。
實作
public function get entries():Array public function set entries(value:Array):voidinterpolationMethod | 屬性 |
interpolationMethod:String| 語言版本: | ActionScript 3.0 |
| 產品版本: | Flex 3 |
| 執行階段版本: | Flash Player 9, AIR 1.1 |
A value from the InterpolationMethod class that specifies which interpolation method to use.
Valid values are InterpolationMethod.LINEAR_RGB
and InterpolationMethod.RGB.
預設值為 InterpolationMethod.RGB。
實作
public function get interpolationMethod():String public function set interpolationMethod(value:String):voidmatrix | 屬性 |
matrix:Matrix| 語言版本: | ActionScript 3.0 |
| 產品版本: | Flex 3 |
| 執行階段版本: | Flash Player 9, AIR 1.1 |
An array of values used for matrix transformation.
The gradient scaleX and scaleY properties represent pixels while the Matrix scale properties represent multipliers.
Thus they are not compatible.
Another difference is the most of the transform properties (x, y, scaleX, and scaleY)
support NaN values while the matrix does not. A NaN value means that the gradient will choose an appropriate value.
The scaleX and scaleY properties can not be represented by the matrix.
Once the matrix is set, scaleX and scaleY can no longer be set.
Also, x and y can not be set to NaN.
The matrix can be set back to null which also resets all of the convenience transform properties back to their default values.
If the matrix is set, then the gradient draw logic will scale the gradient to fit the bounds of the graphic element. It will then position the gradient in the upper left corner of the graphic element. Finally, it will apply the matrix transformations.
By default, the LinearGradientStroke defines a transition
from left to right across the control.
Use the rotation property to control the transition direction.
For example, a value of 180.0 causes the transition
to occur from right to left, rather than from left to right.
預設值為 null。
實作
public function get matrix():Matrix public function set matrix(value:Matrix):voidrotation | 屬性 |
rotation:Number| 語言版本: | ActionScript 3.0 |
| 產品版本: | Flex 3 |
| 執行階段版本: | Flash Player 9, AIR 1.1 |
By default, the LinearGradientStroke defines a transition
from left to right across the control.
Use the rotation property to control the transition direction.
For example, a value of 180.0 causes the transition
to occur from right to left, rather than from left to right.
預設值為 0.0。
此屬性可以做為資料繫結的來源。一旦修改此屬性,將傳送 propertyChange 事件。
實作
public function get rotation():Number public function set rotation(value:Number):voidspreadMethod | 屬性 |
spreadMethod:String| 語言版本: | ActionScript 3.0 |
| 產品版本: | Flex 3 |
| 執行階段版本: | Flash Player 9, AIR 1.1 |
A value from the SpreadMethod class that specifies which spread method to use.
Valid values are SpreadMethod.PAD,
SpreadMethod.REFLECT,
and SpreadMethod.REPEAT.
預設值為 SpreadMethod.PAD。
此屬性可以做為資料繫結的來源。一旦修改此屬性,將傳送 propertyChange 事件。
實作
public function get spreadMethod():String public function set spreadMethod(value:String):voidx | 屬性 |
y | 屬性 |
GradientBase | () | 建構函式 |
public function GradientBase()| 語言版本: | ActionScript 3.0 |
| 產品版本: | Flex 3 |
| 執行階段版本: | Flash Player 9, AIR 1.1 |
Constructor.
GRADIENT_DIMENSION | 常數 |
public static const GRADIENT_DIMENSION:Number = 1638.4| 語言版本: | ActionScript 3.0 |
| 產品版本: | Flex 4 |
| 執行階段版本: | Flash Player 10, AIR 1.5 |
Value of the width and height of the untransformed gradient
Tue Jun 12 2018, 03:47 PM Z
隱藏繼承公用屬性
顯示繼承公用屬性