unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#24235: 25.1.50; `describe-bindings' request: show `??' definitions
@ 2016-08-15 17:12 Drew Adams
  2019-07-27 15:10 ` Lars Ingebrigtsen
  2021-11-02 15:20 ` Lars Ingebrigtsen
  0 siblings, 2 replies; 6+ messages in thread
From: Drew Adams @ 2016-08-15 17:12 UTC (permalink / raw)
  To: 24235

Enhancement request.  Keys shown by `describe-bindings' and similar
(including `substitute-command-keys' for \{...}) currently show `??' as
their binding if the binding is not a command symbol.

Please turn the `??' occurrences into links that when clicked show the
source code for the key's binding, when available.  If it is
byte-compiled, and the uncompiled code is unknown, show the byte code,
but with control chars filtered out (so somewhat human-readable).

This lets users see what is behind the `??', giving them a somewhat
better idea what the key does.

In GNU Emacs 25.1.50.1 (i686-pc-mingw32)
 of 2015-12-10
Repository revision: 6148555ee5a3d0139ae517803718b3e0357933c7
Windowing system distributor 'Microsoft Corp.', version 6.1.7601
Configured using:
 'configure --prefix=/c/Devel/emacs/snapshot/trunk --enable-checking=yes
 --enable-check-lisp-object-type --without-compress-install 'CFLAGS=-Og
 -ggdb3' LDFLAGS=-Lc:/Devel/emacs/lib 'CPPFLAGS=-DGC_MCHECK=1
 -Ic:/Devel/emacs/include''





^ permalink raw reply	[flat|nested] 6+ messages in thread

* bug#24235: 25.1.50; `describe-bindings' request: show `??' definitions
  2016-08-15 17:12 bug#24235: 25.1.50; `describe-bindings' request: show `??' definitions Drew Adams
