Common Desktop Environment: Application Builder User's Guide

To Edit a Menu

After creating a menu you will need to edit the menu: add menu items, give the menu items meaningful names, add submenus, and so on.

  1. Display the Menu Property Editor by choosing Menus from the Editors menu in the App Builder primary window.

    Or, display the Revolving Property Editor and choose Menu as the Object Type.

    See "Menu Property Editor " for a description of the editor.

  2. Change Object Name, if necessary.

    The automatically-generated Object names, which are unique within modules, do not usually need to be changed.

  3. Click Enabled to enable the Tearoff function, if necessary.

    This will make the menu "postable," meaning that if you click on the Tearoff indicator (a dotted line) the menu will not be dismissed as soon as you select a menu item. The menu will remain posted until you dismiss it.

  4. Add menu items to the Items list, if necessary.

    Click Add Item to add an item after the selected item; choose from the Edit menu button to perform other edit functions.

  5. Change Item Label Type for menu items in the Items list, if necessary.

    Choices are String (text), Graphic, or Separator. Label becomes Graphic Filename if Graphic is chosen; Line Style becomes active if Separator is chosen.

  6. Type a different Label or Graphic Filename for the selected item, if necessary.


    Note -

    The easiest way to edit labels for menu items is to select the first one in the Items list, thus selecting it in the Label field. Type a new name and click Return. The new name will be displayed in the Items list and the next item in the list will be selected. Continue down the list with this select, type, Return process until all labels are completed.


    If Graphic Item Label Type was chosen, the Graphic Filename must be an xpm or xbm graphic file.

  7. Type an Item Mnemonic, if necessary.

    Type one of the letters in the item label. That letter will be underlined in the menu item label. If the menu is posted, pressing that key will cause the action connected with the menu item to be performed.


    Note -

    The same mnemonic letter, regardless of case, cannot be used more than once in a menu.


  8. Type an Accelerator, if necessary.

    An accelerator is comprised of a prefix (Ctrl, Alt, Meta, or Shift), <Key>, and a letter (uppercase or lowercase). See "Menu Property Editor " for more information.

  9. Choose a Line Style, if Item Label Type is Separator.

    See "Menu Property Editor " for the list of choices.

  10. Attach an Item Submenu, if appropriate.

    See "To Attach an Existing Submenu to a Menu Item " for instructions.

  11. Change Item State, if necessary.

    By default the item state is Active. If you want the menu item to be inactive when the application is started, click the Active check box to deselect it.

  12. Select Background and Foreground Colors, if necessary.

    Type in a color or choose Color Chooser from the menu and select a color from the Color Chooser. See "To Select Colors from the Color Chooser " for details.

  13. Click Connections to add programmatic connections to menu items, as necessary.

    See "Connecting Menu Items to Actions" for instructions.

  14. Click Apply or OK to apply the changes.

    If you click Apply the property editor will remain displayed.