diff options
| author | E Sabof | 2013-12-20 21:47:01 +0200 |
|---|---|---|
| committer | Juri Linkov | 2013-12-20 21:47:01 +0200 |
| commit | 137f57c81e368013e62fcd6f0c6489e6363f65e7 (patch) | |
| tree | 2123a7f213b7e87d3208d4c7c79e532ba1721697 | |
| parent | 3fbba716fbf09f0c13c73e822df10a7607aa6799 (diff) | |
| download | emacs-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/ChangeLog | 5 | ||||
| -rw-r--r-- | lisp/hi-lock.el | 2 |
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 @@ | |||
| 1 | 2013-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 | |||
| 1 | 2013-12-20 Stephen Berman <stephen.berman@gmx.net> | 6 | 2013-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)) |