From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: martin rudalics Newsgroups: gmane.emacs.bugs Subject: bug#55169: Can't combine window-min-height with window-height Date: Sat, 30 Apr 2022 10:03:33 +0200 Message-ID: <9753db0e-05f2-5927-80fb-50d17f16441d@gmx.at> References: <86y1zp5but.fsf@mail.linkov.net> <87czh0gp6m.fsf@gnus.org> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="33490"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 55169@debbugs.gnu.org To: Lars Ingebrigtsen , Juri Linkov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Apr 30 10:07:26 2022 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nki8U-0008ax-4b for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 30 Apr 2022 10:07:26 +0200 Original-Received: from localhost ([::1]:41046 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nki8P-00079N-3R for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 30 Apr 2022 04:07:21 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:45472) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nki5C-00077K-NF for bug-gnu-emacs@gnu.org; Sat, 30 Apr 2022 04:04:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:33679) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nki5C-0000oE-EV for bug-gnu-emacs@gnu.org; Sat, 30 Apr 2022 04:04:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1nki5C-00015w-Az for bug-gnu-emacs@gnu.org; Sat, 30 Apr 2022 04:04:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: martin rudalics Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 30 Apr 2022 08:04:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 55169 X-GNU-PR-Package: emacs Original-Received: via spool by 55169-submit@debbugs.gnu.org id=B55169.16513058244185 (code B ref 55169); Sat, 30 Apr 2022 08:04:02 +0000 Original-Received: (at 55169) by debbugs.gnu.org; 30 Apr 2022 08:03:44 +0000 Original-Received: from localhost ([127.0.0.1]:55809 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nki4t-00015Q-QU for submit@debbugs.gnu.org; Sat, 30 Apr 2022 04:03:44 -0400 Original-Received: from mout.gmx.net ([212.227.15.15]:33659) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nki4r-00015C-Ml for 55169@debbugs.gnu.org; Sat, 30 Apr 2022 04:03:42 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1651305815; bh=GsM9B7yJUkQ2Yy3Hun88V3OotdshVJ13St8fbHwUBnQ=; h=X-UI-Sender-Class:Date:Subject:To:Cc:References:From:In-Reply-To; b=UF6y+nxilU6eMN5tTkKmgRGEayl5F7XasDTaCB03u909+ahqkMHwqgPhtSy3g1tlG ayliQwEOprn2c/ukP9yR+sTKBuurjHd1yS22fRwkkrhjrAFaHY+wXZy1i8IwsvZs8m Pkn26dvamEPowEKUxMppuioda3CG5XWy1GsieKXI= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Original-Received: from [192.168.1.102] ([212.95.5.72]) by mail.gmx.net (mrgmx004 [212.227.17.190]) with ESMTPSA (Nemesis) id 1MDhlV-1nbb8b3pEF-00AnHe; Sat, 30 Apr 2022 10:03:35 +0200 Content-Language: en-US In-Reply-To: <87czh0gp6m.fsf@gnus.org> X-Provags-ID: V03:K1:bTvoMqKrBSQk8NSogJyzROAz6lAwfZYHGxzM01HyN+N3W8amj0J AlAO3OzHV2u0iy8ixOaUNnGBkFtYvy3+L5fX9r3OSo38YGudWqkOzG0S1CV+Y3eXbsCXZaG 8b59FVnTJv7gYAqla5jLR0ZLaAd5m0u+p6VEIpoHTFiuDZ6M2sLWpsPLaNkph+KC249gAZP jegyNVXymcovXGIbZ1jRg== X-UI-Out-Filterresults: notjunk:1;V03:K0:mmf4nUlQL0Q=:MCFMAK1ZMkIEVFBQaJIwfA fI5dRmpDNUhkuR3u3jtyIgx/Jeo/6OTKoas1C5eQPVG9ArlsJG103pVONed8B56EGdlZNSRJy sTD0yXbY3v/i2UlAwUjELAM0A/v9bV1q/CiIu2E+BkBBdqjYTDcy1qVZmNL3A2t51T6KalZfs gGKB5EtrRRrrFjcFt/jAUFYlrqfEG2V+xjsKdtbpcwdBh+Q82kFMo+83EydVqEqYFLYMtnkU4 vCQb9SOajVLoHyA76ERX1HeL8C7egkma/EPHeI8ZDzThAoLege7WMWIEFZXf7+2KyhTdcw/3L GO66YdH8TB3L5weHQICGd2yMFCzCZ6aiETBQTytybF0JQJRAAmLlfOJPoBrbZiHVAmBdnZjRQ pYvT3o22Of6c1dGFQdYXjvpJRyt5XLXKgEXnXYSF+zsIyXMOy0QmTG7HqhGOuFYgzvUr0xlvJ lu1XZeui8gugRiL3JmpchtZ58I80RI3Kie4uk+gmu19of3gYb0yBLNI4XR3wQK5r4CMeHeT2Q GjGVwX67Rt15Rr6KYm+wYe47dlQJ8As9PYbZnpX7I0OvkvJKQAan56mKpcahqGYoEaIIQGxt/ KpTiA2H6nRrV+2U8TS8i2JaSnqUK+1O9zzrA3UugrTW6FCQLBesdh9/qkCNgH8e3S4G9FLn8F TzHYDpPteWc4loGHA3Qpnr1Te+A3HneYbVZylkl52b8rSv8ZKnvV6wrEJcFupCJTYRaWAZY7Z 7cHHjuzk3ieOFGKud8EZBDPj4oRDYIZvnCdtjF350BFAY7M3qRg1/vNN5LHvDHUw7UV8Pz0H X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:230997 Archived-At: > I'd expect that to work as you describe (or perhaps with the alist in > opposite order), and it doesn't. Perhaps Martin has some comments; > added to the CCs. 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. martin