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


View this message in rfc822 format

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: bug#55169: Can't combine window-min-height with window-height
Date: Wed, 11 May 2022 10:21:19 +0300
>> It would be nice to add just a small example of a lambda with more args
>> for fit-window-to-buffer or shrink-window-if-larger-than-buffer.
>
> Maybe show the code you intend to use and how the user could override it
> with 'shrink-window-if-larger-than-buffer' in 'display-buffer-alist'.

I have an example only for 'fit-window-to-buffer':

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

>>>> BTW, fit-window-to-buffer has also other arguments: MAX-WIDTH and MIN-WIDTH.
>>>> Would they be useful for a window-width entry?
>>>
>>> Maybe.  But let's talk about MAX-HEIGHT first.
>>
>> Maybe MAX-WIDTH is not needed after all, as much as MAX-HEIGHT.
>
> Currently, we don't have to bother anyway.  The only client of this is
> 'display-buffer-below-selected' and that hardly produces a horizontal
> combination.

I wonder why other 'display-buffer-*' function wouldn't need the same?




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

Previous Next


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