From: Eshel Yaron <me@eshelyaron.com>
To: emacs-devel@gnu.org
Cc: Sean Whitton <spwhitton@spwhitton.name>
Subject: Re: master c3e989ca9d7: New minor mode find-function-mode replaces find-function-setup-keys
Date: Fri, 04 Oct 2024 11:56:17 +0200 [thread overview]
Message-ID: <m1ed4wfaym.fsf@dazzs-mbp.home> (raw)
In-Reply-To: <20241004002843.024A41867DE@vcs3.savannah.gnu.org> (Sean Whitton's message of "Thu, 3 Oct 2024 20:28:42 -0400 (EDT)")
Hi,
Sean Whitton <spwhitton@spwhitton.name> writes:
> branch: master
> commit c3e989ca9d786e001a9801fdd95fcbcb0d73fddc
> Author: Sean Whitton <spwhitton@spwhitton.name>
> Commit: Sean Whitton <spwhitton@spwhitton.name>
>
> New minor mode find-function-mode replaces find-function-setup-keys
>
> * lisp/emacs-lisp/find-func.el (find-function-mode-map):
> (find-function-mode): New minor mode.
> (find-function-setup-keys): Replace with stub function that just
> enables the new minor mode. Mark as obsolete.
[...]
> +(defvar-keymap find-function-mode-map
> + "C-x F" #'find-function
> + "C-x 4 F" #'find-function-other-window
> + "C-x 5 F" #'find-function-other-frame
> +
> + "C-x K" #'find-function-on-key
> + "C-x 4 K" #'find-function-on-key-other-window
> + "C-x 5 K" #'find-function-on-key-other-frame
> +
> + "C-x V" #'find-variable
> + "C-x 4 V" #'find-variable-other-window
> + "C-x 5 V" #'find-variable-other-frame
> +
> + "C-x L" #'find-library
> + "C-x 4 L" #'find-library-other-window
> + "C-x 5 L" #'find-library-other-frame)
> +
> +;;;###autoload
> +(define-minor-mode find-function-mode
> + "Enable some key bindings for the `find-function' family of functions."
> + :global t :lighter nil ; compat. with old `find-function-setup-keys'
> + :group 'find-function :version "31.1")
> +
> ;;;###autoload
> (defun find-function-setup-keys ()
> - "Define some key bindings for the `find-function' family of functions."
> - (define-key ctl-x-map "F" 'find-function)
> - (define-key ctl-x-4-map "F" 'find-function-other-window)
> - (define-key ctl-x-5-map "F" 'find-function-other-frame)
> - (define-key ctl-x-map "K" 'find-function-on-key)
> - (define-key ctl-x-4-map "K" 'find-function-on-key-other-window)
> - (define-key ctl-x-5-map "K" 'find-function-on-key-other-frame)
> - (define-key ctl-x-map "V" 'find-variable)
> - (define-key ctl-x-4-map "V" 'find-variable-other-window)
> - (define-key ctl-x-5-map "V" 'find-variable-other-frame)
> - (define-key ctl-x-map "L" 'find-library)
> - (define-key ctl-x-4-map "L" 'find-library-other-window)
> - (define-key ctl-x-5-map "L" 'find-library-other-frame))
> + "Turn on `find-function-mode', which see."
> + (find-function-mode 1))
> +(make-obsolete 'find-function-setup-keys 'find-function-mode "31.1")
>
> (provide 'find-func)
Hmm this changes the precedence of these bindings from low (global map)
to very high (minor mode map). So it's actually quite a breaking change
for those of us that use find-function-setup-keys and override these
bindings in certain major mode maps :/
How about keeping the behavior of find-function-setup-keys as it was?
We can keep that minor mode too, of course.
Best,
Eshel
next parent reply other threads:[~2024-10-04 9:56 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <172800172214.1813703.15067539931889719779@vcs3.savannah.gnu.org>
[not found] ` <20241004002843.024A41867DE@vcs3.savannah.gnu.org>
2024-10-04 9:56 ` Eshel Yaron [this message]
2024-10-04 10:44 ` master c3e989ca9d7: New minor mode find-function-mode replaces find-function-setup-keys Sean Whitton
2024-10-04 11:57 ` Eshel Yaron
2024-10-04 12:47 ` Sean Whitton
2024-10-05 16:56 ` Howard Melman
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=m1ed4wfaym.fsf@dazzs-mbp.home \
--to=me@eshelyaron.com \
--cc=emacs-devel@gnu.org \
--cc=spwhitton@spwhitton.name \
/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).