GNU bug report logs -
#52074
29.0.50; Add key binding for find-library
Previous Next
Reported by: Manuel Uberti <manuel.uberti <at> inventati.org>
Date: Wed, 24 Nov 2021 06:55:02 UTC
Severity: wishlist
Merged with 51240
Found in versions 27.2, 29.0.50
Fixed in version 29.1
Done: Lars Ingebrigtsen <larsi <at> gnus.org>
Bug is archived. No further changes may be made.
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 52074 in the body.
You can then email your comments to 52074 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#52074
; Package
emacs
.
(Wed, 24 Nov 2021 06:55:02 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Manuel Uberti <manuel.uberti <at> inventati.org>
:
New bug report received and forwarded. Copy sent to
bug-gnu-emacs <at> gnu.org
.
(Wed, 24 Nov 2021 06:55:02 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
Hello everyone,
I was just wondering if to anyone other than me it would make sense to have a
default key binding for find-library. This is something I use regularly to
explore the source code of built-in features and external packages to understand
more about them.
In my init.el, I have this setting:
(keymap-global-set "C-h C-l" #'find-library)
I picked this key binding for mnemonic reasons (h -> help, l -> library) and
because 'C-h C-l' seems to be unbound in emacs -Q.
What do you think?
--
Manuel Uberti
www.manueluberti.eu
In GNU Emacs 29.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.18, cairo
version 1.16.0)
of 2021-11-24 built on hathaway
Repository revision: d112c75f53c690e6f13ec3b340dbc384425bb04d
Repository branch: master
Windowing system distributor 'The X.Org Foundation', version 11.0.12009000
System Description: Ubuntu 20.04 LTS
Configured using:
'configure --with-harfbuzz --with-native-compilation'
Configured features:
ACL CAIRO DBUS FREETYPE GIF GLIB GMP GNUTLS GPM GSETTINGS HARFBUZZ JPEG
JSON LCMS2 LIBOTF LIBSELINUX LIBSYSTEMD LIBXML2 M17N_FLT MODULES
NATIVE_COMP NOTIFY INOTIFY PDUMPER PNG RSVG SECCOMP SOUND THREADS TIFF
TOOLKIT_SCROLL_BARS X11 XDBE XIM XPM GTK3 ZLIB
Important settings:
value of $LC_MONETARY: it_IT.UTF-8
value of $LC_NUMERIC: it_IT.UTF-8
value of $LC_TIME: it_IT.UTF-8
value of $LANG: en_US.UTF-8
value of $XMODIFIERS: @im=ibus
locale-coding-system: utf-8-unix
Major mode: Fundamental
Minor modes in effect:
electric-pair-mode: t
savehist-mode: t
global-so-long-mode: t
global-subword-mode: t
subword-mode: t
windmove-mode: t
winner-mode: t
global-company-mode: t
company-mode: t
envrc-global-mode: t
envrc-mode: t
fido-vertical-mode: t
icomplete-vertical-mode: t
icomplete-mode: t
fido-mode: t
delete-selection-mode: t
tooltip-mode: t
global-eldoc-mode: t
show-paren-mode: t
electric-indent-mode: t
mouse-wheel-mode: t
tool-bar-mode: t
menu-bar-mode: t
file-name-shadow-mode: t
global-font-lock-mode: t
font-lock-mode: t
window-divider-mode: t
auto-composition-mode: t
auto-encryption-mode: t
auto-compression-mode: t
column-number-mode: t
line-number-mode: t
transient-mark-mode: t
Load-path shadows:
/home/manuel/.emacs.d/elpa/transient-0.3.7.0.20211105.10020/transient hides
/usr/local/share/emacs/29.0.50/lisp/transient
Features:
(shadow sort mail-extr emacsbug message yank-media rmc puny rfc822 mml
mml-sec epa derived epg rfc6068 epg-config gnus-util rmail
rmail-loaddefs mm-decode mm-bodies mm-encode mailabbrev gmm-utils
mailheader sendmail mail-utils completion dos-w32 find-cmd grep
find-dired eieio-opt speedbar ezimage dframe shortdoc help-fns
radix-tree hl-line ibuf-ext ibuffer ibuffer-loaddefs add-log log-view
pcvs-util vc-dir ewoc pp vc-git diff-mode vc vc-dispatcher noutline
outline easy-mmode checkdoc lisp-mnt mail-parse rfc2231 rfc2047 rfc2045
mm-util ietf-drums mail-prsvr dired-x dired dired-loaddefs view
elec-pair flymake-proc flymake compile text-property-search comint
flyspell ispell goto-addr jka-compr cursor-sensor thingatpt find-func
time-date modus-vivendi-theme modus-themes delight comp comp-cstr
warnings cl-extra help-mode savehist so-long cap-words superword subword
windmove winner company-oddmuse company-keywords company-etags etags
fileloop generator xref project ring company-gtags company-dabbrev-code
company-dabbrev company-files company-clang company-capf company-cmake
company-semantic company-template company-bbdb company pcase envrc
inheritenv ansi-color icomplete ibuf-macs rx delsel info tex-site
package browse-url url url-proxy url-privacy url-expand url-methods
url-history url-cookie url-domsuf url-util mailcap url-handlers
url-parse auth-source cl-seq eieio eieio-core cl-macs eieio-loaddefs
password-cache json map url-vars seq gv subr-x byte-opt bytecomp
byte-compile cconv cl-loaddefs cl-lib iso-transl tooltip eldoc paren
electric uniquify ediff-hook vc-hooks lisp-float-type elisp-mode mwheel
term/x-win x-win term/common-win x-dnd tool-bar dnd fontset image
regexp-opt fringe tabulated-list replace newcomment text-mode lisp-mode
prog-mode register page tab-bar menu-bar rfn-eshadow isearch easymenu
timer select scroll-bar mouse jit-lock font-lock syntax font-core
term/tty-colors frame minibuffer cl-generic cham georgian utf-8-lang
misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms
cp51932 hebrew greek romanian slovak czech european ethiopic indian
cyrillic chinese composite emoji-zwj charscript charprop case-table
epa-hook jka-cmpr-hook help simple abbrev obarray cl-preloaded nadvice
button loaddefs faces cus-face macroexp files window text-properties
overlay sha1 md5 base64 format env code-pages mule custom widget keymap
hashtable-print-readable backquote threads dbusbind inotify lcms2
dynamic-setting system-font-setting font-render-setting cairo
move-toolbar gtk x-toolkit x multi-tty make-network-process
native-compile emacs)
Memory information:
((conses 16 288911 46166)
(symbols 48 18679 1)
(strings 32 60963 4075)
(string-bytes 1 2148371)
(vectors 16 30316)
(vector-slots 8 561302 16807)
(floats 8 188 703)
(intervals 56 677 0)
(buffers 992 15))
--
Manuel Uberti
www.manueluberti.eu
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#52074
; Package
emacs
.
(Wed, 24 Nov 2021 07:21:02 GMT)
Full text and
rfc822 format available.
Message #8 received at 52074 <at> debbugs.gnu.org (full text, mbox):
Manuel Uberti <manuel.uberti <at> inventati.org> writes:
> I was just wondering if to anyone other than me it would make sense to
> have a default key binding for find-library. This is something I use
> regularly to explore the source code of built-in features and external
> packages to understand more about them.
Yes, it's a useful command, so perhaps we should have a default binding
for it.
> In my init.el, I have this setting:
>
> (keymap-global-set "C-h C-l" #'find-library)
>
> I picked this key binding for mnemonic reasons (h -> help, l ->
> library) and because 'C-h C-l' seems to be unbound in emacs -Q.
Hm... Finding a library isn't exactly a help command, so I think it
would be somewhat confusing to put it there. But I don't have a good
suggestion for where to put otherwise.
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#52074
; Package
emacs
.
(Wed, 24 Nov 2021 07:27:02 GMT)
Full text and
rfc822 format available.
Message #11 received at 52074 <at> debbugs.gnu.org (full text, mbox):
On 24/11/21 08:20, Lars Ingebrigtsen wrote:
> Hm... Finding a library isn't exactly a help command, so I think it
> would be somewhat confusing to put it there. But I don't have a good
> suggestion for where to put otherwise.
You're right. What about using a prefix like C-x 7 and add something like:
- C-x 7 l for find-library
Then these can be considered as well:
- C-x 7 f for find-function
- C-x 7 v for find-variable
--
Manuel Uberti
www.manueluberti.eu
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#52074
; Package
emacs
.
(Wed, 24 Nov 2021 12:02:02 GMT)
Full text and
rfc822 format available.
Message #14 received at 52074 <at> debbugs.gnu.org (full text, mbox):
On 2021-11-24 20:20, Lars Ingebrigtsen wrote:
> Manuel Uberti <manuel.uberti <at> inventati.org> writes:
>> I picked this key binding for mnemonic reasons (h -> help, l ->
>> library) and because 'C-h C-l' seems to be unbound in emacs -Q.
>
> Hm... Finding a library isn't exactly a help command, so I think it
> would be somewhat confusing to put it there. But I don't have a good
> suggestion for where to put otherwise.
Library commentaries are one of the primary sources of documentation
in Emacs, so I think it's pretty help-related.
FWIW I use this same binding, and in my mind it makes excellent sense
to use C-h C-l for `find-library' if you also have:
C-h C-v for `find-variable'
C-h C-f for `find-function'
C-h C-k for `find-function-on-key'
All of which feel (to me) analogous to C-h v, C-h f, and C-h k: Without
the Ctrl modifier you view the docstrings; with it you view the code.
(Admittedly C-h l is unconnected, but that hasn't bothered me.
Following
my pattern that would probably be bound to `finder-commentary', but I'm
not suggesting we move `view-lossage' elsewhere.)
I guess my main point is that I do think of *all* of these things as
help-related, as I consider reading the code as just the next step up
from reading the docstrings.
-Phil
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#52074
; Package
emacs
.
(Wed, 24 Nov 2021 17:17:02 GMT)
Full text and
rfc822 format available.
Message #17 received at 52074 <at> debbugs.gnu.org (full text, mbox):
Manuel Uberti <manuel.uberti <at> inventati.org> writes:
> You're right. What about using a prefix like C-x 7 and add something like:
>
> - C-x 7 l for find-library
>
> Then these can be considered as well:
>
> - C-x 7 f for find-function
> - C-x 7 v for find-variable
Hm... We've got a variety of stuff on `C-x <num>', but mostly things
that deal with windows/tabs/frames. But perhaps it might make sense to
put a `find-*' keymap there.
Phil Sainty <psainty <at> orcon.net.nz> writes:
> FWIW I use this same binding, and in my mind it makes excellent sense
> to use C-h C-l for `find-library' if you also have:
>
> C-h C-v for `find-variable'
> C-h C-f for `find-function'
> C-h C-k for `find-function-on-key'
>
> All of which feel (to me) analogous to C-h v, C-h f, and C-h k: Without
> the Ctrl modifier you view the docstrings; with it you view the code.
Unfortunately `C-h C-f' is taken, but this makes sense.
> (Admittedly C-h l is unconnected, but that hasn't bothered me.
> Following
> my pattern that would probably be bound to `finder-commentary', but I'm
> not suggesting we move `view-lossage' elsewhere.)
>
> I guess my main point is that I do think of *all* of these things as
> help-related, as I consider reading the code as just the next step up
> from reading the docstrings.
That's a good point.
I doubt `C-h C-f' is used that often, so perhaps we could consider
moving it and binding these four find-* commands to the `C-h' map.
Anybody else with opinions or ideas here?
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#52074
; Package
emacs
.
(Wed, 24 Nov 2021 18:22:01 GMT)
Full text and
rfc822 format available.
Message #20 received at 52074 <at> debbugs.gnu.org (full text, mbox):
> I was just wondering if to anyone other than me it would make sense to have
> a default key binding for find-library. This is something I use regularly to
> explore the source code of built-in features and external packages to
> understand more about them.
>
> In my init.el, I have this setting:
> (keymap-global-set "C-h C-l" #'find-library)
>
> I picked this key binding for mnemonic reasons (h -> help, l -> library) and
> because 'C-h C-l' seems to be unbound in emacs -Q.
>
> What do you think?
Yes. See bug #51240. I use `C-x 4 l' for my
`find-library-other-window'. (I almost never
want to switch to the library in the same window.)
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#52074
; Package
emacs
.
(Wed, 24 Nov 2021 18:31:01 GMT)
Full text and
rfc822 format available.
Message #23 received at 52074 <at> debbugs.gnu.org (full text, mbox):
forcemerge 51240 52074
quit
> Anybody else with opinions or ideas here?
This is duplicate of https://debbugs.gnu.org/51240
where both using the C-h keymap or C-x L/C-x 4 L/C-x 5 L
were proposed without a conclusive decision which one to prefer.
Forcibly Merged 51240 52074.
Request was from
Juri Linkov <juri <at> linkov.net>
to
control <at> debbugs.gnu.org
.
(Wed, 24 Nov 2021 18:31:02 GMT)
Full text and
rfc822 format available.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#52074
; Package
emacs
.
(Wed, 24 Nov 2021 18:33:02 GMT)
Full text and
rfc822 format available.
Message #28 received at 52074 <at> debbugs.gnu.org (full text, mbox):
> Yes. See bug #51240.
Even that one was a duplicate of #26712? and #2270.
Those haven't gotten anywhere. But maybe you'll have
better luck... This goes back at least 14 years.
See, for example:
https://debbugs.gnu.org/cgi/bugreport.cgi?bug=26712#8
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#52074
; Package
emacs
.
(Wed, 24 Nov 2021 18:56:02 GMT)
Full text and
rfc822 format available.
Message #31 received at 52074 <at> debbugs.gnu.org (full text, mbox):
> Anybody else with opinions or ideas here?
Yes, and they've been expressed many times, in
the multiple emacs-devel and duplicate bug threads
about this.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#52074
; Package
emacs
.
(Wed, 24 Nov 2021 21:08:01 GMT)
Full text and
rfc822 format available.
Message #34 received at 52074 <at> debbugs.gnu.org (full text, mbox):
[Sending again. Didn't show up in the bug list for some reason.]
> Library commentaries are one of the primary sources of documentation
> in Emacs, so I think it's pretty help-related.
True. But we also have `finder-commentary' for that aspect.
> FWIW I use this same binding, and in my mind it makes excellent sense
> to use C-h C-l for `find-library' if you also have:
>
> C-h C-v for `find-variable'
> C-h C-f for `find-function'
> C-h C-k for `find-function-on-key'
>
> All of which feel (to me) analogous to C-h v, C-h f, and C-h k: Without
> the Ctrl modifier you view the docstrings; with it you view the code.
>
> (Admittedly C-h l is unconnected, but that hasn't bothered me.
> Following
> my pattern that would probably be bound to `finder-commentary', but I'm
> not suggesting we move `view-lossage' elsewhere.)
>
> I guess my main point is that I do think of *all* of these things as
> help-related, as I consider reading the code as just the next step up
> from reading the docstrings.
It's good to discuss this, and I'm glad to see
people giving _reasons_ for proposals/opinions.
I wish that were more often the case.
To my mind `find-library' fits most closely with
`find-file'. I put my `other-window' version on
`C-x 4 l' as analogy to `C-x 4 f'.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#52074
; Package
emacs
.
(Thu, 30 Jun 2022 10:51:02 GMT)
Full text and
rfc822 format available.
Message #37 received at 52074 <at> debbugs.gnu.org (full text, mbox):
Lars Ingebrigtsen <larsi <at> gnus.org> writes:
>> Thanks for the explanation, I think it makes sense to add
>> C-x L, C-x 4 L, C-x 5 L to find-function-setup-keys.
>
> Makes sense to me.
So I've now done this in Emacs 29.
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
bug marked as fixed in version 29.1, send any further explanations to
52074 <at> debbugs.gnu.org and Manuel Uberti <manuel.uberti <at> inventati.org>
Request was from
Lars Ingebrigtsen <larsi <at> gnus.org>
to
control <at> debbugs.gnu.org
.
(Thu, 30 Jun 2022 10:51:02 GMT)
Full text and
rfc822 format available.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#52074
; Package
emacs
.
(Thu, 30 Jun 2022 15:41:01 GMT)
Full text and
rfc822 format available.
Message #42 received at 52074 <at> debbugs.gnu.org (full text, mbox):
> >> Thanks for the explanation, I think it makes sense to add
> >> C-x L, C-x 4 L, C-x 5 L to find-function-setup-keys.
> >
> > Makes sense to me.
>
> So I've now done this in Emacs 29.
Finally.
But as I said in bug #51240, which is a duplicate
of this one:
[Isn't this essentially bug #26712? and 2270? (which
was closed as Done, but with no key binding)]
At least 3 duplicate bugs, + discussion in emacs-devel.
15 years.
It's taken 15 years to get this done, from my initial
proposal to add the -other-window/frame versions, and
my suggestion of `C-x 4 l' and `C-x 5 l' bindings.
Yes, you should have used lowercase `l'. From #26712:
I almost _never_ use `count-lines-page', and I use
`find-library-other-window' several times a day.
And I'm probably one of the few people who actually
does use page commands. That's just not that useful
a command, for me.)
And `find-function-setup-keys' shouldn't hardcode the
keys anyway - it should use a user option.
And this isn't even (at all) about finding a function.
There's no reason to put finding a _library_ on
`find-function-setup-keys'. But I repeat myself...
https://debbugs.gnu.org/cgi/bugreport.cgi?bug=2270
https://debbugs.gnu.org/cgi/bugreport.cgi?bug=26712#8
https://debbugs.gnu.org/cgi/bugreport.cgi?bug=26712#44
https://lists.gnu.org/archive/html/emacs-devel/2007-03/msg01073.html
https://lists.gnu.org/archive/html/emacs-devel/2007-06/msg01306.html
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Fri, 29 Jul 2022 11:24:08 GMT)
Full text and
rfc822 format available.
This bug report was last modified 1 year and 272 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.