From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Sam Steingold Newsgroups: gmane.emacs.devel Subject: Re: *Occur in buf*? Date: 25 Jul 2002 11:01:17 -0400 Sender: emacs-devel-admin@gnu.org Message-ID: References: <20020725143738.GA26891@gnu.org> Reply-To: sds@gnu.org NNTP-Posting-Host: localhost.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: main.gmane.org 1027609335 988 127.0.0.1 (25 Jul 2002 15:02:15 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Thu, 25 Jul 2002 15:02:15 +0000 (UTC) Cc: "Marshall, Simon" , "'Emacs Developers'" Return-path: Original-Received: from quimby.gnus.org ([80.91.224.244]) by main.gmane.org with esmtp (Exim 3.33 #1 (Debian)) id 17Xk85-0000Fp-00 for ; Thu, 25 Jul 2002 17:02:13 +0200 Original-Received: from fencepost.gnu.org ([199.232.76.164]) by quimby.gnus.org with esmtp (Exim 3.12 #1 (Debian)) id 17XkNQ-0007Gq-00 for ; Thu, 25 Jul 2002 17:18:04 +0200 Original-Received: from localhost ([127.0.0.1] helo=fencepost.gnu.org) by fencepost.gnu.org with esmtp (Exim 3.35 #1 (Debian)) id 17Xk8L-0000hP-00; Thu, 25 Jul 2002 11:02:29 -0400 Original-Received: from h021.c001.snv.cp.net ([209.228.32.135] helo=c001.snv.cp.net) by fencepost.gnu.org with smtp (Exim 3.35 #1 (Debian)) id 17Xk7J-0000eL-00 for ; Thu, 25 Jul 2002 11:01:25 -0400 Original-Received: (cpmta 1910 invoked from network); 25 Jul 2002 08:01:23 -0700 Original-Received: from 65.114.186.226 (HELO glip.premonitia.com) by smtp.premonitia.com (209.228.32.135) with SMTP; 25 Jul 2002 08:01:23 -0700 X-Sent: 25 Jul 2002 15:01:23 GMT Original-To: Miles Bader X-Attribution: Sam X-Disclaimer: You should not expect anyone to agree with me. Mail-Copies-To: never In-Reply-To: <20020725143738.GA26891@gnu.org> Original-Lines: 41 User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3.50 Errors-To: emacs-devel-admin@gnu.org X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.0.11 Precedence: bulk List-Help: List-Post: List-Subscribe: , List-Id: Emacs development discussions. List-Unsubscribe: , List-Archive: Xref: main.gmane.org gmane.emacs.devel:6035 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:6035 > * In message <20020725143738.GA26891@gnu.org> > * On the subject of "Re: *Occur in buf*?" > * Sent on Thu, 25 Jul 2002 10:37:38 -0400 > * Honorable Miles Bader writes: > > On Thu, Jul 25, 2002 at 09:42:16AM -0400, Sam Steingold wrote: > > > IWBNI M-x occur created an *Occur in buf* buffer so that I wouldn't have > > > to do this, rather than *Occur*. > > > > I like your idea. > > unless there are objections, I will install the appended patch. > > The reason why it's common for commands such as occur to use a global > buffer is that otherwise you end up with lots of random buffers > cluttering up things. this is why I bound 'z' to kill-this-buffer. as for random buffer clutter, there is midnight.el for that. > I would suggest to instead make a C-u prefix to occur create a unique > buffer, and keep the default behavior as-is. I thought about it. occur uses the prefix argument to indicate the number of lines, so this is not quite feasible. > Also note that a more general solution is the `clone-buffer' command, > which duplicates the current buffer with a unique name; in some modes > such as info this is bound to M-n (in occur though, M-n is bound to > `occur-next', though that command actually doesn't seem to work). I can add an `occur-rename' command (bound to `r') that would rename the occur buffer as proposed and bind `clone-buffer' to 'c'. do you like this better? then the effect of my original patch can be accomplished by adding `occur-rename' to `occur-mode-hook'. -- Sam Steingold (http://www.podval.org/~sds) running RedHat7.3 GNU/Linux Good judgment comes from experience and experience comes from bad judgment.