Improve documentation of Hi Lock mode
* lisp/hi-lock.el (hi-lock-mode, hi-lock-face-buffer) (hi-lock-face-phrase-buffer, hi-lock-face-symbol-at-point): Clarify when 'hi-lock-mode' will use Font Lock and when it will use overlays. (Bug#41124)
This commit is contained in:
parent
7081c1d66f
commit
2caf3e997e
1 changed files with 16 additions and 4 deletions
|
@ -318,7 +318,10 @@ or add (global-hi-lock-mode 1) to your init file.
|
||||||
In buffers where Font Lock mode is enabled, patterns are
|
In buffers where Font Lock mode is enabled, patterns are
|
||||||
highlighted using font lock. In buffers where Font Lock mode is
|
highlighted using font lock. In buffers where Font Lock mode is
|
||||||
disabled, patterns are applied using overlays; in this case, the
|
disabled, patterns are applied using overlays; in this case, the
|
||||||
highlighting will not be updated as you type.
|
highlighting will not be updated as you type. The Font Lock mode
|
||||||
|
is considered \"enabled\" in a buffer if its `major-mode'
|
||||||
|
causes `font-lock-specified-p' to return non-nil, which means
|
||||||
|
the major mode specifies support for Font Lock.
|
||||||
|
|
||||||
When Hi Lock mode is enabled, a \"Regexp Highlighting\" submenu
|
When Hi Lock mode is enabled, a \"Regexp Highlighting\" submenu
|
||||||
is added to the \"Edit\" menu. The commands in the submenu,
|
is added to the \"Edit\" menu. The commands in the submenu,
|
||||||
|
@ -462,7 +465,10 @@ If SUBEXP is omitted or nil, the entire REGEXP is highlighted.
|
||||||
|
|
||||||
Use Font lock mode, if enabled, to highlight REGEXP. Otherwise,
|
Use Font lock mode, if enabled, to highlight REGEXP. Otherwise,
|
||||||
use overlays for highlighting. If overlays are used, the
|
use overlays for highlighting. If overlays are used, the
|
||||||
highlighting will not update as you type."
|
highlighting will not update as you type. The Font Lock mode
|
||||||
|
is considered \"enabled\" in a buffer if its `major-mode'
|
||||||
|
causes `font-lock-specified-p' to return non-nil, which means
|
||||||
|
the major mode specifies support for Font Lock."
|
||||||
(interactive
|
(interactive
|
||||||
(list
|
(list
|
||||||
(hi-lock-regexp-okay
|
(hi-lock-regexp-okay
|
||||||
|
@ -487,7 +493,10 @@ letters case-insensitive, before highlighting with `hi-lock-set-pattern'.
|
||||||
|
|
||||||
Use Font lock mode, if enabled, to highlight REGEXP. Otherwise,
|
Use Font lock mode, if enabled, to highlight REGEXP. Otherwise,
|
||||||
use overlays for highlighting. If overlays are used, the
|
use overlays for highlighting. If overlays are used, the
|
||||||
highlighting will not update as you type."
|
highlighting will not update as you type. The Font Lock mode
|
||||||
|
is considered \"enabled\" in a buffer if its `major-mode'
|
||||||
|
causes `font-lock-specified-p' to return non-nil, which means
|
||||||
|
the major mode specifies support for Font Lock."
|
||||||
(interactive
|
(interactive
|
||||||
(list
|
(list
|
||||||
(hi-lock-regexp-okay
|
(hi-lock-regexp-okay
|
||||||
|
@ -508,7 +517,10 @@ unless you use a prefix argument.
|
||||||
Uses `find-tag-default-as-symbol-regexp' to retrieve the symbol at point.
|
Uses `find-tag-default-as-symbol-regexp' to retrieve the symbol at point.
|
||||||
|
|
||||||
This uses Font lock mode if it is enabled; otherwise it uses overlays,
|
This uses Font lock mode if it is enabled; otherwise it uses overlays,
|
||||||
in which case the highlighting will not update as you type."
|
in which case the highlighting will not update as you type. The Font
|
||||||
|
Lock mode is considered \"enabled\" in a buffer if its `major-mode'
|
||||||
|
causes `font-lock-specified-p' to return non-nil, which means
|
||||||
|
the major mode specifies support for Font Lock."
|
||||||
(interactive)
|
(interactive)
|
||||||
(let* ((regexp (hi-lock-regexp-okay
|
(let* ((regexp (hi-lock-regexp-okay
|
||||||
(find-tag-default-as-symbol-regexp)))
|
(find-tag-default-as-symbol-regexp)))
|
||||||
|
|
Loading…
Add table
Reference in a new issue