From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Alan Third Newsgroups: gmane.emacs.devel Subject: Re: nsterm.m: How to prevent _inactive_ window update from overreaching. Date: Thu, 22 Nov 2018 22:57:20 +0000 Message-ID: <20181122225720.GA23773@breton.holly.idiocy.org> References: 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 1542927362 6229 195.159.176.226 (22 Nov 2018 22:56:02 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Thu, 22 Nov 2018 22:56:02 +0000 (UTC) User-Agent: Mutt/1.10.1 (2018-07-13) Cc: Emacs Devel To: Keith David Bershatsky Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Nov 22 23:55:57 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 1gPxt2-0001QX-M0 for ged-emacs-devel@m.gmane.org; Thu, 22 Nov 2018 23:55:52 +0100 Original-Received: from localhost ([::1]:49639 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gPxv8-00070y-P6 for ged-emacs-devel@m.gmane.org; Thu, 22 Nov 2018 17:58:02 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:46390) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gPxuX-00070i-LR for emacs-devel@gnu.org; Thu, 22 Nov 2018 17:57:26 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gPxuW-000249-Tg for emacs-devel@gnu.org; Thu, 22 Nov 2018 17:57:25 -0500 Original-Received: from mail-wm1-x334.google.com ([2a00:1450:4864:20::334]:52425) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gPxuW-000237-Me for emacs-devel@gnu.org; Thu, 22 Nov 2018 17:57:24 -0500 Original-Received: by mail-wm1-x334.google.com with SMTP id r11-v6so10267754wmb.2 for ; Thu, 22 Nov 2018 14:57:24 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=20161025; h=sender:date:from:to:cc:subject:message-id:references:mime-version :content-disposition:content-transfer-encoding:in-reply-to :user-agent; bh=FoJojxIQhonsZ8OFGVljQmK02dDGdliAOXvNdZsc+88=; b=AU7mwsOhwbTTyY18X+W8oJSZSlF0rldA0HaphzZlgYW6BDEfmnzX8QGLuJIR5piGSL pzlmAfytyqJDNf6CFOE4S37L1FdLsq1wvICarGaEv+iIxCNDbZbL32XPEBSyjJ6ChTWz 1177awrnPLrmavoyF1ZAE9lv/4sVsy5jqgyD3XbtqezsnsdpwHdu94+/dqS3RXqPZKxj 3LiDiaf5+Mddg3fw0ncDM6/hzvPbGnTIffVnDEmpKwwuV8RMqsHKnZC1CvxH8iHtG6+Q uGTHAL7HoPLjV5aortjgpZcQICsdMa7xc+8kg5i/WS0+BVIjwcYuSUrNSrYk9+aHCT0t lFzw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:date:from:to:cc:subject:message-id :references:mime-version:content-disposition :content-transfer-encoding:in-reply-to:user-agent; bh=FoJojxIQhonsZ8OFGVljQmK02dDGdliAOXvNdZsc+88=; b=MQpMarJdq1SYtsr03k0pu7nyEHDM+M00OekflD91rFCjycAUDKArUpu88UffSw2OfR dMf04mF8gpDQbyWH5j3PaDDXq7lRXUHVYGc0SIKnTno+GTEbcZFFEz7Jom2/LgtUz1Wu CiEJ5a1FYrK7ctKXxguuM79kXd+gWBYP13eFsNn6kMY6ZOdxoX+2ePgTQ21MalhKVZOY NB4g8ANWz2kGehFMD4ea5l1HjHRTbD+pFROoG848ZQmntHaB7Mh1X6Pg8q5Ar21y7Ll3 9KC6TIdVU03RYLwZupfLT56NswMX+hJiIYUK8H7vmi0itAddJpBnm7lU9KTL1d0YIQyk uq6g== X-Gm-Message-State: AGRZ1gJrKtRts/lcIGagCCVZCs0KxrL3Xy+47RX2l+ulzhw4CrezEwkP jF8TjKpHwybw/2pu6dnLEow= X-Google-Smtp-Source: AJdET5frZKVz9OAEhmvrFkzdESEwPm9cpIdEtoEtCLCwO0wloSOSLRUGCOcW5BiGePFUivmq3r+R+w== X-Received: by 2002:a1c:b4c1:: with SMTP id d184-v6mr12102452wmf.143.1542927443209; Thu, 22 Nov 2018 14:57:23 -0800 (PST) Original-Received: from breton.holly.idiocy.org (ip6-2001-08b0-03f8-8129-dce1-f8e2-3065-9b77.holly.idiocy.org. [2001:8b0:3f8:8129:dce1:f8e2:3065:9b77]) by smtp.gmail.com with ESMTPSA id f15sm6383442wrt.10.2018.11.22.14.57.22 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 22 Nov 2018 14:57:22 -0800 (PST) Content-Disposition: inline In-Reply-To: X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::334 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:231308 Archived-At: Hi Keith, On Thu, Nov 22, 2018 at 11:07:26AM -0800, Keith David Bershatsky wrote: > In working on feature requests #17684 (crosshairs / visible fill > column) and #22873 (multiple fake cursors), I have come across a > situation where nsterm.m updates a portion of the _active_ window > when updating the _inactive_ window. Although this is the case as of > 11/16/2018, it was not the case back on 07/07/2018. The change > occurred sometime between 07/07/2018 and 11/16/2018. > > In the following examples, the _active_ window on the right gets > updated first in time. Using a version of Emacs from 07/07/2018, > updating the _inactive_ window does not cause the active window to > be modified. Using a version of Emacs from 11/16/2018, updating the > _inactive_ window updates a portion of the _active_ window. The > update happens from the top of the window to the X axis of the > cursor in the _inactive_ window. > > In the 07/07/2018 screenshot, the crosshairs and visible fill column > in the _active_ window are not touched by updates to the _inactive_ > window. > > In the 11/16/2018 screenshot, the crosshairs and visible fill column > in the _active_ window are partially erased by updates to the > _inactive_ window. There are two (potential) issues here: 1. Something is marking a large portion of the frame as dirty, and it’s overflowing from the left window to the right, probably all the way to the right edge of the frame. That’s almost certainly a call to ns_clip_to_rect. 2. When the right window is marked as dirty it’s failing to redraw completely. I’d assume what is happening is that the expose_frame functions (and its descendants) don’t notice that the crosshair needs to be redrawn. I’m unsure how that side of it works, something must have to compare the rectangle to be exposed with the contents of the frame and decide what needs redrawn. IMHO both should be fixed. 1 because it’s redrawing too much, and 2 because there are other circumstances where part of your crosshair could be marked as dirty and therefore need redrawn. -- Alan Third