GNU bug report logs -
#68689
30.0.50; minibuffer-visible-completions should change completion-show-help
Previous Next
Reported by: Spencer Baugh <sbaugh <at> janestreet.com>
Date: Wed, 24 Jan 2024 16:10:01 UTC
Severity: normal
Fixed in version 30.0.50
Done: Juri Linkov <juri <at> linkov.net>
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 68689 in the body.
You can then email your comments to 68689 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#68689
; Package
emacs
.
(Wed, 24 Jan 2024 16:10:01 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Spencer Baugh <sbaugh <at> janestreet.com>
:
New bug report received and forwarded. Copy sent to
bug-gnu-emacs <at> gnu.org
.
(Wed, 24 Jan 2024 16:10:01 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
completion-show-help shows some useful help for new users.
However, it suggests suboptimal bindings when
minibuffer-visible-completions is on. minibuffer-visible-completions
should change the help shown by completion-show-help.
A patch to do this will follow.
In GNU Emacs 30.0.50 (build 20, x86_64-pc-linux-gnu, X toolkit, cairo
version 1.15.12, Xaw scroll bars) of 2023-12-27 built on
igm-qws-u22796a
Repository revision: b9c0ce0a400f18e1bba4e3491c94994d73ef9405
Repository branch: master
Windowing system distributor 'The X.Org Foundation', version 11.0.12011000
System Description: Rocky Linux 8.9 (Green Obsidian)
Configured using:
'configure -C 'CFLAGS=-O0 -g3' --with-gif=ifavailable
--with-x-toolkit=lucid'
Configured features:
CAIRO DBUS FREETYPE GLIB GMP GNUTLS GSETTINGS HARFBUZZ JPEG JSON
LIBSELINUX LIBSYSTEMD LIBXML2 MODULES NOTIFY INOTIFY PDUMPER PNG RSVG
SECCOMP SOUND SQLITE3 THREADS TIFF TOOLKIT_SCROLL_BARS X11 XDBE XIM
XINPUT2 XPM LUCID ZLIB
Important settings:
value of $LANG: en_US.UTF-8
locale-coding-system: utf-8-unix
Major mode: Lisp Interaction
Minor modes in effect:
tooltip-mode: t
global-eldoc-mode: t
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
blink-cursor-mode: t
minibuffer-regexp-mode: t
line-number-mode: t
indent-tabs-mode: t
transient-mark-mode: t
auto-composition-mode: t
auto-encryption-mode: t
auto-compression-mode: t
Load-path shadows:
None found.
Features:
(shadow sort mail-extr emacsbug message mailcap yank-media puny dired
dired-loaddefs rfc822 mml mml-sec password-cache epa derived epg rfc6068
epg-config gnus-util text-property-search time-date subr-x mm-decode
mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader
cl-loaddefs cl-lib sendmail rfc2047 rfc2045 ietf-drums mm-util
mail-prsvr mail-utils rmc iso-transl tooltip cconv eldoc paren electric
uniquify ediff-hook vc-hooks lisp-float-type elisp-mode mwheel
term/x-win x-win term/common-win x-dnd touch-screen 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 nadvice seq simple cl-generic
indonesian philippine 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 abbrev obarray oclosure cl-preloaded button loaddefs
theme-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
dynamic-setting system-font-setting font-render-setting cairo x-toolkit
xinput2 x multi-tty move-toolbar make-network-process emacs)
Memory information:
((conses 16 64909 12153) (symbols 48 9546 0) (strings 32 22818 1610)
(string-bytes 1 676937) (vectors 16 10394)
(vector-slots 8 158028 13136) (floats 8 40 19) (intervals 56 262 0)
(buffers 984 10))
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#68689
; Package
emacs
.
(Wed, 24 Jan 2024 16:12:02 GMT)
Full text and
rfc822 format available.
Message #8 received at 68689 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Patch to fix
[0001-Update-minibuffer-show-help-based-on-minibuffer-visi.patch (text/x-patch, inline)]
From c70736c52262cacb905ed1e564b2335a3c87f5b4 Mon Sep 17 00:00:00 2001
From: Spencer Baugh <sbaugh <at> janestreet.com>
Date: Wed, 24 Jan 2024 11:10:40 -0500
Subject: [PATCH] Update minibuffer-show-help based on
minibuffer-visible-completions
minibuffer-visible-completions makes some more convenient bindings
available, but the help shown by minibuffer-show-help wasn't
suggesting them. Now it is.
* lisp/simple.el (completion-setup-function): Change help text when
minibuffer-visible-completions is non-nil. (bug#68689)
---
lisp/simple.el | 28 +++++++++++++++++++++-------
1 file changed, 21 insertions(+), 7 deletions(-)
diff --git a/lisp/simple.el b/lisp/simple.el
index 35fd76b8d1a..23019dd1138 100644
--- a/lisp/simple.el
+++ b/lisp/simple.el
@@ -10232,13 +10232,27 @@ completion-setup-function
;; Maybe insert help string.
(when completion-show-help
(goto-char (point-min))
- (insert (substitute-command-keys
- (if (display-mouse-p)
- "Click or type \\[minibuffer-choose-completion] on a completion to select it.\n"
- "Type \\[minibuffer-choose-completion] on a completion to select it.\n")))
- (insert (substitute-command-keys
- "Type \\[minibuffer-next-completion] or \\[minibuffer-previous-completion] \
-to move point between completions.\n\n"))))))
+ (if minibuffer-visible-completions
+ (let ((helps
+ (with-current-buffer (window-buffer (active-minibuffer-window))
+ (list
+ (substitute-command-keys
+ (if (display-mouse-p)
+ "Click or type \\[minibuffer-choose-completion-or-exit] on a completion to select it.\n"
+ "Type \\[minibuffer-choose-completion-or-exit] on a completion to select it.\n"))
+ (substitute-command-keys
+ "Type \\[minibuffer-next-completion], \\[minibuffer-previous-completion], \
+\\[minibuffer-next-line-completion], \\[minibuffer-previous-line-completion] \
+to move point between completions.\n\n")))))
+ (dolist (help helps)
+ (insert help)))
+ (insert (substitute-command-keys
+ (if (display-mouse-p)
+ "Click or type \\[minibuffer-choose-completion] on a completion to select it.\n"
+ "Type \\[minibuffer-choose-completion] on a completion to select it.\n")))
+ (insert (substitute-command-keys
+ "Type \\[minibuffer-next-completion] or \\[minibuffer-previous-completion] \
+to move point between completions.\n\n")))))))
(add-hook 'completion-setup-hook #'completion-setup-function)
--
2.39.3
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#68689
; Package
emacs
.
(Wed, 24 Jan 2024 16:51:02 GMT)
Full text and
rfc822 format available.
Message #11 received at 68689 <at> debbugs.gnu.org (full text, mbox):
> completion-show-help shows some useful help for new users.
> However, it suggests suboptimal bindings when
> minibuffer-visible-completions is on. minibuffer-visible-completions
> should change the help shown by completion-show-help.
>
> A patch to do this will follow.
It's hard to see what your patch will output.
Could you please send the outputs of `emacs -Q`
to compare before and after your patch.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#68689
; Package
emacs
.
(Wed, 24 Jan 2024 17:23:02 GMT)
Full text and
rfc822 format available.
Message #14 received at 68689 <at> debbugs.gnu.org (full text, mbox):
Juri Linkov <juri <at> linkov.net> writes:
>> completion-show-help shows some useful help for new users.
>> However, it suggests suboptimal bindings when
>> minibuffer-visible-completions is on. minibuffer-visible-completions
>> should change the help shown by completion-show-help.
>>
>> A patch to do this will follow.
>
> It's hard to see what your patch will output.
> Could you please send the outputs of `emacs -Q`
> to compare before and after your patch.
With minibuffer-visible-completions=nil, there's no change.
With minibuffer-visible-completions=t, before my patch:
Click or type M-RET on a completion to select it.
Type M-<down> or M-<up> to move point between completions.
After my patch:
Click or type RET on a completion to select it.
Type <right>, <left>, <down>, <up> to move point between completions.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#68689
; Package
emacs
.
(Thu, 25 Jan 2024 07:52:02 GMT)
Full text and
rfc822 format available.
Message #17 received at 68689 <at> debbugs.gnu.org (full text, mbox):
close 68689 30.0.50
thanks
> With minibuffer-visible-completions=nil, there's no change.
>
> With minibuffer-visible-completions=t, before my patch:
>
> Click or type M-RET on a completion to select it.
> Type M-<down> or M-<up> to move point between completions.
>
> After my patch:
>
> Click or type RET on a completion to select it.
> Type <right>, <left>, <down>, <up> to move point between completions.
Thanks, this looks nice. Now pushed to master and closed.
bug marked as fixed in version 30.0.50, send any further explanations to
68689 <at> debbugs.gnu.org and Spencer Baugh <sbaugh <at> janestreet.com>
Request was from
Juri Linkov <juri <at> linkov.net>
to
control <at> debbugs.gnu.org
.
(Thu, 25 Jan 2024 07:52:03 GMT)
Full text and
rfc822 format available.
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Thu, 22 Feb 2024 12:24:13 GMT)
Full text and
rfc822 format available.
This bug report was last modified 1 year and 119 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.