From: Stefan Monnier <monnier@IRO.UMontreal.CA>
To: Michael Mauger <mmaug@yahoo.com>
Cc: Emacs Devel <emacs-devel@gnu.org>
Subject: Re: Dynamically modifying menu entries
Date: Tue, 20 Jul 2010 13:18:25 +0200 [thread overview]
Message-ID: <jwv8w56z9me.fsf-monnier+emacs@gnu.org> (raw)
In-Reply-To: <407470.62599.qm@web62502.mail.re1.yahoo.com> (Michael Mauger's message of "Sun, 18 Jul 2010 22:15:50 -0700 (PDT)")
> I am building a menu using `easy-menu-define' with a submenu whose
> entries are dependent on the entries in a list in the package.
> The contents of the list may change and based on those changes the
> contents of the submenu may change. This is not as simple as
> enabling/disabling menu entries; it involves adding and removing
> entries based on the contents of the separate list.
If the set of possible entries is finite (and reasonably small), then
you can use :visible, but otherwise :filter is most likely the way to go.
> It also does appear that the submenu doesn't get refreshed as
> frequently as I'd like. Ideally, I'd like to be able to populate the
> submenu when it's selected rather than having to predefine the
> menu contents.
:filter should be run often enough (or even more often than that, in my
experience), so if it's not often enough for you, please report the
precise case where it fails to be (re)run.
Stefan
prev parent reply other threads:[~2010-07-20 11:18 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-07-19 5:15 Dynamically modifying menu entries Michael Mauger
2010-07-19 6:18 ` Drew Adams
2010-07-20 11:18 ` Stefan Monnier [this message]
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=jwv8w56z9me.fsf-monnier+emacs@gnu.org \
--to=monnier@iro.umontreal.ca \
--cc=emacs-devel@gnu.org \
--cc=mmaug@yahoo.com \
/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.