Subject: Re: bug#38181: Actual height of mode-line not taken into account

From: Eli Zaretskii <[email-masked]>
Date: Mon, 18 Nov 2019 17:46:19 +0200

> Cc: [email-masked], [email-masked]
> From: martin rudalics <[email-masked]>
> Date: Mon, 18 Nov 2019 10:45:13 +0100
> 
>  >>   > Mmm... actually, it could be that we cannot resize windows during
>  >>   > redisplay at all.  See, for example, how resize_mini_window does its
>  >>   > tricky job.  We may need to call this outside of redisplay.
>  >>
>  >> Inherently, resize_mini_window does what 'fit-window-to-buffer' does
>  >> and it gets called from redisplay_internal.
>  >
>  > And it immediately returns if that happens while redisplaying a
>  > window.
> 
> But IIUC in neither of our proposals we would have done that.

I wouldn't be so sure: the code fragment I've shown that detects
mode-line height changes is inside redisplay_window.

> I'd even say that we should resize windows when redisplay finds out
> that the mode line height has been increased and would obscure the
> window above, not leave at least one line of its window's text
> visible

Some might dislike such side effects, I think, for the same reason
some dislike the resizing which happens due to mini-window growth.