From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: Change to NS drawing routines Date: Tue, 14 Aug 2018 17:50:08 +0300 Message-ID: <83bma5j93z.fsf@gnu.org> References: <20180811140620.GA1519@breton.holly.idiocy.org> <20180813184659.GA2258@breton.holly.idiocy.org> <83in4ejd5a.fsf@gnu.org> <20180813193604.GB2258@breton.holly.idiocy.org> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Trace: blaine.gmane.org 1534259094 19279 195.159.176.226 (14 Aug 2018 15:04:54 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Tue, 14 Aug 2018 15:04:54 +0000 (UTC) Cc: charles@aurox.ch, emacs-devel@gnu.org To: Alan Third Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Aug 14 17:04:49 2018 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fpasK-0004uv-2V for ged-emacs-devel@m.gmane.org; Tue, 14 Aug 2018 17:04:48 +0200 Original-Received: from localhost ([::1]:44771 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fpauQ-0003MX-KP for ged-emacs-devel@m.gmane.org; Tue, 14 Aug 2018 11:06:58 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:50371) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fpae3-0003j6-9k for emacs-devel@gnu.org; Tue, 14 Aug 2018 10:50:07 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fpadz-0006KM-1W for emacs-devel@gnu.org; Tue, 14 Aug 2018 10:50:03 -0400 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:43777) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fpady-0006KB-TH; Tue, 14 Aug 2018 10:49:58 -0400 Original-Received: from [176.228.60.248] (port=2319 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1fpady-0002Y8-AK; Tue, 14 Aug 2018 10:49:58 -0400 In-reply-to: <20180813193604.GB2258@breton.holly.idiocy.org> (message from Alan Third on Mon, 13 Aug 2018 20:36:04 +0100) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e 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:228525 Archived-At: > Date: Mon, 13 Aug 2018 20:36:04 +0100 > From: Alan Third > Cc: charles@aurox.ch, emacs-devel@gnu.org > > > > from http://lists.gnu.org/archive/html/emacs-devel/2013-04/msg00435.html > > > > > > I can understand the argument to an extent, but I don’t have another > > > solution. > > > > We could discuss this again, perhaps the details have changed, or we > > might be able o find some compromise everybody can live with. > > > > For starters, what changes, if any, would you need to make in the > > glyph matrices, and why? > > For this none, I can do it all in the NS specific code. > > I’ve changed all the NS drawing functions to check whether they are > allowed to draw. If not then I mark the area as dirty. > > I’ve added an ns_flush_display function that I believe is called at > the end of redisplay (flush_frame). I wasn’t sure about this but it > looks as though it works, (i.e. everything draws OK) so I assume it’s > safe. > > Anyway, ns_flush_display asks Cocoa/GNUstep to redraw the frame, which > results in drawRect being called which calls expose_frame on the > rectangles that have been marked as dirty. In that case, I don't see why would I object. My objection was to introducing platform specific stuff into platform-independent code in xdisp.c and dispnew.c, and/or into data structures these files use as part of the display engine. By contrast, it sounds like you just caused the expose event to be triggered under special circumstances, perhaps much more frequently than before, but when exactly the expose event comes in on different window-systems is not something that is against Emacs expectations, and certainly doesn't bother me. Thanks.