beautypg.com

Stroke.color, Stroke.curve – Adobe Extending Flash Professional CS4 User Manual

Page 424

background image

402

EXTENDING FLASH CS4 PROFESSIONAL

Stroke object

stroke.color

Availability
Flash MX 2004. In Flash 8 and later, this property is deprecated in favor of

stroke.shapeFill.color

.

Usage

stroke.color

Description
Property; the color of the stroke, in one of the following formats:

A string in the format

"#RRGGBB"

or

"#RRGGBBAA"

A hexadecimal number in the format

0xRRGGBB

An integer that represents the decimal equivalent of a hexadecimal number

Example
The following example sets the stroke color:

var myStroke = fl.getDocumentDOM().getCustomStroke();

myStroke.color = "#000000";

fl.getDocumentDOM().setCustomStroke(myStroke);

See also

stroke.shapeFill

stroke.curve

Availability
Flash MX 2004.

Usage

stroke.curve

Description
Property; a string that specifies the type of hatching for the stroke. This property can be set only if the

stroke.style

property is set to

"hatched"

(see

stroke.style

). Acceptable values are

"straight"

,

"slight curve"

,

"medium

curve"

, and

"very curved"

.

Example
The following example sets the curve property, as well as others, for a stroke having the

hatched

style: