From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Alan Mackenzie Newsgroups: gmane.emacs.devel Subject: Re: Isearch in dired Date: Sat, 8 Nov 2008 12:19:29 +0000 Message-ID: <20081108121929.GA3616@muc.de> References: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1226146109 4640 80.91.229.12 (8 Nov 2008 12:08:29 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 8 Nov 2008 12:08:29 +0000 (UTC) Cc: emacs-devel@gnu.org To: "Richard M. Stallman" Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat Nov 08 13:09:32 2008 connect(): Connection refused 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 1Kymd9-0001x4-Hp for ged-emacs-devel@m.gmane.org; Sat, 08 Nov 2008 13:09:31 +0100 Original-Received: from localhost ([127.0.0.1]:43152 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Kymc2-0002Vh-4r for ged-emacs-devel@m.gmane.org; Sat, 08 Nov 2008 07:08:22 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Kymbx-0002VP-Tz for emacs-devel@gnu.org; Sat, 08 Nov 2008 07:08:17 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Kymbx-0002Uf-4s for emacs-devel@gnu.org; Sat, 08 Nov 2008 07:08:17 -0500 Original-Received: from [199.232.76.173] (port=54316 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Kymbx-0002UZ-25 for emacs-devel@gnu.org; Sat, 08 Nov 2008 07:08:17 -0500 Original-Received: from colin.muc.de ([193.149.48.1]:2744 helo=mail.muc.de) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1Kymbw-0005KV-Gt for emacs-devel@gnu.org; Sat, 08 Nov 2008 07:08:16 -0500 Original-Received: (qmail 25120 invoked by uid 3782); 8 Nov 2008 12:08:14 -0000 Original-Received: from acm.muc.de (pD9E520F2.dip.t-dialin.net [217.229.32.242]) by colin2.muc.de (tmda-ofmipd) with ESMTP; Sat, 08 Nov 2008 13:08:10 +0100 Original-Received: (qmail 4328 invoked by uid 1000); 8 Nov 2008 12:19:29 -0000 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.9i X-Delivery-Agent: TMDA/1.1.5 (Fettercairn) X-Primary-Address: acm@muc.de X-detected-operating-system: by monty-python.gnu.org: FreeBSD 4.6-4.9 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:105460 Archived-At: Morning, Richard! On Sat, Nov 08, 2008 at 04:56:52AM -0500, Richard M. Stallman wrote: > It would be useful for isearch in a dired buffer to match only file > names by default. I think this would be a good feature -- if we can > come up with a natural way to request ordinary search of the entire > buffer. > Can anyone think of one? This doesn't have to be a special dired thing. Surely it should be a major mode dependent hook: (defvar isearch-in-valid-region-p nil "If non-nil, a function which returns non-nil if the current isearch match is acceptable. It is given two parameters, the beginning and end of the match.") There are already several toggle keys in isearch-mode: M-r (toggle regexp), M-c (toggle case sensitivity), ..... So, how about C-M-z (toggle validation funtion)? It's not that brilliant - in fact, it's pretty bad, but it doesn't shadow a useful function in the Emacs core (is C-M-z bound anywhere at all?) and it's no worse than C-M-w. ;-( Come on, Richard, tell us what your best effort at thinking up a key binding was. ;-) -- Alan Mackenzie (Nuremberg, Germany).