From: Drew Adams <drew.adams@oracle.com>
To: Lars Ingebrigtsen <larsi@gnus.org>
Cc: 26428@debbugs.gnu.org
Subject: bug#26428: 24.5; (elisp) Extended Menu Items: document same features for menus
Date: Sat, 12 Dec 2020 14:01:38 -0800 (PST) [thread overview]
Message-ID: <0c41efdb-437f-4f41-85b2-6f28a3d80c66@default> (raw)
In-Reply-To: <87eeju953d.fsf@gnus.org>
> Could you suggest a text for the manual to document this?
Doing this quickly. Modify as you see fit.
In node `Extended Menu Items' we say:
To define a real menu item which can be selected,
the extended format binding looks like this:
(menu-item ITEM-NAME REAL-BINDING
. ITEM-PROPERTY-LIST)
Here, ITEM-NAME is an expression which evaluates to
the menu item string. Thus, the string need not be
a constant. The third element, REAL-BINDING, is the
command to execute. The tail of the list,
ITEM-PROPERTY-LIST, has the form of a property list
which contains other information.
The last paragraph could be changed to indicate that
REAL-BINDING can be a command or a menu keymap (but
not a keymap-variable symbol). Something like this
perhaps:
Here, ITEM-NAME is an expression which evaluates to
the menu item string. Thus, the string need not be
a constant.
The third element, REAL-BINDING, is the command to
execute or a menu keymap (but not a keymap-variable
symbol). If it is a menu keymap, that is, a keymap
that has a prompt string, then ITEM-NAME is the
name that appears for the submenu in its parent menu.
The tail of the list, ITEM-PROPERTY-LIST, has the
form of a property list that contains other information.
If you don't think that's clear enough (I do) then you
can add an example such as what I provided in the bug
report.
One thing I'm not clear on (haven't investigated): I'm
guessing that the keymap you provide here needs to be
a menu keymap, that is, a keymap with a prompt string.
Dunno whether that's true. If not, remove mention of
that.
Whether that's actually needed or just possible, when
it happens what's the relation between the prompt
string and ITEM-NAME? I'm guessing that ITEM-NAME is
used for the submenu name that appears, and the prompt
string is not used in this context.
next prev parent reply other threads:[~2020-12-12 22:01 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-04-09 21:23 bug#26428: 24.5; (elisp) Extended Menu Items: document same features for menus Drew Adams
2020-12-12 19:50 ` Lars Ingebrigtsen
2020-12-12 22:01 ` Drew Adams [this message]
2020-12-13 12:49 ` Lars Ingebrigtsen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=0c41efdb-437f-4f41-85b2-6f28a3d80c66@default \
--to=drew.adams@oracle.com \
--cc=26428@debbugs.gnu.org \
--cc=larsi@gnus.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.