1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2025-12-15 18:40:39 -08:00

* lisp/hi-lock.el (hi-lock-set-pattern): Check for `font-lock-specified-p'.

Fixes: debbugs:14179
This commit is contained in:
E Sabof 2013-12-20 21:47:01 +02:00 committed by Juri Linkov
parent 3fbba716fb
commit 137f57c81e
2 changed files with 6 additions and 1 deletions

View file

@ -1,3 +1,8 @@
2013-12-20 E Sabof <esabof@gmail.com> (tiny change)
* hi-lock.el (hi-lock-set-pattern): Check for `font-lock-specified-p'.
(Bug#14179)
2013-12-20 Stephen Berman <stephen.berman@gmx.net>
* calendar/todo-mode.el: New implementation of item insertion

View file

@ -719,7 +719,7 @@ Otherwise, read face name from minibuffer with completion and history."
;; Refuse to highlight a text that is already highlighted.
(unless (assoc regexp hi-lock-interactive-patterns)
(push pattern hi-lock-interactive-patterns)
(if font-lock-mode
(if (and font-lock-mode (font-lock-specified-p major-mode))
(progn
(font-lock-add-keywords nil (list pattern) t)
(font-lock-fontify-buffer))