From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: martin rudalics Newsgroups: gmane.emacs.devel Subject: Re: Question about display engine Date: Fri, 6 Sep 2019 10:22:48 +0200 Message-ID: <97f66744-8481-084a-ef23-2c50444e1f05@gmx.at> References: <318675867.1913640.1567711569517.ref@mail.yahoo.com> <318675867.1913640.1567711569517@mail.yahoo.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="69433"; mail-complaints-to="usenet@blaine.gmane.org" Cc: eliz@gnu.org, emacs-devel@gnu.org To: Ergus Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Sep 06 10:23:25 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.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1i69Wd-000Hid-F9 for ged-emacs-devel@m.gmane.org; Fri, 06 Sep 2019 10:23:23 +0200 Original-Received: from localhost ([::1]:53440 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1i69Wb-0006Ri-RA for ged-emacs-devel@m.gmane.org; Fri, 06 Sep 2019 04:23:22 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:47613) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1i69WG-0006RI-Vb for emacs-devel@gnu.org; Fri, 06 Sep 2019 04:23:01 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1i69WF-0007F4-T6 for emacs-devel@gnu.org; Fri, 06 Sep 2019 04:23:00 -0400 Original-Received: from mout.gmx.net ([212.227.17.20]:40495) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1i69WE-0007D6-7X; Fri, 06 Sep 2019 04:22:58 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1567758168; bh=p1TvD1oGlMKqS6hbIYIZLmHaG00gVVSDGw/KZEE2yEw=; h=X-UI-Sender-Class:Subject:To:Cc:References:From:Date:In-Reply-To; b=be2K8BJiMpZa3+hR16KH6c17GE9UmlKMOFde/Qgsa/1XQxH6Cx8lQ4Co5fcl/JKht nYG1csztvyi0xmNUDc423V2rZDFQahatzN+I876dGKbFWBbLaic6m07/uxbklQTVoO /sIs0aHAbl/YcGGDIYOYhor5cByJ6q6DXv+C4WAw= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Original-Received: from [192.168.1.101] ([213.162.80.142]) by mail.gmx.com (mrgmx101 [212.227.17.168]) with ESMTPSA (Nemesis) id 0M4jbN-1iN7Qr2jc5-00yyOm; Fri, 06 Sep 2019 10:22:48 +0200 In-Reply-To: <318675867.1913640.1567711569517@mail.yahoo.com> Content-Language: de-DE X-Provags-ID: V03:K1:aEGf48nShr6d+yqQQZl45PmmuqK7Lp/w1p1ilH/07cjUAD41S58 JWuXX6O7+YYeXFqCPVjuvNN+zb/4tzXx0etQuzkLAMA7Ll7Suok0IwD12J43A88+MWzJpQ7 /JUBMuLsVhoCExfz6UrwPgg6iznB8TPSEUSqzlR0dDbIPmqBIxRYIFBAt345grCN/1Fj3U/ LrD/ZPJrPpRvA62LfI0hQ== X-UI-Out-Filterresults: notjunk:1;V03:K0:ri675roObfA=:3b3oPwA9z5hIFGIK0r+fJO OXgmBupX4FpCfq9oBecuErvPMVGyM2mxH8uVsj8S8aBNof65j3Yu//Bfr2/EqoZt+SaSU7MP3 ljE1DXOg3NLT/bsUTYBVZIBCsHp8ydg0APhO68EuQQnh3RFdmCDNNIuf1YUoqowLODuZkPiTb A4GlZyVMSdOKueIE2zW2JqKwtYQFohwfpAJhC+WmIVuQAsXR1QexB/u3h1U61FFQO+ymLyRZK dlB9R4T1GrF767PsdxgiD9S0bTFZmHSzYgDY1GFiOoAp+8MlKc8Ph9RxZgbbJ1HVXLW46su0Z GEvdbiKJuu5zRzZkIRUUhFpGNdL/tFZ7kWRq7H9lzc/2Ce3ARN3sZqdgqhe0ycS+H6AUDLHNo 2PXAD11kHgf2moM/bAnV/tBeQ5s1TZ7gEZGE62/kRo2Z3RnmxEX6fZVBCctwKx1plCjErc+Os PwTLy0kPKkVm12RBurkISMqjA8JeDT6GNQjrqfsFrr6EJOheOo46Dp0zg6AYE56a4ttQmoNyB DxNTcXK52275JWS/PN7T/6DbRM9TOmR3GHVplHQyGKsj94eMYPwY+od6zh1H60c3anGJYuaL1 /LfKkx6uHLYNAdOi2JOA0TES0EABCXoOtiXGh5Z1Kt1We+6OVtcp5lvKy3B0BT5wLswcNLrns Q3gGcBrQG2tPAB05PPYX+OWSTswdvD+27CDL3qVonDp+aqz6/7T/YoNEg8zc33Hh4tJjKA/lP eXHKrZ8A3ZNsZOq/hsSVXsBJeSKNfJXaAHbW4TBGN1w01/W822rWiSGGeKkJ9HTHqcpYcZnm X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 212.227.17.20 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 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:239890 Archived-At: Thanks for the new patch. It applies and Emacs builds here on Windows without problems. > The issue is actually related with the fact that > extend_face_id is never restarted to face_id when going back from an > extend to a non_extend face between lines (for example when mark is > active and the iterator crosses the pointer to outside the selected > region like in the picture). The end of the region is a stop position for the iterator. It can occur in the middle of a line, so handling this problem at the beginning of a display line would be neither sufficient nor useful. When the stop position coinciding with the end of the region is processed, the extend_face_id has to be reset to some new face_id at that position. I'm yet too silly to understand your patch so I cannot figure out where this should happen. But the following parts appear somehow suspicious: /* Update the faces id and extend. */ it->face_id = new_face_id; if (FACE_EXTENSIBLE_P (new_face)) it->extend_face_id = new_face_id; At the end of the region this may get you a new_face that is not extensible. But that means that you do not reset it->extend_face_id although you should (IMHO). Just to make sure that we see the same things: Is my interpretation correct that in your screenshot you use blue for the region and black as default background and the regions starts at line 9 of your window? martin