diff options
| author | Juri Linkov | 2005-01-11 23:05:16 +0000 |
|---|---|---|
| committer | Juri Linkov | 2005-01-11 23:05:16 +0000 |
| commit | afd33362f4ba845bb6a80c1116a9a82fe32ebfff (patch) | |
| tree | 80aec505a5bbe257549589ba6ed40b548db3eff3 | |
| parent | bca92193e42e31279529e2601a23bc7ad5523485 (diff) | |
| download | emacs-afd33362f4ba845bb6a80c1116a9a82fe32ebfff.tar.gz emacs-afd33362f4ba845bb6a80c1116a9a82fe32ebfff.zip | |
(query-replace-lazy-highlight): Add lazy-highlight group.
(query-replace-highlight, query-replace-lazy-highlight)
(query-replace): Move definitions to the beginning of the file.
| -rw-r--r-- | lisp/ChangeLog | 18 | ||||
| -rw-r--r-- | lisp/replace.el | 42 |
2 files changed, 39 insertions, 21 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 1d8e6518c56..96d8bcc5b06 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,21 @@ | |||
| 1 | 2005-01-12 Juri Linkov <juri@jurta.org> | ||
| 2 | |||
| 3 | * isearch.el (search-highlight, isearch, isearch-lazy-highlight): | ||
| 4 | Bring together isearch highlight related options. | ||
| 5 | (lazy-highlight): Replace group `replace' by `matching'. | ||
| 6 | (lazy-highlight-cleanup, lazy-highlight-initial-delay) | ||
| 7 | (lazy-highlight-interval, lazy-highlight-max-at-a-time) | ||
| 8 | (lazy-highlight): Add aliases to old names isearch-lazy-highlight-... | ||
| 9 | and declare them obsolete. | ||
| 10 | (lazy-highlight-face): Rename from isearch-lazy-highlight-face. | ||
| 11 | (isearch-faces): Remove defgroup. | ||
| 12 | (isearch-overlay, isearch-highlight, isearch-dehighlight): | ||
| 13 | Move isearch highlighting code closer to lazy highlighting code. | ||
| 14 | |||
| 15 | * replace.el (query-replace-lazy-highlight): Add lazy-highlight group. | ||
| 16 | (query-replace-highlight, query-replace-lazy-highlight) | ||
| 17 | (query-replace): Move definitions to the beginning of the file. | ||
| 18 | |||
| 1 | 2005-01-11 Juri Linkov <juri@jurta.org> | 19 | 2005-01-11 Juri Linkov <juri@jurta.org> |
| 2 | 20 | ||
| 3 | * toolbar/back_arrow.xpm, toolbar/back_arrow.pbm, | 21 | * toolbar/back_arrow.xpm, toolbar/back_arrow.pbm, |
diff --git a/lisp/replace.el b/lisp/replace.el index 33a30aa92d9..3520f3e2268 100644 --- a/lisp/replace.el +++ b/lisp/replace.el | |||
| @@ -64,6 +64,27 @@ strings or patterns." | |||
| 64 | :group 'matching | 64 | :group 'matching |
| 65 | :version "21.4") | 65 | :version "21.4") |
| 66 | 66 | ||
| 67 | (defcustom query-replace-highlight t | ||
| 68 | "*Non-nil means to highlight matches during query replacement." | ||
| 69 | :type 'boolean | ||
| 70 | :group 'matching) | ||
| 71 | |||
| 72 | (defcustom query-replace-lazy-highlight t | ||
| 73 | "*Controls the lazy-highlighting during query replacements. | ||
| 74 | When non-nil, all text in the buffer matching the current match | ||
| 75 | is highlighted lazily using isearch lazy highlighting (see | ||
| 76 | `lazy-highlight-initial-delay' and `lazy-highlight-interval')." | ||
| 77 | :type 'boolean | ||
| 78 | :group 'lazy-highlight | ||
| 79 | :group 'matching | ||
| 80 | :version "21.4") | ||
| 81 | |||
| 82 | (defface query-replace | ||
| 83 | '((t (:inherit isearch))) | ||
| 84 | "Face for highlighting query replacement matches." | ||
| 85 | :group 'matching | ||
| 86 | :version "21.4") | ||
| 87 | |||
| 67 | (defun query-replace-descr (string) | 88 | (defun query-replace-descr (string) |
| 68 | (mapconcat 'isearch-text-char-description string "")) | 89 | (mapconcat 'isearch-text-char-description string "")) |
| 69 | 90 | ||
| @@ -1258,27 +1279,6 @@ passed in. If LITERAL is set, no checking is done, anyway." | |||
| 1258 | (replace-match newtext fixedcase literal) | 1279 | (replace-match newtext fixedcase literal) |
| 1259 | noedit) | 1280 | noedit) |
| 1260 | 1281 | ||
| 1261 | (defcustom query-replace-highlight t | ||
| 1262 | "*Non-nil means to highlight matches during query replacement." | ||
| 1263 | :type 'boolean | ||
| 1264 | :group 'matching) | ||
| 1265 | |||
| 1266 | (defcustom query-replace-lazy-highlight t | ||
| 1267 | "*Controls the lazy-highlighting during query replacements. | ||
| 1268 | When non-nil, all text in the buffer matching the current match | ||
| 1269 | is highlighted lazily using isearch lazy highlighting (see | ||
| 1270 | `lazy-highlight-initial-delay' and | ||
| 1271 | `lazy-highlight-interval')." | ||
| 1272 | :type 'boolean | ||
| 1273 | :group 'matching | ||
| 1274 | :version "21.4") | ||
| 1275 | |||
| 1276 | (defface query-replace | ||
| 1277 | '((t (:inherit isearch))) | ||
| 1278 | "Face for highlighting query replacement matches." | ||
| 1279 | :group 'matching | ||
| 1280 | :version "21.4") | ||
| 1281 | |||
| 1282 | (defun perform-replace (from-string replacements | 1282 | (defun perform-replace (from-string replacements |
| 1283 | query-flag regexp-flag delimited-flag | 1283 | query-flag regexp-flag delimited-flag |
| 1284 | &optional repeat-count map start end) | 1284 | &optional repeat-count map start end) |