@ 2019-07-27 15:10 ` Lars Ingebrigtsen
  2019-07-27 17:18   ` Drew Adams
  2021-11-02 15:20 ` Lars Ingebrigtsen
  1 sibling, 1 reply; 6+ messages in thread
From: Lars Ingebrigtsen @ 2019-07-27 15:10 UTC (permalink / raw)
  To: Drew Adams; +Cc: 24235

Drew Adams <drew.adams@oracle.com> writes:

> Enhancement request.  Keys shown by `describe-bindings' and similar
> (including `substitute-command-keys' for \{...}) currently show `??' as
> their binding if the binding is not a command symbol.
>
> Please turn the `??' occurrences into links that when clicked show the
> source code for the key's binding, when available.  If it is
> byte-compiled, and the uncompiled code is unknown, show the byte code,
> but with control chars filtered out (so somewhat human-readable).
>
> This lets users see what is behind the `??', giving them a somewhat
> better idea what the key does.

The calling sequence for this command is slightly convoluted, but it
turns out that help.el calls basically

  (describe-buffer-bindings buffer nil nil)

which is a C function (but why?) which inserts all the

C-n		next-line
C-o		open-line
C-H-w		??

stuff, which is then post-processed to add the xref links.  So at the
point where the xref is added, then there's no feasible way to determine
what the ?? referred to, really, without redoing the work the C function
had already done...

I think.

Anybody?

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





^ permalink raw reply	[flat|nested] 6+ messages in thread

* bug#24235: 25.1.50; `describe-bindings' request: show `??' definitions
  2019-07-27 15:10 ` Lars Ingebrigtsen
@ 2019-07-27 17:18   ` Drew Adams
  0 siblings, 0 replies; 6+ messages in thread
From: Drew Adams @ 2019-07-27 17:18 UTC (permalink / raw)
  To: Lars Ingebrigtsen; +Cc: 24235

> The calling sequence for this command is slightly convoluted, but it
> turns out that help.el calls basically
>   (describe-buffer-bindings buffer nil nil)
> which is a C function (but why?) which inserts all the
> 
> C-n		next-line
> C-o		open-line
> C-H-w		??
> 
> stuff, which is then post-processed to add the xref links.  So at the
> point where the xref is added, then there's no feasible way to
> determine what the ?? referred to, really, without redoing the work the C
> function had already done...
> 
> I think.
> 
> Anybody?

I don't have a solution suggestion.  But maybe
a start would be to move this from C to Lisp?
(Just a suggestion.  Dunno whether there's a
good reason why it's still in C.)





^ permalink raw reply	[flat|nested] 6+ messages in thread

* bug#24235: 25.1.50; `describe-bindings' request: show `??' definitions
  2016-08-15 17:12 bug#24235: 25.1.50; `describe-bindings' request: show `??' definitions Drew Adams
  2019-07-27 15:10 ` Lars Ingebrigtsen
@ 2021-11-02 15:20 ` Lars Ingebrigtsen
  2021-11-06 18:58   ` Juri Linkov
  1 sibling, 1 reply; 6+ messages in thread
From: Lars Ingebrigtsen @ 2021-11-02 15:20 UTC (permalink / raw)
  To: Drew Adams; +Cc: 24235

Drew Adams <drew.adams@oracle.com> writes:

> Please turn the `??' occurrences into links that when clicked show the
> source code for the key's binding, when available.  If it is
> byte-compiled, and the uncompiled code is unknown, show the byte code,
> but with control chars filtered out (so somewhat human-readable).

This is now fixed in Emacs 29.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





^ permalink raw reply	[flat|nested] 6+ messages in thread

* bug#24235: 25.1.50; `describe-bindings' request: show `??' definitions
  2021-11-02 15:20 ` Lars Ingebrigtsen
@ 2021-11-06 18:58   ` Juri Linkov
  2021-11-06 21:28     ` Lars Ingebrigtsen
  0 siblings, 1 reply; 6+ messages in thread
From: Juri Linkov @ 2021-11-06 18:58 UTC (permalink / raw)
  To: Lars Ingebrigtsen; +Cc: 24235

>> Please turn the `??' occurrences into links that when clicked show the
>> source code for the key's binding, when available.  If it is
>> byte-compiled, and the uncompiled code is unknown, show the byte code,
>> but with control chars filtered out (so somewhat human-readable).
>
> This is now fixed in Emacs 29.

One minor problem is that [closure] and [lambda] buttons
have no 'help-echo' and no 'mouse-face' with 'highlight'
like other buttons in 'C-h b'.





^ permalink raw reply	[flat|nested] 6+ messages in thread

* bug#24235: 25.1.50; `describe-bindings' request: show `??' definitions
  2021-11-06 18:58   ` Juri Linkov
@ 2021-11-06 21:28     ` Lars Ingebrigtsen
  0 siblings, 0 replies; 6+ messages in thread
From: Lars Ingebrigtsen @ 2021-11-06 21:28 UTC (permalink / raw)
  To: Juri Linkov; +Cc: 24235

Juri Linkov <juri@linkov.net> writes:

> One minor problem is that [closure] and [lambda] buttons
> have no 'help-echo' and no 'mouse-face' with 'highlight'
> like other buttons in 'C-h b'.

I've now fixed the mouse-face...  but...  I think we kinda go overboard
on the help-echo stuff: It's a button, so RET/mouse is what works, and I
don't think anybody needs to be told?

But I guess it could say what it's doing of you click on it.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2021-11-06 21:28 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-08-15 17:12 bug#24235: 25.1.50; `describe-bindings' request: show `??' definitions Drew Adams
2019-07-27 15:10 ` Lars Ingebrigtsen
2019-07-27 17:18   ` Drew Adams
2021-11-02 15:20 ` Lars Ingebrigtsen
2021-11-06 18:58   ` Juri Linkov
2021-11-06 21:28     ` Lars Ingebrigtsen

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).