| Pakket | mx.graphics |
| Klasse | public class RectangularDropShadow |
| Overerving | RectangularDropShadow Object |
| Taalversie: | ActionScript 3.0 |
| Productversie: | Flex 3 |
| Runtimeversies: | 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.
Verwante API-elementen
| Eigenschap | Gedefinieerd door | ||
|---|---|---|---|
| alpha : Number
De alpha-transparantiewaarde voor de schaduwkleur. | RectangularDropShadow | ||
| angle : Number
De hoek van de schaduw. | 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
De kleur van de schaduw. | RectangularDropShadow | ||
![]() | constructor : Object
Verwijzing naar het klasseobject of de constructorfunctie van een bepaalde objectinstantie. | Object | |
| distance : Number
De verschuivingsafstand voor de schaduw, in pixels. | 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 | ||
| Methode | Gedefinieerd door | ||
|---|---|---|---|
Constructor. | RectangularDropShadow | ||
Renders the shadow on the screen. | RectangularDropShadow | ||
![]() |
Geeft aan of voor een object een opgegeven eigenschap is gedefinieerd. | Object | |
![]() |
Geeft aan of een instantie van de klasse Object zich in de prototypeketen van het object bevindt dat als parameter is opgegeven. | Object | |
![]() |
Geeft aan of de opgegeven eigenschap bestaat en kan worden opgesomd. | Object | |
![]() |
Stelt de beschikbaarheid van een dynamische eigenschap voor lusbewerkingen in. | Object | |
![]() |
Geeft de tekenreeksweergave van dit object weer, geformatteerd volgens de locatiespecifieke conventies. | Object | |
![]() |
Retourneert een tekenreeksrepresentatie van het opgegeven object. | Object | |
![]() |
Retourneert de primitieve waarde van het opgegeven object. | Object | |
alpha | eigenschap |
alpha:Number| Taalversie: | ActionScript 3.0 |
| Productversie: | Flex 3 |
| Runtimeversies: | Flash Player 9, AIR 1.1 |
De alpha-transparantiewaarde voor de schaduwkleur. Geldige waarden zijn 0.0 tot en met 1.0. De waarde .25 stelt bijvoorbeeld een transparantiewaarde in van 25%. De standaardwaarde is 1.0.
Implementatie
public function get alpha():Number public function set alpha(value:Number):voidangle | eigenschap |
angle:Number| Taalversie: | ActionScript 3.0 |
| Productversie: | Flex 3 |
| Runtimeversies: | Flash Player 9, AIR 1.1 |
De hoek van de schaduw. Geldige waarden zijn 0 tot en met 360 (drijvende komma). De standaardwaarde is 45.
Implementatie
public function get angle():Number public function set angle(value:Number):voidblRadius | eigenschap |
blRadius:Number| Taalversie: | ActionScript 3.0 |
| Productversie: | Flex 3 |
| Runtimeversies: | 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.
Implementatie
public function get blRadius():Number public function set blRadius(value:Number):voidblurX | eigenschap |
blurY | eigenschap |
brRadius | eigenschap |
brRadius:Number| Taalversie: | ActionScript 3.0 |
| Productversie: | Flex 3 |
| Runtimeversies: | 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.
Implementatie
public function get brRadius():Number public function set brRadius(value:Number):voidcolor | eigenschap |
distance | eigenschap |
distance:Number| Taalversie: | ActionScript 3.0 |
| Productversie: | Flex 3 |
| Runtimeversies: | Flash Player 9, AIR 1.1 |
De verschuivingsafstand voor de schaduw, in pixels. De standaardwaarde is 4,0 (drijvende komma).
Implementatie
public function get distance():Number public function set distance(value:Number):voidtlRadius | eigenschap |
tlRadius:Number| Taalversie: | ActionScript 3.0 |
| Productversie: | Flex 3 |
| Runtimeversies: | 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.
Implementatie
public function get tlRadius():Number public function set tlRadius(value:Number):voidtrRadius | eigenschap |
trRadius:Number| Taalversie: | ActionScript 3.0 |
| Productversie: | Flex 3 |
| Runtimeversies: | 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.
Implementatie
public function get trRadius():Number public function set trRadius(value:Number):voidRectangularDropShadow | () | Constructor |
public function RectangularDropShadow()| Taalversie: | ActionScript 3.0 |
| Productversie: | Flex 3 |
| Runtimeversies: | Flash Player 9, AIR 1.1 |
Constructor.
drawShadow | () | methode |
public function drawShadow(g:Graphics, x:Number, y:Number, width:Number, height:Number):void| Taalversie: | ActionScript 3.0 |
| Productversie: | Flex 3 |
| Runtimeversies: | Flash Player 9, AIR 1.1 |
Renders the shadow on the screen.
Parameters
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.
|
Wed Jun 13 2018, 11:42 AM Z
Overerfde openbare eigenschappen verbergen
Overerfde openbare eigenschappen weergeven