Please enable JavaScript to view this site.

ESL Documentation

Action Statement

Change the position of an object.

change {OBJECT_NAME|CLASS_NAME} position

{by XOFFSET YOFFSET|to X Y} [in PARENT_NAME]

OBJECT_NAME

The identifier for an object.

CLASS_NAME

The identifier for a class of objects.

by XOFFSET YOFFSET

Move the object's origin by relative X and Y coordinates from its current position, in the coordinate system of its parent. XOFFSET and YOFFSET must be integer values representing the number of relative coordinates by which you want to move the object, in the parent's coordinates.

to X Y

Move the object's origin to the absolute X and Y coordinates specified, in the coordinate system of its parent. X and Y must be integer values representing the absolute coordinates of the object's new origin.

in PARENT_NAME

Remove the current parent of the object and place the object in the coordinate system of the specified new parent (PARENT_NAME). If you omit this clause, the object will remain in the coordinate system of its parent.

Description

Use this statement to change the position of any object to either a positional offset or a new location in its parent or to a position in a different parent. ESL uses the coordinate system of the destination parent when moving objects.

Example

 

response to Sel2_PB

 change Square_Key position by 50 100

 

response to Red_Key

 change Square_Key position to 110 120

 

response to Menu3

 change Button1_PB in Menu1 position by -50 0

 

response to Colder

 change Zipper position to 100 300 in NewCoat

 visible textual region MoveIntoView_GR # Not in window of

 size 100 100 # PrimaryWindow initially

 at 1000 1000 in PrimaryWindow_GR

 

response to DoIt_PB

 change MoveIntoView_GR position to 50 50 in PrimaryWindow_GR

See Also

ancestry Response Inquiry Built-in Function

ancestry of Object Inquiry Built-in Function

change window position Action Statement

position Keyword