GNU bug report logs - #55169
Can't combine window-min-height with window-height

Previous Next

Package: emacs;

Reported by: Juri Linkov <juri <at> linkov.net>

Date: Thu, 28 Apr 2022 18:04:01 UTC

Severity: normal

Full log


Message #44 received at 55169 <at> debbugs.gnu.org (full text, mbox):

From: Juri Linkov <juri <at> linkov.net>
To: martin rudalics <rudalics <at> gmx.at>
Cc: Lars Ingebrigtsen <larsi <at> gnus.org>, 55169 <at> debbugs.gnu.org
Subject: Re: bug#55169: Can't combine window-min-height with window-height
Date: Thu, 05 May 2022 19:37:25 +0300
>> Also this increases the likelihood of regressions.
>> For example, with your latest patch, *Completions*
>> are no more fit into a small window, e.g.
>> 'C-h f car TAB TAB' pops up too high window.
>
> Likely because the *Completions* window would become smaller than
> 'window-min-height'.  Either decrease that or provide an explicit
> 'window-min-height' alist entry of 0 in the 'display-buffer' call.
>
> It's a can or worms we'd open here.

Do you think it would be simpler and thus more reliable
to enforce height constraints such as min-height
in fit-window-to-buffer?

This will be very clear to users to see how it works:

  (pop-to-buffer (generate-new-buffer "*edit string*")
                 '(display-buffer-below-selected
                   (window-height (fit-window-to-buffer 10))))

where 10 is min-height.

Because it should be the task of fit-window-to-buffer,
and it already has the argument MIN-HEIGHT.
Also other arguments of fit-window-to-buffer
could be allowed to use in display-buffer-alist.




This bug report was last modified 3 years and 28 days ago.

Previous Next


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