diff options
author | Lars Ingebrigtsen <larsi@gnus.org> | 2019-10-30 15:04:17 +0100 |
---|---|---|
committer | Lars Ingebrigtsen <larsi@gnus.org> | 2019-10-30 15:04:17 +0100 |
commit | 9df254119c4de577f273cf1ec1a5892a3509da20 (patch) | |
tree | f91fa7fb5359d55f758fb5fed3514702d03b73bf /lisp/font-lock.el | |
parent | 1fc8bf71d99bf966111cfccabef8e8e1cb0321f2 (diff) | |
download | emacs-9df254119c4de577f273cf1ec1a5892a3509da20.tar.gz emacs-9df254119c4de577f273cf1ec1a5892a3509da20.tar.bz2 emacs-9df254119c4de577f273cf1ec1a5892a3509da20.zip |
Make font-lock-refontify try even harder to refontify
* lisp/font-lock.el (font-lock-refontify): Make this command work
even after switching global font lock mode on and then off again.
Diffstat (limited to 'lisp/font-lock.el')
-rw-r--r-- | lisp/font-lock.el | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lisp/font-lock.el b/lisp/font-lock.el index 971e37309e9..2c91586c99d 100644 --- a/lisp/font-lock.el +++ b/lisp/font-lock.el @@ -1107,7 +1107,9 @@ locking for a mode, and is not meant to be called from lisp functions." (interactive) (declare (interactive-only t)) (setq font-lock-major-mode nil) - (font-lock-ensure)) + (font-lock-set-defaults) + (save-excursion + (font-lock-fontify-region (point-min) (point-max)))) (defun font-lock-ensure (&optional beg end) "Make sure the region BEG...END has been fontified. |