emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: lax matching is not a great default behavior


From: Drew Adams
Subject: RE: lax matching is not a great default behavior
Date: Tue, 1 Dec 2015 13:17:18 -0800 (PST)

> > The first match is almost instantaneous here; it's the next one,
> > especially if it fails, is slow.
> >
> > So it doesn't seem to be the search itself, it's something else
> > that's at work here.
> 
> Seems to be lazy-highlight.  Set isearch-lazy-highlight to nil, and
> Bob's your uncle.

Of course then only one hit is found at a time.  Naturally that
makes a big difference (always, though it's generally not so
noticeable for non-folded searching).

The same is true, BTW, for the symmetric char folding I added.

It's the reason I have this in the Commentary:

;; Be aware that character-fold searching can be much slower when
;; symmetric - there are many more possibilities to search for.
;; If, for example, you search only for a single "e"-family
;; character then every "e" in the buffer is a search hit (which
;; means lazy-highlighting them all, by default).  Searching with
;; a longer search string is much faster.
;;
;; If you also use library `isearch+.el' then you can turn off lazy
;; highlighting using the toggle key `M-s h L'.  This can vastly
;; improve performance when character folding is symmetric.

Toggling lazy highlighting off makes even symmetric folding snappy,
and even for a one-char string such as é, which (symmetrically)
matches every "e"-like character.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]