From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: martin rudalics Newsgroups: gmane.emacs.bugs Subject: bug#38181: Actual height of mode-line not taken into account Date: Sat, 16 Nov 2019 09:57:40 +0100 Message-ID: References: <87eeyd3ul0.fsf@bernoul.li> <83d0dt2qt6.fsf@gnu.org> <83r2290w24.fsf@gnu.org> <83pnhs6wwp.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="32692"; mail-complaints-to="usenet@blaine.gmane.org" Cc: jonas@bernoul.li, 38181@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sat Nov 16 09:58:30 2019 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1iVtuV-0008L4-Hh for geb-bug-gnu-emacs@m.gmane.org; Sat, 16 Nov 2019 09:58:27 +0100 Original-Received: from localhost ([::1]:46952 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iVtuT-0007k4-ND for geb-bug-gnu-emacs@m.gmane.org; Sat, 16 Nov 2019 03:58:25 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:58232) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iVtu7-0007jx-N6 for bug-gnu-emacs@gnu.org; Sat, 16 Nov 2019 03:58:04 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1iVtu6-0008FB-Nb for bug-gnu-emacs@gnu.org; Sat, 16 Nov 2019 03:58:03 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:57133) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1iVtu6-0008Ey-KT for bug-gnu-emacs@gnu.org; Sat, 16 Nov 2019 03:58:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1iVtu6-0000n9-I4 for bug-gnu-emacs@gnu.org; Sat, 16 Nov 2019 03:58:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: martin rudalics Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 16 Nov 2019 08:58:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 38181 X-GNU-PR-Package: emacs Original-Received: via spool by 38181-submit@debbugs.gnu.org id=B38181.15738946763030 (code B ref 38181); Sat, 16 Nov 2019 08:58:02 +0000 Original-Received: (at 38181) by debbugs.gnu.org; 16 Nov 2019 08:57:56 +0000 Original-Received: from localhost ([127.0.0.1]:37721 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iVttz-0000mn-Qw for submit@debbugs.gnu.org; Sat, 16 Nov 2019 03:57:56 -0500 Original-Received: from mout.gmx.net ([212.227.15.19]:57461) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iVttx-0000mY-1Z for 38181@debbugs.gnu.org; Sat, 16 Nov 2019 03:57:53 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1573894663; bh=ZDyP8/kJGGcgr/GIyULQ1l2OEN9h5Ui9CZl4p3DPvDI=; h=X-UI-Sender-Class:Subject:To:Cc:References:From:Date:In-Reply-To; b=KBxOnJYBLPDryoGwHBdPced2hCRQP2BOrlzbrHmgTNMNnn+F+tAca2cecniB+3pKq X5SZWhzD4SmDaP0PYs8w1JJ3zCEHSXs1BPvnjQvdN9xwEx9GCxet4hBAR4K24X6HUV UbysBLRvVSCDx0MIOv/c5p8xHVn9Z2JMExVlGfXw= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Original-Received: from [192.168.1.104] ([46.125.249.58]) by mail.gmx.com (mrgmx004 [212.227.17.190]) with ESMTPSA (Nemesis) id 1McpJg-1hw0ur01AI-00Zxlm; Sat, 16 Nov 2019 09:57:43 +0100 In-Reply-To: <83pnhs6wwp.fsf@gnu.org> Content-Language: de-AT X-Provags-ID: V03:K1:nt9tB0kuFblBiPLFis/euTam/CUoxZ034W7NdHqqLlNZF0SDXJQ +IIPIEMEhWA5cb1VOoQmqYUgmOG2qPTlxy2IbUmSXFHgGeYkbhExkWMJLzenOdKNAGLrAtO tPmivQHsQCxwBIfgQlB/dtNsA5YLC4VnC40Dq2L56ces3bHayqAcjNgJfIydQjW9qmN0DWc AR8beOZzc0ls3fQsuVSTQ== X-UI-Out-Filterresults: notjunk:1;V03:K0:Fa02vbCNyRk=:gO14rdj9vnoNYal2DbSIrI GvOiiwQVU0R2ZOwat8xwhRRR0Ua+n2PoZIxZDA9DqV9D3FkgFeq5n0jS/3Jnl1ifD1dQX98e0 tVZhzvorzLqdt+3m2bZR60Su0mFIPwt2SE63vaAjt8JqIJg4EeV1HhHLdJPPysXXYZ3tstNUU Iu53J3Vc+etaU3/zjy4aOAi9BjTuxJA04heQW3Oi/eIzAHgr5L0qnQCW7CmblQl67MALAn3/y /dI3AvCuObaKwP/ByXv2Gi9YQ/zlFLKls1hdGFeKxDDlwaBqT4ToiLzTZoo32WEJaLmH/vd4E kFBTM6gDTBpn1gkAFkX0gnZh4UtCU6Wue4W4DtlF/nBokAx6UV+1nBZQFTtSr9Hvj00MfI1U3 wcVs0kAFt7+UzNCusGHhIrKlV+MGDtgmPWB+OLA8mk2eyj/qx+A4VZ/pNrKlFb7W4iTBKijpe wpeBsce5OMXeJ51SCPG/aWcdX457WMbPsQSrp2bkFfCuZrbwC4EXTDbaqY5Ee/w4+lsutGWI5 ZTKbMcPnzzNzZbFkVF5oSerqy34iGlA8AdIK4UiXvneqggnekjHPSL2S3nVO2yeQWmxBoofry jgpY8w+qjPopHfMmg2CFlQc1n40/JMxG5TLWRogsPy6ghJCKucunfwxJt/cp33rEVlPm7sizx /nVy8Rt80tTVXSb2yJeCi1pd86G4rW1PjpuFk0CW97gfhgqwvy0a9pAkuELU0z6oEBQtcqYgs RNRx2RqIJwStEiT+X7Hs4WVqweuvfRTvZswDmQ2kIFLVfYUZ8OJB/ZqAOxnUOM71/Mm+0uKR X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 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.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:171712 Archived-At: >> > I think fit-window-to-buffer relies on window's metrics (like the >> > number of lines in the text area) to be up to date, and that is only >> > true after a window was redisplayed once since changing the mode-line >> > height. Martin, is this correct? >> >> Yes. > > Then I'm not sure we can fix such use cases at all, without causing > display flickering in much more popular use cases. Do you have any > ideas for a possible fix? Could fit-window-to-buffer invoke > 'redisplay' internally, perhaps? It could but it's called way too often to warrant such behavior by default. But we could give it a separate optional argument so users can avoid the advice. I think Jonas could easily write and a test a patch along this idea. >> But, as I mentioned earlier, the problem shows up with the >> scroll bar immediately when Jonas' form is evaluated, see the attached >> screenshot. > > That just means we (or a Lisp program which makes these mode-line > modifications) need to recreate and redisplay the scroll bars anew in > these cases, right? Right. But that same program could also redisplay all windows in these cases, right? > It's a separate problem, right? For some value of right ... martin