changeset 72865:1ba9cc2a8b76

(jit-lock-fontify-again): New function. (jit-lock-fontify-now): Use it instead of lambda form.
author Kim F. Storm <storm@cua.dk>
date Thu, 14 Sep 2006 11:08:50 +0000
parents b3ac65067f69
children 0241744f31e1
files lisp/jit-lock.el
diffstat 1 files changed, 9 insertions(+), 9 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/jit-lock.el	Thu Sep 14 11:08:38 2006 +0000
+++ b/lisp/jit-lock.el	Thu Sep 14 11:08:50 2006 +0000
@@ -397,19 +397,19 @@
            ;; eagerly extend the refontified region with
            ;; jit-lock-after-change-extend-region-functions.
            (when (< start orig-start)
-             (lexical-let ((start start)
-                           (orig-start orig-start)
-                           (buf (current-buffer)))
-               (run-with-timer
-                0 nil (lambda ()
-                        (with-current-buffer buf
-                          (with-buffer-prepared-for-jit-lock
-                              (put-text-property start orig-start
-                                                 'fontified t)))))))
+	     (run-with-timer 0 nil 'jit-lock-fontify-again
+			     (current-buffer) start orig-start))
 
 	   ;; Find the start of the next chunk, if any.
 	   (setq start (text-property-any next end 'fontified nil))))))))
 
+(defun jit-lock-fontify-again (buf start end)
+  "Fontify in buffer BUF from START to END."
+  (with-current-buffer buf
+    (with-buffer-prepared-for-jit-lock
+     (put-text-property start end 'fontified t))))
+
+
 
 ;;; Stealth fontification.