From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Katsumi Yamaoka Newsgroups: gmane.emacs.devel Subject: Re: [display-buffer] a way to make it behave as before? Date: Mon, 20 Jun 2011 14:39:11 +0900 Organization: Emacsen advocacy group Message-ID: References: <4DFB7705.2000401@gmx.at> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: dough.gmane.org 1308548401 5146 80.91.229.12 (20 Jun 2011 05:40:01 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 20 Jun 2011 05:40:01 +0000 (UTC) Cc: emacs-devel@gnu.org To: martin rudalics Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Jun 20 07:39:57 2011 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1QYXDG-0000zG-KQ for ged-emacs-devel@m.gmane.org; Mon, 20 Jun 2011 07:39:54 +0200 Original-Received: from localhost ([::1]:57964 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QYXDF-0006Fw-DK for ged-emacs-devel@m.gmane.org; Mon, 20 Jun 2011 01:39:53 -0400 Original-Received: from eggs.gnu.org ([140.186.70.92]:59817) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QYXCw-0006FH-Pd for emacs-devel@gnu.org; Mon, 20 Jun 2011 01:39:36 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QYXCv-0000Tk-7w for emacs-devel@gnu.org; Mon, 20 Jun 2011 01:39:34 -0400 Original-Received: from orlando.hostforweb.net ([216.246.45.90]:34888) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QYXCu-0000Tg-Tt for emacs-devel@gnu.org; Mon, 20 Jun 2011 01:39:33 -0400 Original-Received: from localhost ([127.0.0.1]:54219) by orlando.hostforweb.net with esmtpa (Exim 4.69) (envelope-from ) id 1QYXCs-0001Rt-9g; Mon, 20 Jun 2011 00:39:30 -0500 X-Face: #kKnN,xUnmKia.'[pp`; Omh}odZK)?7wQSl"4o04=EixTF+V[""w~iNbM9ZL+.b*_CxUmFk B#Fu[*?MZZH@IkN:!"\w%I_zt>[$nm7nQosZ<3eu; B:$Q_:p!',P.c0-_Cy[dz4oIpw0ESA^D*1Lw= L&i*6&( User-Agent: Gnus/5.110018 (No Gnus v0.18) Emacs/24.0.50 (cygwin) Cancel-Lock: sha1:aaKLcH7fWEqEtkq7ybLFehyc748= X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - orlando.hostforweb.net X-AntiAbuse: Original Domain - gnu.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - jpl.org X-Source: X-Source-Args: X-Source-Dir: X-detected-operating-system: by eggs.gnu.org: Linux 2.6? (barebone, rare!) X-Received-From: 216.246.45.90 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:140701 Archived-At: (I believe I use the most recent bzr Emacs 24.) >> I'm fiddling `display-buffer-alist' and others so as to make >> `display-buffer' behave as before, though I didn't find out a >> smart way so far. What behavior I want is: >> >> `find-file-other-window' opens a file in the other window of >> the frame when the frame is split into two windows. Don't split >> either of two windows into two, IOW don't change the window >> configuration of the frame[1]. > I just provided a new specifier for `display-buffer-alist' called > other-window-means-other-frame. Please set it and tell me whether it > works (Sometimes I wonder what `find-file-other-frame' is for ;-)). Where/How can I find that specifier in the customization buffer? Ok. I tried those two: (progn (makunbound 'display-buffer-alist) (load "window") (setcdr (car display-buffer-alist) (append (cdar display-buffer-alist) '((other-window-means-other-frame . nil))))) (progn (makunbound 'display-buffer-alist) (load "window") (setcdr (car display-buffer-alist) (append '((other-window-means-other-frame . nil)) (cdar display-buffer-alist)))) But I saw no difference. `C-x 4 f' or `C-x 4 b' still opens a file or a buffer in a new frame, or another existing frame that already displays its window. In the later case, I cannot see it immediately if that frame is hidden by other applications or iconified. I only want to see it in the other window of the current frame. >> Even if there is a window that >> visits the file in another frame, don't use it[2]. > Does this mean that in Emacs 23 you have `display-buffer-reuse-frames' > nil and `pop-up-frames' t? No, both are nil. I leave most such options the default. > Anyway. Why don't you remove all instances of reuse-window from > `display-buffer-alist' that would use a window on another frame, that > is, use only instances of the (reuse-window ... ... nil) type. This way > a window gets reused iff it's on the selected frame. The main reason I want to do all within the current frame is because Emacs doesn't raise a hidden frame. On cygwin (I use it in the office) and on Fedora 14 Linux (I use it in home), Emacs puts a newly created frame on the top of the screen, but it doesn't for a frame that exists but is hidden. As for Fedora 14, I use an external program called `wmctrl' to make `raise-frame' work, but it has no effect on cygwin. Cf. http://lists.gnu.org/archive/html/emacs-devel/2006-10/msg01117.html >> As for the `other-window' specifier, it seems there's no way to >> customize so as to make it behave as above. (It might be >> `display-buffer-macro-specifiers', but it's a constant.) > It's been already removed from there. Please have a look. Confirmed. Thanks. >> I wish there were a switch that makes it behave as before. ;-) >> >> [1] I don't want an Emacs frame to be split into many windows, >> because the screen height of my note is not so high, and >> a font I use is not so small. >> [2] `raise-frame' doesn't work on cygwin (and possibly some >> window managers, like metacity).