GNU bug report logs - #23092
25.0.92; Minibuffer completion fails to resize completion window if reused during same command

Previous Next

Package: emacs;

Reported by: nljlistbox2 <at> gmail.com (N. Jackson)

Date: Tue, 22 Mar 2016 17:09:01 UTC

Severity: minor

Found in version 25.0.92

Done: Juri Linkov <juri <at> jurta.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: martin rudalics <rudalics <at> gmx.at>
To: Eli Zaretskii <eliz <at> gnu.org>, "N. Jackson" <nljlistbox2 <at> gmail.com>
Cc: 23092 <at> debbugs.gnu.org
Subject: bug#23092: 25.0.92; Minibuffer completion fails to resize completion window if reused during same command
Date: Wed, 23 Mar 2016 09:09:05 +0100
>> However, it's interesting that with the recipe reversed, the completions
>> window _does_ get resized.:
>>
>>      src/emacs -Q
>>
>>      C-x C-f            ; find-file
>>      lib/s TAB          ; A largish completions window is shown.
>>      <backspace> v TAB  ; Completions window shrinks.
>>
>> So it seems that the existing implementation has logic in it for
>> resizing the completions window to fit the completions but it just isn't
>> working quite right. Unless the design is that the completions window
>> can only be "shrunk" but not "grown".
>
> I'm sure Martin will be able to explain this ;-)

I never worked in this area but will try to do my best ;-) The behavior
is due to the following form in ‘minibuffer-completion-help’:

	    ,(if temp-buffer-resize-mode
		 '(window-height . resize-temp-buffer-window)
	       '(window-height . shrink-window-if-larger-than-buffer))

The first branch of the ‘if’ means that if ‘temp-buffer-resize-mode’ is
enabled, this function will always try to fit the window to the buffer.
The second branch means that if ‘temp-buffer-resize-mode’ is not
enabled, the window may only shrink to occupy less space.

Obviously, the second branch is based on the assumption that a user will
"refine" her completions in the sense that she starts with a large
number of possible completions and, by typing characters in the
minibuffer, reduces the number of possible completions until she found
the right one.  Apparently, the OP works in the opposite direction - he
starts with few suggestions and removes characters from the minibuffer
ending up with more and more suggestions.

martin





This bug report was last modified 9 years and 63 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.