A keymap is suitable for menu use if it has an overall prompt
string, which is a string that appears as an element of the keymap.
(See section Format of Keymaps.) The string should describe the purpose of
the menu. The easiest way to construct a keymap with a prompt string is
to specify the string as an argument when you call make-keymap
or
make-sparse-keymap
(see section Creating Keymaps).
The order of items in the menu is the same as the order of bindings in
the keymap. Since define-key
puts new bindings at the front, you
should define the menu items starting at the bottom of the menu and
moving to the top, if you care about the order. When you add an item to
an existing menu, you can specify its position in the menu using
define-key-after
(see section Modifying Menus).
Go to the first, previous, next, last section, table of contents.