cursor | |||||||
Type | property | ||||||
Dictionary | LCS | ||||||
Library | LiveCode Script | ||||||
Syntax |
| ||||||
Summary | Specifies the shape of the cursor. | ||||||
Introduced | 1.0 | ||||||
OS | mac, windows, linux | ||||||
Platforms | desktop, server | ||||||
Example |
| ||||||
Values |
| ||||||
Related | Keyword: image, field, items, point Property: cursor, yHot, lockCursor, ID Command: lock cursor, delete stack Object: stack, image Glossary: property, select, loop, handler, execute, download, cursor, hypertext, mouse pointer, command Control Structure: repeat | ||||||
Description | Use the cursor property to signal the status of a handler to the user or to indicate what kind of data the mouse pointer is over. For example, a watch cursor shows the user that a handler is executing, while an I-beam cursor indicates that the text under the mouse pointer is editable. LiveCode looks for the specified image in the following order:
LiveCode includes several built-in cursors whose names you can use in place of their image IDs. The built-in cursors and their recommended uses are:
The busy cursor is a rotating beach ball. Each time you use the statement set the cursor to busy, the beach ball advances in its rotation. For example, the following statements cause the cursor to appear to spin as long as the repeat loop is running:
You can also set the cursor property to the ID of an image. Custom cursor images must contain three colors: black, white, and a transparent color. *Cross-platform note:*
If the lockCursor property is set to false, LiveCode automatically sets the cursor according to its location once the handler finishes. (For example, the cursor normally turns into an arrow over a menu, an I-beam over an editable text field, and so on.) To retain the cursor property after a handler finishes, use the lock cursor command. You can force LiveCode to use the operating system's cursors with the following two statements:
Caution! If you use the delete stack command to remove the "revCursors" stack, LiveCode's cursors are permanently deleted and you will need to download a new cursors stack to restore them. If you change the set of built-in LiveCode cursors in the "revCursors" stack, you must either quit and restart the application or use the reset cursors command to begin using the new cursor shapes. | ||||||
Tags | ui |