aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorE Sabof2013-12-20 21:47:01 +0200
committerJuri Linkov2013-12-20 21:47:01 +0200
commit137f57c81e368013e62fcd6f0c6489e6363f65e7 (patch)
tree2123a7f213b7e87d3208d4c7c79e532ba1721697
parent3fbba716fbf09f0c13c73e822df10a7607aa6799 (diff)
downloademacs-137f57c81e368013e62fcd6f0c6489e6363f65e7.tar.gz
emacs-137f57c81e368013e62fcd6f0c6489e6363f65e7.zip
* lisp/hi-lock.el (hi-lock-set-pattern): Check for `font-lock-specified-p'.
Fixes: debbugs:14179
-rw-r--r--lisp/ChangeLog5
-rw-r--r--lisp/hi-lock.el2
2 files changed, 6 insertions, 1 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 3286c90caed..a5447fb5624 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,8 @@
12013-12-20 E Sabof <esabof@gmail.com> (tiny change)
2
3 * hi-lock.el (hi-lock-set-pattern): Check for `font-lock-specified-p'.
4 (Bug#14179)
5
12013-12-20 Stephen Berman <stephen.berman@gmx.net> 62013-12-20 Stephen Berman <stephen.berman@gmx.net>
2 7
3 * calendar/todo-mode.el: New implementation of item insertion 8 * calendar/todo-mode.el: New implementation of item insertion
diff --git a/lisp/hi-lock.el b/lisp/hi-lock.el
index 37ca83cba31..bb5c54e7152 100644
--- a/lisp/hi-lock.el
+++ b/lisp/hi-lock.el
@@ -719,7 +719,7 @@ Otherwise, read face name from minibuffer with completion and history."
719 ;; Refuse to highlight a text that is already highlighted. 719 ;; Refuse to highlight a text that is already highlighted.
720 (unless (assoc regexp hi-lock-interactive-patterns) 720 (unless (assoc regexp hi-lock-interactive-patterns)
721 (push pattern hi-lock-interactive-patterns) 721 (push pattern hi-lock-interactive-patterns)
722 (if font-lock-mode 722 (if (and font-lock-mode (font-lock-specified-p major-mode))
723 (progn 723 (progn
724 (font-lock-add-keywords nil (list pattern) t) 724 (font-lock-add-keywords nil (list pattern) t)
725 (font-lock-fontify-buffer)) 725 (font-lock-fontify-buffer))