Administration > Customizing the Arbortext Editor Interface > RemappingToolbar Buttons
RemappingToolbar Buttons
Arbortext Editor toolbars are configured using XUI.
The standard toolbars are defined in the file Arbortext-path/lib/dialogs/editwindow.xml. You can customize the file by copying it to Arbortext-path/custom/lib/dialogs directory and modifying its contents.
Alternatively, use the various dlgitem_xxxx() functions to programmatically change the operation of toolbars as in the following examples..
Creating new toolbars
Create new toolbars by defining them in a separate XUI document and loading them with either the ACL function window_load_componentfile() or the AOM Window method loadComponentFile().
Adding button callbacks
Add button callbacks using dlgitem_add_callback()
For example:
dlgitem_add_callback(current_window(), "Toolbar_Open", "open_callback")
In this code, open_callback is the name of the function to call when the button is pressed. The tag name argument to dlgitem_xxx() functions is the value of the id attribute on the element defining the button.
Refer to the Custom Dialog Box Functions section of the Arbortext Command Language Reference for descriptions of all available dlgitem_xxx() functions.
Redefining the command alias assigned to a toolbar button
As an example, the Open toolbar button is defined in editwindow.xml as:
<button id="Toolbar_Open" image="imageOpen"
This markup associates the predefined alias FileOpen to the button. This can be redefined as
alias FileOpen {
response("Toolbar_Open pressed")
Because the alias is also used for the File > Open menu item and the keyboard shortcut CTRL+O, this change will also apply to those methods of opening files.
Removing toolbar buttons
The standard toolbars are defined in the file Arbortext-path/lib/dialogs/editwindow.xml. That file contains several <toolbar/> elements. Each of these elements defines a toolbar. Each <toolbar> element contains one or more <button> elements. The value of the id attribute on a <button> element is the name of the button. Use this value with the dlgitem_withdraw() function.
For example, editwindow.xml contains the following code:
<toolbar id="toobar2" …>

<button command="…" id="Toolbar_ModifyAttributes"…/>
This <button> tag defines defines the Modify Attributes toolbar button. To remove this button, enter the command in Arbortext Editor command line:
dlgitem_withdraw(current_window(), 'Toolbar_ModifyAttributes')