User Guide
512 Objects
Description
Read-only property; a Boolean value that identifies if the Alt key is being pressed. The value is
true if the Alt key is pressed, and false otherwise.
Example
The following example determines whether the Alt key is being pressed.
var isAltDown = fl.tools.altIsDown;
tools.constrainPoint()
Availability
Flash MX 2004.
Usage
tools.constrainPoint(pt1, pt2)
Parameters
pt1 and pt2 specify the starting-click point and the drag-to point.
Returns
A new adjusted or constrained point.
Description
Method; takes two points and returns a new adjusted or constrained point. If the Shift key is
pressed when the command is run, the returned point is constrained to follow either a 45
ยบ
constrain (useful for something such as a line with an arrowhead) or to constrain an object to
maintain its aspect ratio (such as pulling out a perfect square with the rectangle tool).
Example
The following example returns a constrained point:
pt2 = fl.tools.constrainPoint(pt1, tempPt);