Using Director > Movies in a Window > Setting the window size and location for a MIAW |  |

Setting the window size and location for a MIAW

Setting the screen coordinates for a MIAW lets you control how large the window is and where it appears. Setting the coordinates before the movie appears controls the initial position of the window; setting them after the window appears moves the window.

To specify the screen coordinates for a MIAW:

Set the `rect` property to the coordinates of the location where you want the window to appear, choosing from the following options:

| Define the coordinates as a rectangle in the order left, top, right, and bottom, as in this statement:
    set window.rect "Sample" = [0, 0, 200, 300]
| Use the `rect()` function to define the window rectangle's four coordinates, as in these statements:
    set aRect = rect(0, 0, 200, 300)
    set window.rect "Sample" = aRect
| For convenience, assign the coordinates to a variable and then use the variable in the statements you write.

See `rect (window)` and `rect()`.