From: "Drew Adams" <drew.adams@oracle.com>
To: 10251@debbugs.gnu.org
Subject: bug#10251: 24.0.92; easymenu: Document how to conditionalize display of separators.
Date: Thu, 8 Dec 2011 11:19:37 -0800 [thread overview]
Message-ID: <C946F06DE9CC43C8B15B37380E3EC26A@us.oracle.com> (raw)
Consider a use case such as this. You have a mouse menu with several
groups of items, separated by separator lines (e.g. "--"). One or more
of these groups should only be shown under certain conditions
(e.g. (featurep 'foo)). You thus want to give a :visible condition to
not only the menu items in such a group but also to the separator that
precedes (or follows) the group.
In easymenu, the only documented case for a separator is a string of
separator chars, e.g. "--", not a vector entry that contains keywords
such as :visible.
You can use ["--" 'ignore :visible (my-condition)] to do the job. But
this possibility is likely not to be obvious to everyone. So please
document it. (BTW, is there some other way to accomplish this?)
See also http://debbugs.gnu.org/cgi/bugreport.cgi?bug=6344#21, which was
a similar bug (fixed).
In GNU Emacs 24.0.92.1 (i386-mingw-nt5.1.2600) of 2011-12-06 on MARVIN
Windowing system distributor `Microsoft Corp.', version 5.1.2600
configured using `configure --with-gcc (4.6) --no-opt --cflags
-ID:/devel/emacs/libs/libXpm-3.5.8/include
-ID:/devel/emacs/libs/libXpm-3.5.8/src
-ID:/devel/emacs/libs/libpng-dev_1.4.3-1/include
-ID:/devel/emacs/libs/zlib-dev_1.2.5-2/include
-ID:/devel/emacs/libs/giflib-4.1.4-1/include
-ID:/devel/emacs/libs/jpeg-6b-4/include
-ID:/devel/emacs/libs/tiff-3.8.2-1/include
-ID:/devel/emacs/libs/gnutls-2.10.1/include --ldflags
-LD:/devel/emacs/libs/gnutls-2.10.1/lib'
next reply other threads:[~2011-12-08 19:19 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-12-08 19:19 Drew Adams [this message]
2012-09-17 0:21 ` bug#10251: 24.0.92; easymenu: Document how to conditionalize display of separators Drew Adams
2014-02-09 5:42 ` Lars Ingebrigtsen
2014-02-11 15:05 ` Drew Adams
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=C946F06DE9CC43C8B15B37380E3EC26A@us.oracle.com \
--to=drew.adams@oracle.com \
--cc=10251@debbugs.gnu.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.