GNU bug report logs -
#60411
29.0.60; minibuffer-next-completion skips first candidate when completions-header-format and completion-show-help are nil
Previous Next
Reported by: Knut Anders Hatlen <kahatlen <at> gmail.com>
Date: Thu, 29 Dec 2022 21:26:02 UTC
Severity: normal
Fixed in version 29.0.60
Done: Juri Linkov <juri <at> linkov.net>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
>>>> Stefan and Eli, do you agree with that conclusion?
>>>
>>> I admit that I've lost the line of reasoning here (too much of the
>>> previous context is being elided, forcing me to re-read the entire
>>> discussion). Which code is proposed for the release branch, and how
>>> will Emacs behave with that code in this particular use case?
>>
>> It's this patch. It adds an invisible empty line at the beginning of
>> *Completions* when completions-header-format is not a string (in
>> particular, nil) or an empty string.
>
> What is the significance of these two special values of
> completions-header-format? Is it that you want to test whether the
> first candidates starts at buffer position 1 in the *Completions*
> buffer? Then why not test for that explicitly?
>
When completions-header-format is nil or an empty string, no completion
header "NNN possible completions:\n" is inserted in *Completions*.
Because of this, minibuffer-next-completion (bound to M-<down> by
default), which is supposed to select the first completion when it is
called for the first time, erroneously selects the second completion.
The fact that "something" (the completion header and/or the help text
"Click on a completion to select it...") must exist in *Completions*
before the first completion candidate is more or less hardcoded in the
logic of minibuffer-next-completion.
This bug report was last modified 2 years and 130 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.