From: Keith David Bershatsky <esq@lawlist.com>
To: Alan Third <alan@idiocy.org>
Cc: Eli Zaretskii <eliz@gnu.org>, emacs-devel@gnu.org
Subject: Re: Drawing dirty rectangles with expose_window: row->clip = fr
Date: Tue, 02 Apr 2019 13:42:11 -0700 [thread overview]
Message-ID: <m2sgv06sws.wl%esq@lawlist.com> (raw)
Thank you, Alan, for reviewing this particular thread.
1. update_window: Call to ns_clip_to_rect is FALSE.
2. expose_window: Call to ns_clip_to_rect is TRUE.
3. expose_window: Call to ns_clip_to_rect is TRUE.
I believe step three (3) is where the fake cursor (box/hollow family) is drawn, and where "row->clip = fr" in expose_window prevents the glyph from being drawn on top of the newly laid fake cursor. If everything in the core of Emacs is working as it should, then I probably need to come up with a new test to determine whether a glyph can/should be drawn in this situation. However, I have not yet figured out what kind of a test is needed here.
LEGEND:
"fr->x/y/width/height": This is the incoming XRectangle value of expose_window.
"r.x/y/width/height": This is the incoming XRectangle value of expose_line.
"fx/fy/wd/h": These are the NSRect dimensions of the fake box/hollow family cursor, which appears on the first line of the bottom window in a split frame with equal size top/bottom windows).
STDERR MESSAGES:
redisplay_internal 0
0x11602fd60 (*MC-TEST*): same window start
0x11602fd60 (*MC-TEST*): 1
update_window (#<window 6 on *MC-TEST*>)
mc_draw_row (#<window 6 on *MC-TEST*>): vpos (0) | hpos (0) | len (16)
mc_ns_draw_window_cursor (#<window 6 on *MC-TEST*>): ns_clip_to_rect (FALSE)
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)
expose_frame (2, 274, 591, 272)
expose_window (2, 274, 591, 272)
A. expose_window (#<window 6 on *MC-TEST*>): vpos (0)
fr->x (2) | fr->y (274) | fr->width (591) | fr->height (272)
r.x (0) | r.y (0) | r.width (591) | r.height (272)
[expose_line]
expose_area (0): start_x (0) | start_hpos (0) | end_hpos (16)
mc_ns_draw_window_cursor (#<window 6 on *MC-TEST*>): ns_clip_to_rect (TRUE)
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)
expose_frame (0, 258, 595, 16)
expose_window (2, 274, 591, 0)
A. expose_window (#<window 6 on *MC-TEST*>): vpos (0)
fr->x (0) | fr->y (258) | fr->width (595) | fr->height (16)
r.x (0) | r.y (0) | r.width (591) | r.height (0)
[expose_line]
expose_area (0): start_x (0) | start_hpos (0) | end_hpos (16)
mc_ns_draw_window_cursor (#<window 6 on *MC-TEST*>): ns_clip_to_rect (TRUE)
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)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
> Date: [04-02-2019 12:34:21] <2 Apr 2019 20:34:21 +0100>
> From: Alan Third <alan@idiocy.org>
> To: Keith David Bershatsky <esq@lawlist.com>
> Cc: Emacs Devel <emacs-devel@gnu.org>
> Subject: Re: Drawing dirty rectangles with expose_window: row->clip = fr
>
> On Mon, Apr 01, 2019 at 06:55:46PM -0700, Keith David Bershatsky wrote:
> >
> > How can I reconcile a false_positive with ns_clip_to_rect?
>
> Has ns_clip_to_rect already been called on the same rectangle with a
> false result? That false result tells Cocoa to include that area in
> the available clipping area in drawRect:.
>
> --
> Alan Third
next reply other threads:[~2019-04-02 20:42 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-04-02 20:42 Keith David Bershatsky [this message]
-- strict thread matches above, loose matches on Subject: below --
2019-04-03 19:28 Drawing dirty rectangles with expose_window: row->clip = fr Keith David Bershatsky
2019-04-02 17:42 Keith David Bershatsky
2019-04-02 16:27 Keith David Bershatsky
2019-04-02 16:51 ` Eli Zaretskii
2019-04-02 1:55 Keith David Bershatsky
2019-04-02 14:48 ` Eli Zaretskii
2019-04-02 19:34 ` Alan Third
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
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=m2sgv06sws.wl%esq@lawlist.com \
--to=esq@lawlist.com \
--cc=alan@idiocy.org \
--cc=eliz@gnu.org \
--cc=emacs-devel@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 public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).