User Guide
The toolbar definition file 173
5 Dreamweaver calls the getCurrentValue() function on every update cycle, as specified by the
update attribute, to determine what value to display for the control.
6 The user selects an item on the toolbar.
7 Dreamweaver calls the receiveArguments() function to process any arguments that the
arguments attribute of the toolbar item specifies.
For more information on the purpose of specific functions in the Toolbar Command API, see
“The toolbar command API” on page 187.
The toolbar definition file
A toolbar is simply a list of radio buttons, check buttons, edit boxes, and other toolbar items,
optionally divided by
separator tags. Each toolbar item can be a reference to an item using the
itemref tag, a separator using the separator tag, or a complete toolbar item definition, for a
checkbox or an edit box, for example, as described in “Toolbar item tags” on page 177.
Each toolbar definition file starts with the following declarations:
<?xml version="1.0" encoding="optional_encoding"?>
<!DOCTYPE toolbarset SYSTEM "-//Macromedia//DWExtension toolbar 5.0">
If the encoding is omitted, Dreamweaver uses the default encoding of the operating system.
After the declarations, the file consists of a single
toolbarset tag, which contains any number of
the following tags:
toolbar, itemref, separator, include, and itemtype tags, where itemtype
is a
button, checkbutton, radiobutton, menubutton, dropdown, combobox, editcontrol, or
colorpicker. The following example, which is an abbreviated excerpt from the toolbars.xml file,
illustrates the hierarchy of tags in the toolbar file. The example substitutes ellipses (. . .) for the
toolbar item attributes that are described in the following sections.
<?xml version="1.0"?>
<!DOCTYPE toolbarset SYSTEM "-//Macromedia//DWExtension toolbar 5.0">
<toolbarset>
<!-- main toolbar -->
<toolbar id="DW_Toolbar_Main" label="Document">
<radiobutton id="DW_CodeView" . . ./>
<radiobutton id="DW_SplitView" . . ./>
<radiobutton id="DW_DesignView" . . ./>
<separator/>
<checkbutton id="DW_LiveDebug" . . ./>
<checkbutton id="DW_LiveDataView" . . ./>
<separator/>
<editcontrol id="DW_SetTitle" . . ./>
<menubutton id="DW_FileTransfer" . . ./>
<menubutton id="DW_Preview" . . ./>
<separator/>
<button id="DW_DocRefresh" . . ./>
<button id="DW_Reference" . . ./>
<menubutton id="DW_CodeNav" . . ./>
<menubutton id="DW_ViewOptions" . . ./>
</toolbar>
</toolbarset>
The following section describes each of the toolbar tags.