XPToolkit Menu Requirements
Written by Chris Saari
Last Modified: 2/23/99
Overview
This document covers the menu bar, menu lists, and menu items.
This does not cover context menus, although they should be very
similar. This does not cover popup menus, those are a seperate
widget. This does not cover keyboard equivalents or accelerators for
menus, pending more work in that area. This lightly touches
menu/command merging, but that is very preliminary.
A menu item is a line item in a visible UI menu. It has
text (displayed visually) and may contain a shortcut key (cmd-Q for
example). A menu item can be enabled or disabled separately from the
other items around it. A special kind of menu item, called a
separator, is visually represented as a disabled horizontal
line with no text.
A menu list corresponds to an entire UI menu, and is a
sequential ordered list of menu items. A menu list may be
hierarchical and have sub-menu lists hanging off of items.
A menu bar is an ordered collection of menu lists. Menu
bars are used to present several menus, usually in a non-transient
way. Context menus, for example, would not use a menu bar since they
are only displaying a single transient menu.
Requirements
- Internationalization support. Dependent upon each OS's
support?
- Keyboard navigation, both keyboard accelerators and
equivalents
Menu Bars
- create a menu bar
- destroy a menu bar
- draw a menu bar
- get menu bar of a window
- set menu bar of a window
- set default menu bar for app (Mac apps can have menu bars with
no windows)
- highlight a menu bar item (needed?)
Menu List
- create a menu list (menu)
- destroy a menu list (menu)
- add a menu list (menu) to menu bar
- insert a menu list (menu) in a menu bar
- remove a menu list (menu) from a menu bar
- set a menu list's (menu's) icon
- get a menu list's (menu's) icon
- enable/disable a menu list
Menu Items
- create a menu item
- destroy a menu item
- add a menu item to a menu list (menu)
- remove a menu item from a menu list (menu)
- add a separator to a menu list (menu)
- get a menu item's text
- set a menu item's text
- check/uncheck a menu item
- enable/disable a menu item
- query if menu item is checked
- query if menu item is enabled
- query if menu item has a submenu
- assign a submenu to an menu item
- remove a submenu from a menu item
- set a menu item's Command Node (abstract command
node) [is this still
relevant?]
- get a menu item's Command Node (abstract command node)
[is this still
relevant?]
Menu Item Arbitration / Merging
We are unclear at this time if Menu Merging is a requirement.
Questions, comments, or concerns about this document should go to
netscape.public.mozilla.xpfe