Chapter 19. Customizing the Interface
Dreamweaver 4 offers greater extensibility and customization than its predecessors and competitors. Beyond the preferences covered in the previous chapter, you can customize Dreamweaver’s menus, keyboard shortcuts, and Objects panel (downloadable extensions, described in Chapter 22, often modify these UI elements to give developers access to enhanced functionality).
Customizing Menus
Dreamweaver menus are defined in an XML-like syntax and stored in the Dreamweaver4/Configuration/Menus/menus.xml file. To customize the menus, exit Dreamweaver and modify the menus.xml file in a text editor, such as WordPad (Windows) or BBEdit (Macintosh).
Warning
Do not edit the menus.xml file in
an XML-savvy editor, as it is not a true XML file. It contains
ampersands (&)
that generate errors when the XML is parsed. Also, don’t edit
menus.xml in Dreamweaver. Don’t change the
existing id attributes within the file. If you
make a mistake, restore menus.xml
from the backup copy, menus.bak,
provided by Macromedia in the same folder.
The menus.xml file defines menu bars, menus, and
menu items. Example 19-1 shows an excerpt of the code
that defines Dreamweaver’s Edit menu.
Example 19-1. An excerpt of the Edit menu definition
<menu name="_Edit" id="DWMenu_MainSite_Edit"> <menuitem name="Cu_t" key="Cmd+X" enabled="dw.canClipCut( )" command="dw.clipCut( )" id="DWMenu_MainSite_Edit_Cut" /> <menuitem name="_Copy" key="Cmd+C" enabled="dw.canClipCopy( )" command="dw.clipCopy( ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access