unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Juri Linkov <juri@linkov.net>
To: martin rudalics <rudalics@gmx.at>
Cc: Lars Ingebrigtsen <larsi@gnus.org>, 55169@debbugs.gnu.org
Subject: bug#55169: Can't combine window-min-height with window-height
Date: Sun, 01 May 2022 20:06:04 +0300	[thread overview]
Message-ID: <86czgxi3nn.fsf@mail.linkov.net> (raw)
In-Reply-To: <9753db0e-05f2-5927-80fb-50d17f16441d@gmx.at> (martin rudalics's message of "Sat, 30 Apr 2022 10:03:33 +0200")

> Ideally, a 'window-min-height' entry should be applied when an existing
> window is used via 'display-buffer-use-some-window'.  Just that in such
> case we (i) don't even look at that entry and (ii) we would not apply a
> 'window-height' entry in the first place because that one is only used
> for new windows or windows that always showed one and the same buffer.
>
> Now
>
>>> 1. first set window-height with fit-window-to-buffer;
>>> 2. then check if the constraint of window-min-height is fulfilled,
>>>     and shrink too high window.
>
> is in general non-trivial because "1." constitutes a fait accompli: We
> need a _real_ window to calculate its desired size and whether it is
> 'window-resizable' to that size.  So we may have to split some window
> first to make "1." work.  But what would we do then if "2." were not
> satisfied?  Restore the frame to a window configuration saved before
> splitting?
>
> Which means that the strategy proposed above would work seamlessly with
> 'display-buffer-reuse-window' only.  But then would we really reject a
> window showing a buffer already only because it's not large enough?
>
> As usual we are caught in between long established conveniences and more
> rigorous guide lines for how 'display-buffer' should behave.

Maybe as a workaround two calls of display-buffer would do the trick?
The first call display-buffer-below-selected will split the window,
then the second call display-buffer-use-some-window will adjust the height.





  reply	other threads:[~2022-05-01 17:06 UTC|newest]

Thread overview: 35+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-04-28 17:58 bug#55169: Can't combine window-min-height with window-height Juri Linkov
2022-04-29 10:27 ` Lars Ingebrigtsen
2022-04-30  8:03   ` martin rudalics
2022-05-01 17:06     ` Juri Linkov [this message]
2022-05-02  7:37       ` martin rudalics
2022-05-02 18:53         ` Juri Linkov
2022-05-03  9:21           ` martin rudalics
2022-05-03 17:38             ` Juri Linkov
2022-05-04  7:54               ` martin rudalics
2022-05-04 19:29                 ` Juri Linkov
2022-05-05  7:47                   ` martin rudalics
2022-05-05  8:03                     ` Juri Linkov
2022-05-05  9:49                       ` martin rudalics
2022-05-05 16:37                         ` Juri Linkov
2022-05-06  7:02                           ` martin rudalics
2022-05-06  7:52                             ` Juri Linkov
2022-05-06 14:10                               ` martin rudalics
2022-05-06 15:34                                 ` Juri Linkov
2022-05-07  7:58                                   ` martin rudalics
2022-05-08 18:18                                     ` Juri Linkov
2022-05-09  7:24                                       ` martin rudalics
2022-05-09  7:38                                         ` martin rudalics
2022-05-09 18:58                                         ` Juri Linkov
2022-05-10  7:41                                           ` martin rudalics
2022-05-11  7:21                                             ` Juri Linkov
2022-05-11  8:19                                               ` martin rudalics
2022-05-12 17:03                                                 ` Juri Linkov
2022-05-13  7:01                                                   ` martin rudalics
2022-05-13 16:58                                                     ` Juri Linkov
2022-05-14  7:49                                                       ` martin rudalics
2022-05-11  9:03                                           ` Richard Stallman
2022-05-12 16:59                                             ` Juri Linkov
2022-05-18 18:20                                         ` Juri Linkov
2022-05-19  7:18                                           ` martin rudalics
2022-05-19 16:27                                             ` Juri Linkov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=86czgxi3nn.fsf@mail.linkov.net \
    --to=juri@linkov.net \
    --cc=55169@debbugs.gnu.org \
    --cc=larsi@gnus.org \
    --cc=rudalics@gmx.at \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).