 |
THE HYPERCARD CENTER |
|
|
Note: This is a work in progress and many formatting issues have been fixed. Read more about the project on the home page.
screenRectthe screenRect
Value returned: a rectangle equal to the dimensions of the screen in pixels If there's more than one monitor, the screenRect returns the dimensions of the monitor displaying the current stack as offsets from the top-left corner of the screen that contains the menu bar. If the card window appears on more than one monitor, the screenRect returns the dimensions of the screen that shows the most area from the card window. Examplesget the screenRect if the mouseLoc is not within it then ... if the screenRect = "0,0,512,342" then ... -- SE size monitor
Demo Scripton screenRectDemo get the screenRect put "The dimensions of the monitor displaying this stack are:" &¬ return & return & "Width:" && (item 3 of it - item 1 of it) &¬ return & "Height:" && (item 4 of it - item 2 of it) into sayIt answer sayIt end screenRectDemo
Related Topics Placeholders
rectangleAn expression that evaluates to a rectangle, in the form of four integers separated by commas (and, in AppleScript, enclosed in brackets). Items 1 and 2 of a rectangle specify the left and top coordinates; items 3 and 4 specify the right and bottom coordinates (in pixels). For example: 0,0,200,250 the rect of card window "30,30," & "240,240" { 10, 35, 250, 300 } --AppleScript form
HyperTalk Reference
|