From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Kevin Rodgers Newsgroups: gmane.emacs.devel Subject: Re: info-look.el bug Date: Fri, 06 Feb 2004 13:30:05 -0700 Sender: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Message-ID: <4023F94D.5080307@yahoo.com> References: <16413.4543.492252.351095@bushmills.inf.ed.ac.uk> <401FD49A.5010506@yahoo.com> NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1076099519 27486 80.91.224.253 (6 Feb 2004 20:31:59 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Fri, 6 Feb 2004 20:31:59 +0000 (UTC) Original-X-From: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Fri Feb 06 21:31:52 2004 Return-path: Original-Received: from quimby.gnus.org ([80.91.224.244]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1ApCdk-0000yH-00 for ; Fri, 06 Feb 2004 21:31:52 +0100 Original-Received: from monty-python.gnu.org ([199.232.76.173]) by quimby.gnus.org with esmtp (Exim 3.35 #1 (Debian)) id 1ApCdk-0004H6-00 for ; Fri, 06 Feb 2004 21:31:52 +0100 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.24) id 1ApCdF-0001JY-0d for emacs-devel@quimby.gnus.org; Fri, 06 Feb 2004 15:31:21 -0500 Original-Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.24) id 1ApCcW-0001IO-H9 for emacs-devel@gnu.org; Fri, 06 Feb 2004 15:30:36 -0500 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.24) id 1ApCbz-0001Ef-71 for emacs-devel@gnu.org; Fri, 06 Feb 2004 15:30:35 -0500 Original-Received: from [80.91.224.249] (helo=main.gmane.org) by monty-python.gnu.org with esmtp (Exim 4.24) id 1ApCby-0001EX-M6 for emacs-devel@gnu.org; Fri, 06 Feb 2004 15:30:02 -0500 Original-Received: from list by main.gmane.org with local (Exim 3.35 #1 (Debian)) id 1ApCbw-0000z1-00 for ; Fri, 06 Feb 2004 21:30:00 +0100 Original-Received: from 170.207.51.80 ([170.207.51.80]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri Feb 6 20:30:00 2004 Original-Received: from ihs_4664 by 170.207.51.80 with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri Feb 6 20:30:00 2004 X-Injected-Via-Gmane: http://gmane.org/ Original-To: emacs-devel@gnu.org Original-Lines: 37 Original-X-Complaints-To: usenet@sea.gmane.org X-Gmane-NNTP-Posting-Host: 170.207.51.80 User-Agent: Mozilla/5.0 (X11; U; SunOS i86pc; en-US; rv:0.9.4.1) Gecko/20020406 Netscape6/6.2.2 X-Accept-Language: en-us X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.2 Precedence: list List-Id: Emacs development discussions. List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Xref: main.gmane.org gmane.emacs.devel:19773 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:19773 Richard Stallman wrote: > When you want to switch to a buffer and let display-buffer choose > where it should appear, you use pop-to-buffer. I think it is a bug > for switch-to-buffer-other-window to obey same-window-buffer-names > or same-window-regexps. So I think this change is called for. > > However, it may be that some existing calls to > switch-to-buffer-other-window would need to be changed to use > pop-to-buffer. I agree with your change, but I don't think it goes far enough. Here's what pop-to-buffer's doc string says: | If optional second arg OTHER-WINDOW is non-nil, insist on finding another | window even if BUFFER is already visible in the selected window. To me, that means that no calls to (pop-to-buffer BUFFER t ...) should obey same-window-buffer-names or -regexps, not just those in switch-to-buffer-other-window and -frame. And so I think the job of temporarily binding same-window-buffer-names and -regexps should be done in pop-to-buffer: (let ((same-window-buffer-names (if other-window nil same-window-buffer-names)) (same-window-regexps (if other-window nil same-window-regexps))) ...) Unfortunately, pop-to-buffer is implemented in C and I don't know how to write that fragment in C. -- Kevin Rodgers