EasyManua.ls Logo

MACROMEDIA DIRECTOR MX 2004-DIRECTOR SCRIPTING - Page 946

MACROMEDIA DIRECTOR MX 2004-DIRECTOR SCRIPTING
1130 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
946 Chapter 14: Properties
rect (Member)
Usage
-- Lingo syntax
memberObjRef.rect
// JavaScript syntax
memberObjRef.rect;
Description
Member property; specifies the left, top, right, and bottom coordinates, returned as a rectangle,
for the rectangle of any graphic cast member, such as a bitmap, shape, movie, or digital video.
Read-only for all cast members, read/write for field cast members only.
For a bitmap, the
rect property is measured from the upper left corner of the bitmap, instead of
from the upper left corner of the easel in the Paint window.
For an Xtra extension cast member, the
rect property is a rectangle whose upper left corner is
at (0,0).
Example
This statement displays the coordinates of bitmap cast member 20:
-- Lingo syntax
put(member(20).rect)
// JavaScript syntax
put(member(20).rect);
This statement sets the coordinates of bitmap cast member Banner:
-- Lingo syntax
member("Banner").rect = rect(100, 150, 300, 400)
// JavaScript syntax
member("Banner").rect = rect(100, 150, 300, 400);
See also
Member
rect (Sprite)
Usage
-- Lingo syntax
spriteObjRef.rect
// JavaScript syntax
spriteObjRef.rect;
Description
Sprite property; specifies the left, top, right, and bottom coordinates, as a rectangle, for the
rectangle of any graphic sprite such as a bitmap, shape, movie, or digital video. Read/write.