emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] master c1d18b1: Tidy up fix to debbugs#20240.


From: Alan Mackenzie
Subject: [Emacs-diffs] master c1d18b1: Tidy up fix to debbugs#20240.
Date: Sun, 05 Apr 2015 14:42:49 +0000

branch: master
commit c1d18b1d59ef3f0d01c8a1112976241feba2f74a
Author: Alan Mackenzie <address@hidden>
Commit: Alan Mackenzie <address@hidden>

    Tidy up fix to debbugs#20240.
    
    * jit-lock.el (jit-lock-after-change): Widen the buffer only
    whilst putting the 'fontified text properties.
---
 lisp/ChangeLog   |    5 +++++
 lisp/jit-lock.el |   16 ++++++++--------
 2 files changed, 13 insertions(+), 8 deletions(-)

diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 7f2e998..a780b08 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,5 +1,10 @@
 2015-04-05  Alan Mackenzie  <address@hidden>
 
+       * jit-lock.el (jit-lock-after-change): Widen the buffer only
+       whilst putting the 'fontified text properties.
+
+2015-04-05  Alan Mackenzie  <address@hidden>
+
        Rationalize use of c[ad]+r, expunging cl-c[ad]\{3,4\}r.
        Also expunge eudc-c[ad]+r.
 
diff --git a/lisp/jit-lock.el b/lisp/jit-lock.el
index d5651c6..5f9196d 100644
--- a/lisp/jit-lock.el
+++ b/lisp/jit-lock.el
@@ -650,14 +650,14 @@ will take place when text is fontified stealthily."
     (let ((jit-lock-start start)
           (jit-lock-end end))
       (with-buffer-prepared-for-jit-lock
-          (save-restriction
-           (widen)
-           (run-hook-with-args 'jit-lock-after-change-extend-region-functions
-                               start end old-len)
-           ;; Make sure we change at least one char (in case of deletions).
-           (setq jit-lock-end (min (max jit-lock-end (1+ start)) (point-max)))
-           ;; Request refontification.
-           (put-text-property jit-lock-start jit-lock-end 'fontified nil)))
+       (run-hook-with-args 'jit-lock-after-change-extend-region-functions
+                          start end old-len)
+       ;; Make sure we change at least one char (in case of deletions).
+       (setq jit-lock-end (min (max jit-lock-end (1+ start)) (point-max)))
+       ;; Request refontification.
+       (save-restriction
+        (widen)
+        (put-text-property jit-lock-start jit-lock-end 'fontified nil)))
       ;; Mark the change for deferred contextual refontification.
       (when jit-lock-context-unfontify-pos
         (setq jit-lock-context-unfontify-pos



reply via email to

[Prev in Thread] Current Thread [Next in Thread]