| Pacchetto | mx.graphics |
| Classe | public class RectangularDropShadow |
| Ereditarietà | RectangularDropShadow Object |
| Versione linguaggio: | ActionScript 3.0 |
| Versione prodotto: | Flex 3 |
| Versioni runtime: | Flash Player 9, AIR 1.1 |
This class optimizes drop shadows for a common case. If you are applying a drop shadow to a rectangularly-shaped object whose edges fall on pixel boundaries, then this class should be used instead of using the DropShadowFilter directly.
This class accepts the first four parameters that are passed
to DropShadowFilter: alpha, angle,
color, and distance.
In addition, this class accepts the corner radii for each of the four
corners of the rectangularly-shaped object that is casting a shadow.
Once those 8 values have been set,
this class pre-computes the drop shadow in an offscreen Bitmap.
When the drawShadow() method is called, pieces of the
precomputed drop shadow are copied onto the passed-in Graphics object.
Elementi API correlati
| Proprietà | Definito da | ||
|---|---|---|---|
| alpha : Number
Il valore di trasparenza alfa del colore d'ombra. | RectangularDropShadow | ||
| angle : Number
L'angolo dell'ombra. | RectangularDropShadow | ||
| blRadius : Number
The corner radius of the bottom left corner
of the rounded rectangle that is casting the shadow. | RectangularDropShadow | ||
| blurX : Number
The amount of horizontal blur. | RectangularDropShadow | ||
| blurY : Number
The amount of vertical blur. | RectangularDropShadow | ||
| brRadius : Number
The corner radius of the bottom right corner
of the rounded rectangle that is casting the shadow. | RectangularDropShadow | ||
| color : int
Il colore dell'ombra. | RectangularDropShadow | ||
![]() | constructor : Object
Un riferimento all'oggetto classe o alla funzione di costruzione per una determinata istanza di oggetto. | Object | |
| distance : Number
La distanza di offset dell'ombra, in pixel. | RectangularDropShadow | ||
| tlRadius : Number
The corner radius of the top left corner
of the rounded rectangle that is casting the shadow. | RectangularDropShadow | ||
| trRadius : Number
The corner radius of the top right corner
of the rounded rectangle that is casting the shadow. | RectangularDropShadow | ||
| Metodo | Definito da | ||
|---|---|---|---|
Constructor. | RectangularDropShadow | ||
Renders the shadow on the screen. | RectangularDropShadow | ||
![]() |
Indica se per un oggetto è definita una proprietà specifica. | Object | |
![]() |
Indica se un'istanza della classe Object si trova nella catena di prototipi dell'oggetto specificato come parametro. | Object | |
![]() |
Indica se la proprietà specificata esiste ed è enumerabile. | Object | |
![]() |
Imposta la disponibilità di una proprietà dinamica per le operazioni cicliche. | Object | |
![]() |
Restituisce la rappresentazione in formato stringa di questo oggetto, formattato in base alle convenzioni specifiche per le versioni localizzate. | Object | |
![]() |
Restituisce la rappresentazione in formato stringa dell'oggetto specificato. | Object | |
![]() |
Restituisce il valore di base dell'oggetto specificato. | Object | |
alpha | proprietà |
alpha:Number| Versione linguaggio: | ActionScript 3.0 |
| Versione prodotto: | Flex 3 |
| Versioni runtime: | Flash Player 9, AIR 1.1 |
Il valore di trasparenza alfa del colore d'ombra. I valori validi sono compresi tra 0,0 e 1,0. Ad esempio, 0.25 imposta un valore di trasparenza del 25%. Il valore predefinito è 1,0.
Implementazione
public function get alpha():Number public function set alpha(value:Number):voidangle | proprietà |
angle:Number| Versione linguaggio: | ActionScript 3.0 |
| Versione prodotto: | Flex 3 |
| Versioni runtime: | Flash Player 9, AIR 1.1 |
L'angolo dell'ombra. I valori validi sono compresi tra 0 e 360 gradi (virgola mobile). Il valore predefinito è 45.
Implementazione
public function get angle():Number public function set angle(value:Number):voidblRadius | proprietà |
blRadius:Number| Versione linguaggio: | ActionScript 3.0 |
| Versione prodotto: | Flex 3 |
| Versioni runtime: | Flash Player 9, AIR 1.1 |
The corner radius of the bottom left corner of the rounded rectangle that is casting the shadow. May be zero for non-rounded rectangles.
Implementazione
public function get blRadius():Number public function set blRadius(value:Number):voidblurX | proprietà |
blurY | proprietà |
brRadius | proprietà |
brRadius:Number| Versione linguaggio: | ActionScript 3.0 |
| Versione prodotto: | Flex 3 |
| Versioni runtime: | Flash Player 9, AIR 1.1 |
The corner radius of the bottom right corner of the rounded rectangle that is casting the shadow. May be zero for non-rounded rectangles.
Implementazione
public function get brRadius():Number public function set brRadius(value:Number):voidcolor | proprietà |
color:int| Versione linguaggio: | ActionScript 3.0 |
| Versione prodotto: | Flex 3 |
| Versioni runtime: | Flash Player 9, AIR 1.1 |
Il colore dell'ombra. I valori validi sono espressi nel formato esadecimale 0xRRGGBB. Il valore predefinito è 0x000000.
Implementazione
public function get color():int public function set color(value:int):voiddistance | proprietà |
distance:Number| Versione linguaggio: | ActionScript 3.0 |
| Versione prodotto: | Flex 3 |
| Versioni runtime: | Flash Player 9, AIR 1.1 |
La distanza di offset dell'ombra, in pixel. Il valore predefinito è 4,0 (virgola mobile).
Implementazione
public function get distance():Number public function set distance(value:Number):voidtlRadius | proprietà |
tlRadius:Number| Versione linguaggio: | ActionScript 3.0 |
| Versione prodotto: | Flex 3 |
| Versioni runtime: | Flash Player 9, AIR 1.1 |
The corner radius of the top left corner of the rounded rectangle that is casting the shadow. May be zero for non-rounded rectangles.
Implementazione
public function get tlRadius():Number public function set tlRadius(value:Number):voidtrRadius | proprietà |
trRadius:Number| Versione linguaggio: | ActionScript 3.0 |
| Versione prodotto: | Flex 3 |
| Versioni runtime: | Flash Player 9, AIR 1.1 |
The corner radius of the top right corner of the rounded rectangle that is casting the shadow. May be zero for non-rounded rectangles.
Implementazione
public function get trRadius():Number public function set trRadius(value:Number):voidRectangularDropShadow | () | Funzione di costruzione |
public function RectangularDropShadow()| Versione linguaggio: | ActionScript 3.0 |
| Versione prodotto: | Flex 3 |
| Versioni runtime: | Flash Player 9, AIR 1.1 |
Constructor.
drawShadow | () | metodo |
public function drawShadow(g:Graphics, x:Number, y:Number, width:Number, height:Number):void| Versione linguaggio: | ActionScript 3.0 |
| Versione prodotto: | Flex 3 |
| Versioni runtime: | Flash Player 9, AIR 1.1 |
Renders the shadow on the screen.
Parametri
g:Graphics — The Graphics object on which to draw the shadow.
| |
x:Number — The horizontal offset of the drop shadow,
based on the Graphics object's position.
| |
y:Number — The vertical offset of the drop shadow,
based on the Graphics object's position.
| |
width:Number — The width of the shadow, in pixels.
| |
height:Number — The height of the shadow, in pixels.
|
Tue Jun 12 2018, 02:44 PM Z
Nascondi proprietà pubbliche ereditate
Mostra proprietà pubbliche ereditate