]> code.delx.au - gnu-emacs/commitdiff
(isearch-lazy-highlight-new-loop):
authorJuri Linkov <juri@jurta.org>
Fri, 18 Mar 2005 09:59:31 +0000 (09:59 +0000)
committerJuri Linkov <juri@jurta.org>
Fri, 18 Mar 2005 09:59:31 +0000 (09:59 +0000)
Make arguments beg and end optional.
(isearch-update): Remove optional arguments nil from
isearch-lazy-highlight-new-loop.
(isearch-lazy-highlight-search): Let-bind case-fold-search to
isearch-lazy-highlight-case-fold-search instead of
isearch-case-fold-search, and let-bind isearch-regexp to
isearch-lazy-highlight-regexp.  Use
isearch-lazy-highlight-last-string instead of isearch-string.

lisp/isearch.el

index 2a952272873453cf8c6701153a4229f4b280ba55..dfd50b2a8a1d8f687bc4769bec71c46ea9b15c05 100644 (file)
@@ -744,7 +744,7 @@ is treated as a regexp.  See \\[isearch-forward] for more info."
    isearch-adjusted nil
    isearch-yank-flag nil)
   (when isearch-lazy-highlight
-    (isearch-lazy-highlight-new-loop nil nil))
+    (isearch-lazy-highlight-new-loop))
   ;; We must prevent the point moving to the end of composition when a
   ;; part of the composition has just been searched.
   (setq disable-point-adjustment t))
@@ -2347,7 +2347,7 @@ is nil.  This function is called when exiting an incremental search if
 (defalias 'isearch-lazy-highlight-cleanup 'lazy-highlight-cleanup)
 (make-obsolete 'isearch-lazy-highlight-cleanup 'lazy-highlight-cleanup "22.1")
 
-(defun isearch-lazy-highlight-new-loop (beg end)
+(defun isearch-lazy-highlight-new-loop (&optional beg end)
   "Cleanup any previous `lazy-highlight' loop and begin a new one.
 BEG and END specify the bounds within which highlighting should occur.
 This is called when `isearch-update' is invoked (which can cause the
@@ -2389,11 +2389,12 @@ by other Emacs features."
 (defun isearch-lazy-highlight-search ()
   "Search ahead for the next or previous match, for lazy highlighting.
 Attempt to do the search exactly the way the pending isearch would."
-  (let ((case-fold-search isearch-case-fold-search)
+  (let ((case-fold-search isearch-lazy-highlight-case-fold-search)
+       (isearch-regexp isearch-lazy-highlight-regexp)
        (search-spaces-regexp search-whitespace-regexp))
     (condition-case nil
        (funcall (isearch-search-fun)
-                isearch-string
+                isearch-lazy-highlight-last-string
                 (if isearch-forward
                     (min (or isearch-lazy-highlight-end-limit (point-max))
                          (if isearch-lazy-highlight-wrapped