User Guide

146 Chapter 8: Menus and Menu Commands
About the menus.xml file
The menus.xml file contains a structured list of menu bars, menus, menu items, separators,
shortcut lists, and keyboard shortcuts. These items are described by XML tags that you can edit in
a text editor.
Note: Be careful when making changes to menus. Dreamweaver ignores any menu or menu item that
contains an XML syntax error.
A menu bar (tagged with opening and closing menubar tags) is a discrete menu or set of menus—
for example, theres a main menu bar, a separate Site window menu bar (which appears only on
Windows, not the Macintosh), and a menu bar for each context menu. Each menu bar contains
one or more menus; a menu is contained in a menu tag. Each menu contains one or more menu
items, each described by a
menuitem tag and its attributes. A menu can also contain separators
(described by separator tags) and submenus.
In addition to the keyboard shortcuts associated with menu items, Dreamweaver provides a
variety of other keyboard shortcuts, including alternate shortcuts and shortcuts that are available
only in certain contexts. For example, Control+Y (Windows) or Command+Y (Macintosh) is the
shortcut for Redo; but Control+Shift+Z or Command+Shift+Z is an alternate shortcut for Redo.
These alternates—and other shortcuts that cant be represented in the tags for menu items—are
defined in shortcut lists in the menus.xml file. Each shortcut list (described by a
shortcutlist
tag) contains one or more shortcuts, each of which is described by a shortcut tag.
The following sections describe the syntax of the menus.xml tags. Optional attributes are marked
in the attribute lists with curly braces ({}); all attributes not marked with curly braces are required.
<menubar>
Description
Provides information about a menu bar in the Dreamweaver menu structure.
Attributes
name, {app}, id, {platform}
name The name of the menu bar. Although name is a required attribute, you can give it the
value "".
app The name of the application in which the menu bar is available. Not currently used.
id The menu ID for the menu bar. Each menu ID in the menus.xml file should be unique.
platform Indicates that the menu bar should appear only on the given platform. Valid values
are
"win" and "mac".
Contents
This tag must contain one or more menu tags.
Container
None.