-- Lingo syntaxmenu: menuNameitemName| scriptitemName| script ...
or
menu: menuName
itemName | script
itemName | script
...
[more menus]
Keyword; in conjunction with the installMenu command, specifies the actual content of custom menus. Field cast members contain menu definitions; refer to them by the cast member name or number.
The menu keyword is followed immediately by a colon, a space, and the name of the menu. In subsequent lines, specify the menu items for that menu. You can set a script to execute when the user chooses an item by placing the script after the vertical bar symbol (|). A new menu is defined by the subsequent occurrence of the menu keyword.
Note: Menus are not available in Shockwave Player.
On the Macintosh, you can use special characters to define custom menus. These special characters are case-sensitive. For example, to make a menu item bold, the letter B must be uppercase.
Special symbols should follow the item name and precede the vertical bar symbol (|). You can also use more than one special character to define a menu item. Using <B<U, for example, sets the style to Bold and Underline.
Avoid special character formatting for cross-platform movies because not all Windows computers support it.
| Symbol | Example | Description |
|---|---|---|
|
|
*On the Macintosh, creates the Apple symbol and enables Macintosh menu bar items when you define an Apple menu. |
|
|
*On the Macintosh, checks the menu with a check mark (Option+v). |
|
|
*On the Macintosh, sets the menu item's style to Bold. |
|
|
*On the Macintosh, sets the style to Italic. |
|
|
*On the Macintosh, sets the style to Underline. |
|
|
*On the Macintosh, sets the style to Outline. |
|
|
*On the Macintosh, sets the style to Shadow. |
|
|
Associates a script with the menu item. |
|
|
Defines a command-key equivalent. |
|
|
Disables the menu item. |
|
|
Creates a disabled line in the menu. |
*identifies formatting tags that work only on the Macintosh.
This example is the text of a field cast member named CustomMenu2 which can be used to specify the content of a custom File menu. To install this menu, use "installMenu member("CustomMenu2")" while the movie is running. The Convert menu item runs the custom handler convertThis.
menu: File
Open/O | _movie.go("Open")
Close/W | _movie.go("Close")
Convert/C | convertThis
(-
Quit/Q | _movie.go("Quit")
installMenu, name, number (menu items), checkMark, enabled, script
Send me an e-mail when comments are added to this page | Comment Report
Current page: http://livedocs.adobe.com/director/mx2004/release_en/06a_ke17.htm