all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: martin rudalics <rudalics@gmx.at>
To: Eli Zaretskii <eliz@gnu.org>
Cc: 38828@debbugs.gnu.org
Subject: bug#38828: 26.3; Customized mode line breaks height of vertical scroll bar
Date: Thu, 2 Jan 2020 20:19:05 +0100	[thread overview]
Message-ID: <bf7e1bed-a33f-4770-07e1-8f9afeb8f067@gmx.at> (raw)
In-Reply-To: <8336cyj66m.fsf@gnu.org>

 >> window.c doesn't use it.  It's used in xdisp.c only.  And I'm sure it
 >> can return negative values, sometimes.  So I presume we can do away
 >> with it then?
 >
 > I think we could.  But I'd rather not do that on the emacs-27 branch,
 > not unless we find situations where it actually causes bugs.

Agreed.  I'd be more interested anyway in (1) getting the

ml_row && ml_row->mode_line_p

check into CURRENT_MODE_LINE_HEIGHT (if that makes sense) so we could
use CURRENT_MODE_LINE_HEIGHT everywhere (maybe without its embedded
assignment) and (2) improve and (remove from there) the

&& WINDOW_PIXEL_HEIGHT (w) > WINDOW_FRAME_LINE_HEIGHT (w));

check from window_wants_mode_line to use the latest calculated mode
line height instead.  I'd like to reserve one bit for each window's
scroll bars, margins, fringes, mode lines whether they would fit into
the window and suppress their display if they don't.  This would mean
that one can easily shrink a window to some bare minimum, maybe even
to zero height/width.

 > There's more than one problem here (didn't you wonder why pressing F3
 > doesn't immediately redraw the mode line?).

It never did that unless I changed the size of some window too, so why
should I have wondered?

 > A more thorough patch is
 > below.

It's a pleasant experience now.  How expensive is watching a variable?
So far I was convinced this would be used for debugging purposes only.

 > The dispnew.c part is semi-cleanup: it isn't strictly needed
 > after the changes in window_box_height, although originally that flag
 > not being reset upon window resizing was exactly the root cause for
 > the problem after "F2 up".  But I don't like the idea of this flag
 > remaining set, even if no one should be looking at it.  Hmm... maybe I
 > should reset the flag even if we did reallocate current_matrix...

What does "resizing a window without allocating new rows" encompass?
Is this only shrinking the window height ('shrink-/split-window') or
also making a special line like the mode line taller (eating away some
of the remaining matrix lines, naively spoken)?

martin





  reply	other threads:[~2020-01-02 19:19 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-12-31  9:57 bug#38828: 26.3; Customized mode line breaks height of vertical scroll bar martin rudalics
2019-12-31 16:05 ` martin rudalics
2020-01-01 16:10 ` Eli Zaretskii
2020-01-01 17:49   ` martin rudalics
2020-01-02 14:15     ` Eli Zaretskii
2020-01-02 19:19       ` martin rudalics [this message]
2020-01-02 19:58         ` Eli Zaretskii
2020-01-03  7:31           ` Eli Zaretskii
2020-01-03  9:38           ` martin rudalics
2020-01-03 10:19             ` Eli Zaretskii
2020-01-03 10:43               ` martin rudalics
2020-01-03 13:07                 ` Eli Zaretskii
2020-01-03 15:57                   ` martin rudalics
2020-01-03 16:08                     ` Eli Zaretskii
2020-01-03 16:34                       ` martin rudalics
2020-01-03 17:11                         ` Eli Zaretskii
2020-01-03 16:30                     ` Eli Zaretskii
2020-01-03 17:16                       ` martin rudalics
2020-01-04 19:36                       ` Amin Bandali
2020-01-04 19:43                         ` Eli Zaretskii
2020-01-04 20:25                           ` Amin Bandali

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

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

  git send-email \
    --in-reply-to=bf7e1bed-a33f-4770-07e1-8f9afeb8f067@gmx.at \
    --to=rudalics@gmx.at \
    --cc=38828@debbugs.gnu.org \
    --cc=eliz@gnu.org \
    /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 external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.