[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Drawing dirty rectangles with expose_window: row->clip = fr
From: |
Keith David Bershatsky |
Subject: |
Re: Drawing dirty rectangles with expose_window: row->clip = fr |
Date: |
Tue, 02 Apr 2019 09:27:44 -0700 |
Thank you, Eli, for reviewing/responding to this particular thread.
In this example, there is one frame with two windows in a top/bottom equal
split. The top window (*scratch*) does not have any fake cursors. The bottom
window (*MC-TEST*) does have fake cursors. It appears that expose_window is
drawing the mode-line of the top window, and the rectangle extends down into
the first line of the bottom window that has fake cursors. The fake cursors
draw on the first line of the bottom window, but the glyphs do not draw on top
of the box/hollow cursors. This happens at the section of expose_window where
it has the comment:
/* Display the mode line if there is one. */
B. expose_window (#<window 3 on *scratch*>): vpos (3)
fr->x (0) | fr->y (258) | fr->width (595) | fr->height (16)
r.x (0) | r.y (256) | r.width (591) | r.height (16)
mc_ns_draw_window_cursor (#<window 6 on *MC-TEST*>):
x (42) | fx (52) | y (0) | fy (274) | hpos (6) | vpos (0)
wd (7) | h (16) | RGB (1.000000/0.000000/0.270588)
cursor_type (FRAMED_BOX_CURSOR) | glyph_flavor (MC_GLYPH)
mc_ns_draw_window_cursor (#<window 6 on *MC-TEST*>):
x (35) | fx (45) | y (0) | fy (274) | hpos (5) | vpos (0)
wd (3) | h (16) | RGB (0.000000/1.000000/1.000000)
cursor_type (BAR_CURSOR) | glyph_flavor (MC_GLYPH)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
> Date: [04-02-2019 07:48:11] <02 Apr 2019 17:48:11 +0300>
> From: Eli Zaretskii <address@hidden>
> To: Keith David Bershatsky <address@hidden>
> CC: address@hidden
> Subject: Re: Drawing dirty rectangles with expose_window: row->clip = fr
>
> > Date: Mon, 01 Apr 2019 18:55:46 -0700
> > From: Keith David Bershatsky <address@hidden>
> >
> > Even though ns_clip_to_rect returns TRUE, "row->clip = fr;" in
> > expose_window can sometimes prevent glyphs from being drawn within the
> > rectangle that is passed as an argument of ns_clip_to_rect. This has the
> > effect of permitting fake cursors to be drawn, but then glyphs cannot be
> > drawn on top of hollow/box fake cursors.
> >
> > How can I reconcile a false_positive with ns_clip_to_rect?
>
> Is the fake cursor entirely inside the rectangle described by 'fr', or
> is it or some of its parts outside?
>
> > Or, perhaps "row->clip = fr;" in expose_window needs to be adjusted to
> > permit the drawing of glyphs?
>
> It already is, AFAIU. Barring bugs, that is.