From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: emacs rendering comparisson between emacs23 and emacs26.3 Date: Wed, 08 Apr 2020 16:59:08 +0300 Message-ID: <83h7xuoz83.fsf@gnu.org> References: <20200403174757.GA8266@ACM> <20200404104553.GA5329@ACM> <07fe3b69-3ab2-3173-0696-cb17809e2b91@gmx.at> <83blo7v68b.fsf@gnu.org> <1845d7aa-9ae4-3d95-6a30-c7b1d8d8adec@gmx.at> <83a73qt6zs.fsf@gnu.org> <97c4254e-ff43-8402-3645-f713c408c245@gmx.at> <83y2r9syby.fsf@gnu.org> <20200405195753.GG5049@ACM> <542b48ba-4dfa-820f-ba50-4b147ab6d8e2@yandex.ru> <0a5f70aa-4985-8f8d-81d6-6ac4a60a94f9@yandex.ru> <838sj8sphk.fsf@gnu.org> <834ktwsmfw.fsf@gnu.org> <83imibqsmm.fsf@gnu.org> Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="41728"; mail-complaints-to="usenet@ciao.gmane.io" Cc: acm@muc.de, rrandresf@gmail.com, emacs-devel@gnu.org, rms@gnu.org, dgutov@yandex.ru To: martin rudalics Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Wed Apr 08 15:59:48 2020 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jMBF6-000Aki-Bf for ged-emacs-devel@m.gmane-mx.org; Wed, 08 Apr 2020 15:59:48 +0200 Original-Received: from localhost ([::1]:36410 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jMBF5-0001uu-Ef for ged-emacs-devel@m.gmane-mx.org; Wed, 08 Apr 2020 09:59:47 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:46533) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jMBEc-0001SG-QD for emacs-devel@gnu.org; Wed, 08 Apr 2020 09:59:19 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:54227) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1jMBEb-00030a-NI; Wed, 08 Apr 2020 09:59:17 -0400 Original-Received: from [176.228.60.248] (port=4764 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1jMBEU-0004xU-D0; Wed, 08 Apr 2020 09:59:10 -0400 In-Reply-To: (message from martin rudalics on Wed, 8 Apr 2020 10:37:46 +0200) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] 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-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:246666 Archived-At: > Cc: acm@muc.de, rrandresf@gmail.com, rms@gnu.org, emacs-devel@gnu.org > From: martin rudalics > Date: Wed, 8 Apr 2020 10:37:46 +0200 > > > It stops when it gets to a buffer position where the > > 'fontified' text property changes its value. If the new value of > > 'fontified' is nil, the display engine calls fontification-functions. > > jit-lock adds its function to that hook, so jit-lock is called. What > > jit-lock does, in a nutshell, is call the current buffer's > > fontification function(s) on a chunk of text starting at the position > > for which it was called, and it puts on that chunk a value of t for > > the 'fontified' text property. (Where that chunk ended is the > > position where the 'fontified' property's value will again change to > > nil, and if that position is inside the window, jit-lock will be > > called again when the display engine gets to that position.) After > > fontification-functions return, the display engine processes the faces > > in the chunk that has been fontified; then it continues marching > > through the buffer. > > IIRC fontification can also modify text before the position where the > 'fontified' property changed to nil. Or is that wrong? What is actually fontified depends on the buffer's fontification-functions; jit-lock just calls those functions with a region that starts at the first position in the window that has its 'fontified' property nil, and ends jit-lock-chunk-size (500 bytes by default) after that. However, the 'fontified' property will be set by jit-lock to t only for text in that chunk, as jit-lock has no way of knowing what was actually fontified.