From: "Drew Adams" <drew.adams@oracle.com>
To: <emacs-devel@gnu.org>
Subject: mode-line-format - local variableness
Date: Sun, 5 Apr 2009 15:18:37 -0700 [thread overview]
Message-ID: <004901c9b63c$77c768e0$0200a8c0@us.oracle.com> (raw)
(defun foo (text &optional buffer)
"Display TEXT in BUFFER's mode line for 2 sec."
(with-current-buffer (or buffer (current-buffer))
(let ((mode-line-format text))
(force-mode-line-update) (sit-for 2))
(force-mode-line-update)))
M-: (foo "JJJJJ" "*scratch*")
In Emacs 20, JJJJJ is displayed in the mode-line of buffer *scratch* only. The
mode lines of other buffers are unaffected.
In Emacs 21 and later, *each* buffer's mode-line shows JJJJJ.
What am I missing? `mode-line-format' is a buffer-local variable. That makes me
think the Emacs 20 behavior is correct and the behavior since then is incorrect.
I assume I must be missing something here. Can someone please clue me in? Thx.
next reply other threads:[~2009-04-05 22:18 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-04-05 22:18 Drew Adams [this message]
2009-04-05 22:50 ` mode-line-format - local variableness Johan Bockgård
2009-04-05 23:24 ` Miles Bader
2009-04-05 23:29 ` Drew Adams
2009-04-05 23:37 ` Drew Adams
2009-04-06 0:50 ` Miles Bader
2009-04-06 3:05 ` Drew Adams
2009-04-06 1:37 ` Stefan Monnier
2009-04-06 3:19 ` Drew Adams
2009-04-06 13:30 ` Stefan Monnier
2009-04-06 21:37 ` Miles Bader
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
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='004901c9b63c$77c768e0$0200a8c0@us.oracle.com' \
--to=drew.adams@oracle.com \
--cc=emacs-devel@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 public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).