]> git.eshelyaron.com Git - emacs.git/commitdiff
bug-reference: signal fontified bounds back to jit-lock (bug#70796)
authorTassilo Horn <tsdh@gnu.org>
Fri, 24 May 2024 19:52:34 +0000 (21:52 +0200)
committerEshel Yaron <me@eshelyaron.com>
Sun, 26 May 2024 05:52:29 +0000 (07:52 +0200)
* lisp/progmodes/bug-reference.el (bug-reference-fontify): Signal
fontified bounds back to jit-lock in order to allow for redisplay
optimizations (bug#70796).

(cherry picked from commit 59d7730a46a4a51a2c7e3c800a1d60f92a2322b6)

lisp/progmodes/bug-reference.el

index 46163774e47da22a877ad9e64b07207cfb7cc3b8..569de5a2b918326063d2f5d9b326800391dc95ea 100644 (file)
@@ -196,7 +196,10 @@ subexpression 10."
                              (funcall bug-reference-url-format)))))))
       ;; Delete remaining but unused overlays.
       (dolist (ov overlays)
-        (delete-overlay ov)))))
+        (delete-overlay ov)))
+    ;; Signal the bounds we actually fontified to jit-lock to allow for
+    ;; optimizations (bug#70796).
+    `(jit-lock-bounds ,beg-line . ,end-line)))
 
 ;; Taken from button.el.
 (defun bug-reference-push-button (&optional pos _use-mouse-action)