beautypg.com

Shape.numcubicsegments, Shape.vertices – Adobe Extending Flash Professional CS5 User Manual

Page 408

background image

386

EXTENDING FLASH PROFESSIONAL

Shape object

Last updated 5/2/2011

Usage

shape.members

Description
Read-only property; an array of objects in the currently selected group. This property is available only if the value of

shape.isGroup

is

true

). Raw shapes in the group are not included in the

shape.members

array.

For example, if the group contains three drawing objects and three raw shapes, the

shape.members

array contains

three entries, one for each of the drawing objects. If the group contains only raw shapes, the array is empty.

Example
The following code displays the number of cubic segments of each drawing object in the currently selected group:

var shapesArray = fl.getDocumentDOM().selection[0].members;
for (i=0; i

fl.trace(shapesArray[i].numCubicSegments);

}

See also

shape.isGroup

shape.numCubicSegments

Availability
Flash CS4 Professional.

Usage

shape.numCubicSegments

Description
Read-only property; the number of cubic segments in the shape.

Example
Assuming a square or rectangle shape is selected, the following code displays “4” in the Output panel:

var theShape = fl.getDocumentDOM().selection[0];
fl.trace(theShape.numCubicSegments);

shape.vertices

Availability
Flash MX 2004.

Usage

shape.vertices

This manual is related to the following products: