From: charles@aurox.ch (Charles A. Roelli)
To: Eli Zaretskii <eliz@gnu.org>
Cc: agrambot@gmail.com, 27114@debbugs.gnu.org,
npostavs@users.sourceforge.net
Subject: bug#27114: 25.2: fringe click echoes "Emacs-Lisp:" in emacs-lisp mode
Date: Mon, 21 Aug 2017 15:20:14 +0200 [thread overview]
Message-ID: <m2ziatoy5t.fsf@aurox.ch> (raw)
In-Reply-To: <83k21ycmlk.fsf@gnu.org> (message from Eli Zaretskii on Sun, 20 Aug 2017 17:58:31 +0300)
> Date: Sun, 20 Aug 2017 17:58:31 +0300
> From: Eli Zaretskii <eliz@gnu.org>
>
> > Date: Sun, 20 Aug 2017 16:14:40 +0200
> > From: charles@aurox.ch (Charles A. Roelli)
> > CC: eliz@gnu.org, npostavs@users.sourceforge.net,
> > 27114@debbugs.gnu.org
> >
> > > --- a/lisp/progmodes/elisp-mode.el
> > > +++ b/lisp/progmodes/elisp-mode.el
> > > @@ -45,7 +45,7 @@ emacs-lisp-mode-syntax-table
> > > "Syntax table used in `emacs-lisp-mode'.")
> > >
> > > (defvar emacs-lisp-mode-map
> > > - (let ((map (make-sparse-keymap "Emacs-Lisp"))
> > > + (let ((map (make-sparse-keymap))
> > > (menu-map (make-sparse-keymap "Emacs-Lisp"))
> > > (lint-map (make-sparse-keymap))
> > > (prof-map (make-sparse-keymap))
> >
> > Thanks for finding this out. The function that prints "Emacs-Lisp:"
> > to the echo area during the click is "read_char_minibuf_menu_prompt"
> > (keyboard.c), which calls Fkeymap_prompt (which in the scenario of
> > this bug, returns "Emacs-Lisp"), and eventually executes these lines:
> >
> > /* Prompt with that and read response. */
> > message3_nolog (apply1 (intern ("concat"), Fnreverse (menu_strings)));
> >
> > Maybe it's wrong for "read_char" to call this function
> > ("read_char_minibuf_menu_prompt") for some click events.
>
> No, it's not wrong. It's a feature: it provides visual feedback for
> incomplete mouse clicks. The ELisp manual explicitly says to provide
> this string, which it calls "overall prompt", for all keymaps that can
> be menus. Which this keymap can.
Thanks. But it seems this "overall prompt" should only be set for
menu keymaps, not general mode maps.
For example,
(keymap-prompt lisp-interaction-mode-map)
nil
(keymap-prompt python-mode-map)
nil
(keymap-prompt c-mode-map)
nil
(keymap-prompt emacs-lisp-mode-map)
"Emacs-Lisp"
> (If you make the proposed change, and then visit some .el file and
> click C-mouse-3, what do you see in the header of the pop-up menu?)
I still see "Emacs-Lisp Mode" (it's unchanged). Notice that Alex's
change removes the "overall prompt" from the "main" Emacs Lisp mode
keymap, but not the menu-map.
next prev parent reply other threads:[~2017-08-21 13:20 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-05-28 9:46 bug#27114: 25.2: fringe click echoes "Emacs-Lisp:" in emacs-lisp mode Charles A. Roelli
2017-05-30 23:16 ` npostavs
2017-05-31 6:23 ` Eli Zaretskii
2017-08-09 23:07 ` Alex
2017-08-20 14:14 ` Charles A. Roelli
2017-08-20 14:58 ` Eli Zaretskii
2017-08-21 13:20 ` Charles A. Roelli [this message]
2017-08-21 14:37 ` Eli Zaretskii
2017-08-24 9:38 ` Charles A. Roelli
2018-07-18 1:45 ` Noam Postavsky
2017-10-01 4:25 ` Alex
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=m2ziatoy5t.fsf@aurox.ch \
--to=charles@aurox.ch \
--cc=27114@debbugs.gnu.org \
--cc=agrambot@gmail.com \
--cc=eliz@gnu.org \
--cc=npostavs@users.sourceforge.net \
/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).