From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: Partly deferred font-locking? Date: Wed, 11 Jan 2023 19:45:44 +0200 Message-ID: <834jsxm0c7.fsf@gnu.org> References: <87bkn52dso.fsf@web.de> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="22142"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel@gnu.org To: Michael Heerdegen Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Wed Jan 11 18:45:59 2023 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 1pFfAk-0005Lh-Fe for ged-emacs-devel@m.gmane-mx.org; Wed, 11 Jan 2023 18:45:58 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pFfA6-000667-8Z; Wed, 11 Jan 2023 12:45:18 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pFfA4-00065h-VG for emacs-devel@gnu.org; Wed, 11 Jan 2023 12:45:17 -0500 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pFfA2-00048q-31; Wed, 11 Jan 2023 12:45:16 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=trnP8S7gLDBXHx/wIrd38Fw7nWocS99ijiYZvzOFAsc=; b=aRnruCgj76uF sQflkw0jar6qGfuAwWyaJ7GOgJIopEYvNf9X+yV54TWvVsoUDlJVycgP3wHT/tW2EGBltJFff0rpW J/OCD83D/8/rdqagQMGTo5lMkziBPYj/eeVin87eC7bTybtmbjEtQ5QOUtoh1cE351MYteVAoRK9L y9gLOVbAbhqHVkgg7IgnjAMkIPHrx94M6pGLmxHcNsrFcLHbJuOvQH+uJ/oVr778Q1HoH3sDx1YMU aZLkpFH4MtO5TtOioewUzTUAG6TIfksCOYdHdEerOZEuxNie9VgiHjSQ3EiuhlpUJ+mudVQcDW6a9 HBl058hXTDCWwKQzWzwlpw==; Original-Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pFfA0-0005Uh-TU; Wed, 11 Jan 2023 12:45:13 -0500 In-Reply-To: <87bkn52dso.fsf@web.de> (message from Michael Heerdegen on Wed, 11 Jan 2023 18:15:19 +0100) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 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-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:302352 Archived-At: > From: Michael Heerdegen > Date: Wed, 11 Jan 2023 18:15:19 +0100 > > Is it somehow possible to defer (only) the more expensive parts of > font-lock using a timer? A use case would be the symlink-target > checking fontification rules in dired: the need to check the target file > properties makes scrolling large dired buffers sluggish. > > It seems there are only global settings available that also always > influence font-locking completely as a whole (`jit-lock-stealth-time', > `jit-lock-defer-time'). Yes. > Are there other ways? Or would it be worth to implement? I think it's basically impossible to know up front which parts of fontifications will be expensive and which won't. For starters, it depends on the text around the window.