|Date:||Sat, 19 Sep 2020 15:55:36 +0000|
|User-agent:||Alpine 2.22 (NEB 394 2020-01-19)|
Alas an estimate is not enough in this case. As Ergus just wrote, if there are too many candidates the prompt disappears, leaving the cursor at the beginning of the minibuffer, which is counterintuitive. A simple example: after (setq max-mini-window-height 1), with "M-x a" the "M-x" prompt and the "a" disappear.That can (and should) be fixed without having to reduce the number of candidates inserted in the (mini)buffer.
But how? What should the algorithm be? Put a too long list of candidates in the minibuffer, redisplay, check if the resulting height is larger than then available height (with window-text-pixel-size?), if so remove a candidate, redisplay, ...? Hmmm, no, you just wrote "without having to reduce the number of candidates inserted in the (mini)buffer", so it must be something else?
|[Prev in Thread]||Current Thread||[Next in Thread]|