From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Chong Yidong Newsgroups: gmane.emacs.devel Subject: Re: Lazy Isearch in dired Date: Thu, 13 Nov 2008 10:30:08 -0500 Message-ID: <87fxlv4pa7.fsf@cyd.mit.edu> References: <87d4h5ew7x.fsf@jurta.org> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1226590215 13641 80.91.229.12 (13 Nov 2008 15:30:15 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 13 Nov 2008 15:30:15 +0000 (UTC) Cc: emacs-devel@gnu.org To: Juri Linkov Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Nov 13 16:31:12 2008 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1L0eA2-0008Dr-E5 for ged-emacs-devel@m.gmane.org; Thu, 13 Nov 2008 16:31:10 +0100 Original-Received: from localhost ([127.0.0.1]:46305 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1L0e8u-00017K-8d for ged-emacs-devel@m.gmane.org; Thu, 13 Nov 2008 10:30:00 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1L0e8q-00017F-PZ for emacs-devel@gnu.org; Thu, 13 Nov 2008 10:29:56 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1L0e8o-00016r-ND for emacs-devel@gnu.org; Thu, 13 Nov 2008 10:29:55 -0500 Original-Received: from [199.232.76.173] (port=36653 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1L0e8o-00016o-Ik for emacs-devel@gnu.org; Thu, 13 Nov 2008 10:29:54 -0500 Original-Received: from cyd.mit.edu ([18.115.2.24]:49223) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1L0e8o-0007Hc-P6 for emacs-devel@gnu.org; Thu, 13 Nov 2008 10:29:54 -0500 Original-Received: by cyd.mit.edu (Postfix, from userid 1000) id 24EA957E09E; Thu, 13 Nov 2008 10:30:08 -0500 (EST) In-Reply-To: <87d4h5ew7x.fsf@jurta.org> (Juri Linkov's message of "Sat, 08 Nov 2008 23:57:34 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux) X-detected-operating-system: by monty-python.gnu.org: Genre and OS details not recognized. X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:105639 Archived-At: Juri Linkov writes: > There is a bug in Isearch in dired. When Isearch is narrowed to only > file names, Lazy Isearch highlights matches outside of the Isearch scope. > This is very confusing since C-s and C-r will never visit them. > > The following patch fixes this by using a loop like the loop in the > function `isearch-search'. The docstring of isearch-lazy-highlight-search > says: "Attempt to do the search exactly the way the pending isearch would.", > so no changes in the docstring are needed, because this patch makes it > more similar to the main search function. It also calls isearch-success-function > to skip the matches outside the current Isearch scope. By default this > function skips invisible matches that are useless for lazy highlighting. > This also requires setting search-invisible to nil to not match > invisible text. Hmm, your patch looks reasonable, but I'm not sure. Could it possibly lead to slowdowns in some buffers from the additional search loop? Maybe we should hold this till after the release.