Packagegraphics.drawing
Classpublic class AntPen
InheritanceAntPen Inheritance Pen Inheritance flash.utils.Proxy
Implements Runnable, Startable, Stoppable

This pen display a marching ants path.



Public Properties
 PropertyDefined By
 Inheritedalign : uint
Determinates the align value of the pen.
Pen
  closePath : Boolean
Indicates if the pen close the path when it draw the shape.
AntPen
 Inheritedfill : IFillStyle
Determinates the fill style object of the pen.
Pen
 Inheritedgraphics : *
Specifies the Graphics object belonging to this Shape object, where vector drawing commands can occur.
Pen
 Inheritedline : ILineStyle
Determinates the line style object of the pen.
Pen
  points : Array
The representation of all points of the path to drawing.
AntPen
  running : Boolean
[read-only] Indicates if the ant effect is in progress.
AntPen
  speed : Number
Indicates the speed of the effect.
AntPen
  steps : uint
The steps value of the pen.
AntPen
 InheriteduseClear : Boolean = true
Indicates if the clear() method is invoked at the end of the draw method.
Pen
 InheriteduseEndFill : Boolean = true
Indicates if the endFill() method is invoked at the end of the draw method.
Pen
Public Methods
 MethodDefined By
  
AntPen(graphics:* = null, colors:Array = null, pattern:Array = null, speed:Number = 32, steps:uint = 1, closePath:Boolean = true)
Creates a new AntPen instance.
AntPen
 Inherited
BF(... arguments):void
Defines a shortcut reference to used the beginBitmapFill method.
Pen
 Inherited
C(... arguments):void
Defines a shortcut reference to used the curveTo method.
Pen
 Inherited
CL():void
Defines a shortcut reference to used the clear method.
Pen
  
draw(... args):void
[override] Draws the shape and scale it.
AntPen
  
drawShape():void
[override] This method contains the basic drawing shape algorithm.
AntPen
 Inherited
EF():void
Defines a shortcut reference to used the endFill method.
Pen
 Inherited
F(... arguments):void
Defines a shortcut reference to used the beginFill method.
Pen
 Inherited
GF(... arguments):void
Defines a shortcut reference to used the beginGradientFill method.
Pen
 Inherited
GS(... arguments):void
Defines a shortcut reference to used the lineGradientStyle method.
Pen
 Inherited
L(... arguments):void
Defines a shortcut reference to used the lineTo method.
Pen
 Inherited
M(... arguments):void
Defines a shortcut reference to used the moveTo method.
Pen
  
run(... arguments):void
Run the process.
AntPen
 Inherited
S(... arguments):void
Defines a shortcut reference to used the lineStyle method.
Pen
  
setup(colors:Array = null, pattern:Array = null):void
Sets the pen with the specified colors and the specific pattern.
AntPen
  
start():void
Start the process or the command.
AntPen
  
stop():void
Stop the process or the command.
AntPen
Property Detail
closePathproperty
public var closePath:Boolean

Indicates if the pen close the path when it draw the shape.

pointsproperty 
public var points:Array

The representation of all points of the path to drawing.

runningproperty 
running:Boolean  [read-only]

Indicates if the ant effect is in progress.


Implementation
    public function get running():Boolean
speedproperty 
speed:Number

Indicates the speed of the effect.


Implementation
    public function get speed():Number
    public function set speed(value:Number):void
stepsproperty 
steps:uint

The steps value of the pen.


Implementation
    public function get steps():uint
    public function set steps(value:uint):void
Constructor Detail
AntPen()Constructor
public function AntPen(graphics:* = null, colors:Array = null, pattern:Array = null, speed:Number = 32, steps:uint = 1, closePath:Boolean = true)

Creates a new AntPen instance.

Parameters
graphics:* (default = null) — The Graphics reference to control with this helper. You can passed-in a Shape or Sprite/MovieClip reference in argument.
 
colors:Array (default = null)
 
pattern:Array (default = null)
 
speed:Number (default = 32)
 
steps:uint (default = 1)
 
closePath:Boolean (default = true)
Method Detail
draw()method
override public function draw(... args):void

Draws the shape and scale it.

Parameters

... args

drawShape()method 
override public function drawShape():void

This method contains the basic drawing shape algorithm.

run()method 
public function run(... arguments):void

Run the process.

Parameters

... arguments

setup()method 
public function setup(colors:Array = null, pattern:Array = null):void

Sets the pen with the specified colors and the specific pattern.

Parameters

colors:Array (default = null)
 
pattern:Array (default = null)

start()method 
public function start():void

Start the process or the command.

stop()method 
public function stop():void

Stop the process or the command.