From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Keith David Bershatsky Newsgroups: gmane.emacs.devel Subject: Re: Drawing dirty rectangles with expose_window: row->clip = fr Date: Tue, 02 Apr 2019 09:27:44 -0700 Message-ID: Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="217371"; mail-complaints-to="usenet@blaine.gmane.org" Cc: emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Apr 02 18:37:51 2019 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hBMQ1-000uQG-FO for ged-emacs-devel@m.gmane.org; Tue, 02 Apr 2019 18:37:49 +0200 Original-Received: from localhost ([127.0.0.1]:53499 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hBMQ0-0006T7-Bb for ged-emacs-devel@m.gmane.org; Tue, 02 Apr 2019 12:37:48 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:39164) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hBMPk-0006Pe-IX for emacs-devel@gnu.org; Tue, 02 Apr 2019 12:37:33 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hBMGU-0001Gj-My for emacs-devel@gnu.org; Tue, 02 Apr 2019 12:27:59 -0400 Original-Received: from gateway34.websitewelcome.com ([192.185.148.204]:45634) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1hBMGU-0001AJ-6V for emacs-devel@gnu.org; Tue, 02 Apr 2019 12:27:58 -0400 Original-Received: from cm16.websitewelcome.com (cm16.websitewelcome.com [100.42.49.19]) by gateway34.websitewelcome.com (Postfix) with ESMTP id 307415284C for ; Tue, 2 Apr 2019 11:27:46 -0500 (CDT) Original-Received: from gator3053.hostgator.com ([50.87.144.69]) by cmsmtp with SMTP id BMGHhOPbS4FKpBMGHhuOYx; Tue, 02 Apr 2019 11:27:46 -0500 X-Authority-Reason: nr=8 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lawlist.com ; s=default; h=Content-Type:MIME-Version:Subject:Cc:To:From:Message-ID:Date: Sender:Reply-To:Content-Transfer-Encoding:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: In-Reply-To:References:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=u+NkogqwTh5bxm95yO7e43pKjvBGTPzaUo7i232mEtg=; b=VSpIxZfq2NsxSTKlaEYosglQWL IEgwxz40rOuGdk7HajwXyAiZGcFSLsMiCbAZzo0cou9sblJBE3uW/j9vwTnl5KfqtKlRpDuxTk0AO ei2HJP3uz6yTYCOmcOwn0O9rfHBOpxAMIMn0DKiDNObMAvqgkSGV/IhbfQ5SbJlz5QWDMBKjEFN3B 1nx1trxqA6PQyQJzx2t1i1SFCsUctKZrVNCneaWVihu23YUhbdYvHr/YFr7kiiVAGB1mBfi5x4JUv J4nQCmnkrpKZHkRT4r1yLFUvA5yWxqEAI9KBLKWo3ZtJXn0qgiVpMxCv8iei2WRco/QAVUqos1j8J nPxY9tyA==; Original-Received: from cpe-45-48-239-195.socal.res.rr.com ([45.48.239.195]:49879 helo=server.local) by gator3053.hostgator.com with esmtpsa (TLSv1:DHE-RSA-AES256-SHA:256) (Exim 4.91) (envelope-from ) id 1hBMGH-000ktA-8t; Tue, 02 Apr 2019 11:27:45 -0500 X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - gator3053.hostgator.com X-AntiAbuse: Original Domain - gnu.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - lawlist.com X-BWhitelist: no X-Source-IP: 45.48.239.195 X-Source-L: No X-Exim-ID: 1hBMGH-000ktA-8t X-Source-Sender: cpe-45-48-239-195.socal.res.rr.com (server.local) [45.48.239.195]:49879 X-Source-Auth: lawlist X-Email-Count: 1 X-Source-Cap: bGF3bGlzdDtsYXdsaXN0O2dhdG9yMzA1My5ob3N0Z2F0b3IuY29t X-Local-Domain: yes X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 192.185.148.204 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:234876 Archived-At: 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 (#): 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 (#): 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 (#): 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 > To: Keith David Bershatsky > CC: emacs-devel@gnu.org > Subject: Re: Drawing dirty rectangles with expose_window: row->clip = fr > > > Date: Mon, 01 Apr 2019 18:55:46 -0700 > > From: Keith David Bershatsky > > > > 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.