GNU bug report logs - #29321
Isearch hit count

Previous Next

Package: emacs;

Reported by: charles <at> aurox.ch (Charles A. Roelli)

Date: Thu, 16 Nov 2017 19:28:02 UTC

Severity: wishlist

Done: Juri Linkov <juri <at> linkov.net>

Bug is archived. No further changes may be made.

Full log


Message #137 received at 29321 <at> debbugs.gnu.org (full text, mbox):

From: Juri Linkov <juri <at> linkov.net>
To: Live System User <nyc4bos <at> aol.com>
Cc: 29321 <at> debbugs.gnu.org
Subject: Re: bug#29321: Isearch hit count
Date: Thu, 15 Nov 2018 23:16:39 +0200
[Message part 1 (text/plain, inline)]
>> But this implementation causes flicker because it updates
>> isearch highlighting on every search hit while traversing
>> all found matches COUNT times until it reaches COUNT-th match.
>>
>> Attached is a better approach that adds the COUNT arg to
>> isearch functions down to the lowest-level isearch function,
>> thus making it compatible with the COUNT arg of re-search-forward:
>
>   Unfortunately, this patch (below) had errrs for me:
>
>    ...and in the echo area I see:
>
>              0/0 I-search: -c [(void-variable +)]

It seems this `+' comes from the diff indicator from the
beginning of the diff line from failed patching.

So I attached a whole new file isearch-repeat.3.el
for your convenience.

But please note that it contains a new implementation
because I found problems in the previous implementation:
when COUNT is added to low-level isearch functions then
they don't skip filtered-out matches.

So a better place is in isearch-search after
`funcall isearch-filter-predicate'.  But the problem
is that when (= (match-beginning 0) (match-end 0))
then it doesn't move point one character forward like
isearch-repeat does.  So the right place to use COUNT is in
isearch-repeat.

Please try a new implementation:

[isearch-repeat.3.el (application/emacs-lisp, attachment)]

This bug report was last modified 6 years and 241 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.