[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Fix for org-mode fontification (Bug#25132) fix on emacs-25?
From: |
Noam Postavsky |
Subject: |
Fix for org-mode fontification (Bug#25132) fix on emacs-25? |
Date: |
Mon, 20 Mar 2017 22:11:45 -0400 |
Hi,
I goofed when pushing the fix for Bug#25132, for some reason I decided
to extend let-binding wider than my initial patch. This causes a
fontification error when combined with some other (undetermined, but
Spacemacs was mentioned) packages [1].
Fixed with the diff below (ignoring whitespace changes for
readability) which narrows the scope of the let-binding (the
let-binding was introduced for 25.2 to fix #25132). Should this go to
emacs-25?
diff --git i/lisp/org/org-src.el w/lisp/org/org-src.el
index a02402cf60..16aa443232 100644
--- i/lisp/org/org-src.el
+++ w/lisp/org/org-src.el
@@ -917,17 +917,17 @@ org-src-font-lock-fontify-block
;; the org-src-fontification buffer in case we're called
;; from `jit-lock-function' (Bug#25132).
(let ((inhibit-modification-hooks nil))
(delete-region (point-min) (point-max))
- (insert string " ") ;; so there's a final property change
+ (insert string " ")) ;; so there's a final property change
(unless (eq major-mode lang-mode) (funcall lang-mode))
(org-font-lock-ensure)
(setq pos (point-min))
(while (setq next (next-single-property-change pos 'face))
(put-text-property
(+ start (1- pos)) (1- (+ start next)) 'face
(get-text-property pos 'face) org-buffer)
- (setq pos next))))
+ (setq pos next)))
(add-text-properties
start end
'(font-lock-fontified t fontified t font-lock-multiline t))
(set-buffer-modified-p modified)))))
[1]: http://lists.gnu.org/archive/html/emacs-orgmode/2017-03/msg00420.html
- Fix for org-mode fontification (Bug#25132) fix on emacs-25?,
Noam Postavsky <=