Adobe® Flex® 4 Language Reference
Hide Packages and Classes List |  Packages  |  Classes  |  Index  |  Appendixes
mx.graphics 
IStroke 
Packagemx.graphics
Interfacepublic interface IStroke
Implementors GradientStroke, SolidColorStroke

Language Version: ActionScript 3.0
Product Version: Flex 3
Runtime Versions: Flash Player 9, AIR 1.1

Defines the interface that classes that define a line must implement.



Public Properties
 PropertyDefined By
  joints : String
[read-only] Specifies the appearance of line intersections used at angles.
IStroke
  miterLimit : Number
[read-only] Indicates the limit at which a miter is cut off.
IStroke
  scaleMode : String
[read-only] A value from the LineScaleMode class that specifies which scale mode to use.
IStroke
  weight : Number
The line weight, in pixels.
IStroke
Public Methods
 MethodDefined By
  
apply(graphics:Graphics, targetBounds:Rectangle, targetOrigin:Point):void
Applies the properties to the specified Graphics object.
IStroke
  
Generates a GraphicsStroke object representing this stroke.
IStroke
Property Detail

joints

property
joints:String  [read-only]

Language Version: ActionScript 3.0
Product Version: Flex 3
Runtime Versions: Flash Player 9, AIR 1.1

Specifies the appearance of line intersections used at angles. Valid values are JointStyle.ROUND, JointStyle.MITER, and JointStyle.BEVEL.



Implementation
    public function get joints():String

See also

flash.display.JoingStyle

miterLimit

property 
miterLimit:Number  [read-only]

Language Version: ActionScript 3.0
Product Version: Flex 3
Runtime Versions: Flash Player 9, AIR 1.1

Indicates the limit at which a miter is cut off. Valid values range from 0 to 255.

The default value is 3.



Implementation
    public function get miterLimit():Number

scaleMode

property 
scaleMode:String  [read-only]

Language Version: ActionScript 3.0
Product Version: Flex 3
Runtime Versions: Flash Player 9, AIR 1.1

A value from the LineScaleMode class that specifies which scale mode to use. Value valids are:

  • LineScaleMode.NORMAL— Always scale the line thickness when the object is scaled (the default).
  • LineScaleMode.NONE— Never scale the line thickness.
  • LineScaleMode.VERTICAL— Do not scale the line thickness if the object is scaled vertically only.
  • LineScaleMode.HORIZONTAL— Do not scale the line thickness if the object is scaled horizontally only.

The default value is LineScaleMode.NORMAL.



Implementation
    public function get scaleMode():String

See also

weight

property 
weight:Number

Language Version: ActionScript 3.0
Product Version: Flex 3
Runtime Versions: Flash Player 9, AIR 1.1

The line weight, in pixels. For many chart lines, the default value is 1 pixel.



Implementation
    public function get weight():Number
    public function set weight(value:Number):void
Method Detail

apply

()method
public function apply(graphics:Graphics, targetBounds:Rectangle, targetOrigin:Point):void

Language Version: ActionScript 3.0
Product Version: Flex 3
Runtime Versions: Flash Player 9, AIR 1.1

Applies the properties to the specified Graphics object.

Parameters

graphics:Graphics — The Graphics object to apply the properties to.
 
targetBounds:Rectangle — The bounds of the shape that the stroke is applied to.
 
targetOrigin:Point — The Point that defines the origin (0,0) of the shape in the coordinate system of target.

createGraphicsStroke

()method 
public function createGraphicsStroke(targetBounds:Rectangle, targetOrigin:Point):GraphicsStroke

Language Version: ActionScript 3.0
Product Version: Flex 4
Runtime Versions: Flash Player 10, AIR 1.5

Generates a GraphicsStroke object representing this stroke.

Parameters

targetBounds:Rectangle — The stroke's bounding box.
 
targetOrigin:Point — The Point that defines the origin (0,0) of the shape in the coordinate system of target.

Returns
GraphicsStroke — The Drawing API-2 GraphicsStroke object representing this stroke.