From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: martin rudalics Newsgroups: gmane.emacs.bugs Subject: bug#18381: 24.3.93; Diary can wrongly be displayed in Calendar's window Date: Tue, 09 Sep 2014 08:58:47 +0200 Message-ID: <540EA527.4050809@gmx.at> References: <87k35nqtdd.fsf@rosalinde.fritz.box> <54085AC5.5050304@gmx.at> <7lr3zrjm94.fsf@fencepost.gnu.org> <64a96fko3d.fsf@fencepost.gnu.org> <54099491.4040607@gmx.at> <540ACB49.8010405@gmx.at> <9l38c2bqbo.fsf@fencepost.gnu.org> <87bnqpj1k3.fsf@rosalinde.fritz.box> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1410245970 19942 80.91.229.3 (9 Sep 2014 06:59:30 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 9 Sep 2014 06:59:30 +0000 (UTC) Cc: 18381@debbugs.gnu.org To: Glenn Morris , Stephen Berman Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Tue Sep 09 08:59:23 2014 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1XRFOb-0007yv-Ak for geb-bug-gnu-emacs@m.gmane.org; Tue, 09 Sep 2014 08:59:21 +0200 Original-Received: from localhost ([::1]:47626 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XRFOb-0006u4-1x for geb-bug-gnu-emacs@m.gmane.org; Tue, 09 Sep 2014 02:59:21 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:39101) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XRFOR-0006sw-CN for bug-gnu-emacs@gnu.org; Tue, 09 Sep 2014 02:59:18 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XRFOJ-0007So-89 for bug-gnu-emacs@gnu.org; Tue, 09 Sep 2014 02:59:11 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:42803) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XRFOJ-0007Se-5d for bug-gnu-emacs@gnu.org; Tue, 09 Sep 2014 02:59:03 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1XRFOI-0007tP-KK for bug-gnu-emacs@gnu.org; Tue, 09 Sep 2014 02:59:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: martin rudalics Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 09 Sep 2014 06:59:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 18381 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 18381-submit@debbugs.gnu.org id=B18381.141024594030331 (code B ref 18381); Tue, 09 Sep 2014 06:59:02 +0000 Original-Received: (at 18381) by debbugs.gnu.org; 9 Sep 2014 06:59:00 +0000 Original-Received: from localhost ([127.0.0.1]:34367 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1XRFOF-0007t9-Ne for submit@debbugs.gnu.org; Tue, 09 Sep 2014 02:59:00 -0400 Original-Received: from mout.gmx.net ([212.227.15.19]:51749) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1XRFOD-0007sv-GG for 18381@debbugs.gnu.org; Tue, 09 Sep 2014 02:58:58 -0400 Original-Received: from [88.117.49.181] ([88.117.49.181]) by mail.gmx.com (mrgmx001) with ESMTPSA (Nemesis) id 0Mh9yT-1XnbdC1RSb-00MM2z; Tue, 09 Sep 2014 08:58:51 +0200 In-Reply-To: X-Provags-ID: V03:K0:80mIm+QSRSmOZcJIhfc+wpRuRiu4OLu3PV6nZpk7x4iGLZm+9Kb iWG6mCLNCvmr+BH/GLq62ZNtwnlj8E4FALJil3Sus3d5cDJ0kKmpR9pdEnLdzIO0XU4DSsS yOEh3oVjYsvNERSGKBudtrgbMGe/CdX+lpRoxMa7xprjvlT+igwJ1dvllvjx000WOhTBIND 95VFBBv+cCzQbAsM72xbQ== X-UI-Out-Filterresults: notjunk:1; X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:93173 Archived-At: > emacs -Q > M-x diary > M-x calendar > M-x diary -> clobbered calendar window; not so in 24.3 > > I see now that the cause is that the pixelwise change that I bisected = to > earlier added display-buffer-in-previous-window to > display-buffer-fallback-action - it wasn't there before. > > So I can restore the 24.3 behaviour by using this horrible thing: > > (let ((display-buffer-fallback-action > (list (delq 'display-buffer-in-previous-window > (copy-sequence (car display-buffer-fallback-action)))= ))) > ...) > > This is Not The Right Thing, but ought to restore 24.3-like behaviour.= That's what I meant earlier when I said that > > The window you're using to display `diary' here ... > > ... is the same window where you first show the calendar here. As a= > > consequence, `display-buffer-in-previous-window' will find a window > > where you have shown `diary' already and reuse that window. I'm not= > > sure what's the best thing to do here - maybe we should remove > > `display-buffer-in-previous-window' from > > `display-buffer-fallback-action' in `calendar-in-read-only-buffer'. but obviously we should do something like (let ((display-buffer-overriding-action (list (delq 'display-buffer-in-previous-window (copy-sequence (car display-buffer-fallback-action))))))= ...) because (as you remarked earlier) `display-buffer-fallback-action' is a constant and should not be changed by the user or an application. > I think what I really want is a way to say to display-buffer: > never use a window showing buffer X. > > Is that doable? You can mark the calendar window as softly dedicated to its buffer, ideally only as long as `diary' wants to use it. Otherwise, we could invent new alist entries =E0 la `inhibit-same-window': `inhibit-windows' (whose value would be a list of windows that should not be used), and/or `inhibit-windows-on' (whose value would be a list of buffers that should remain displayed), not for Emacs 24.4, in any case. You still didn't tell me who actually is responsible for displaying the calendar and then the diary. Is it `calendar-in-read-only-buffer'? If we are sure that it's there, we can pass the necessary advice in that mancro's `display-buffer' call's ACTION argument. martin