From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.bugs Subject: bug#32790: 27.0.50; point jumps unexpectedly after delete-window Date: Thu, 15 Nov 2018 02:15:37 +0200 Organization: LINKOV.NET Message-ID: <87va4zfapq.fsf@mail.linkov.net> References: <87efdnsp2k.fsf@mail.linkov.net> <87bm7bru1c.fsf@mail.linkov.net> <5BD963C8.9090905@gmx.at> <87h8h195ki.fsf@mail.linkov.net> <5BDAC159.1060008@gmx.at> <87muqsh11q.fsf@mail.linkov.net> <5BDC0E81.1050806@gmx.at> <87tvkwh4bp.fsf@mail.linkov.net> <5BE00F12.5000703@gmx.at> <87d0rjuq8c.fsf@mail.linkov.net> <5BE15552.4040507@gmx.at> <87y3a5rgm2.fsf@mail.linkov.net> <5BE2AF28.2020505@gmx.at> <87bm6zme24.fsf@mail.linkov.net> <5BE54FA1.2030004@gmx.at> <87k1lkllud.fsf@mail.linkov.net> <5BE7EDAD.9040808@gmx.at> <87tvklx4je.fsf@mail.linkov.net> <5BEA94A7.20809@gmx.at> <87r2foa8gq.fsf@mail.linkov.net> <5BEBDDCB.6090608@gmx.at> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Trace: blaine.gmane.org 1542241828 12040 195.159.176.226 (15 Nov 2018 00:30:28 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Thu, 15 Nov 2018 00:30:28 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (x86_64-pc-linux-gnu) Cc: 32790@debbugs.gnu.org To: martin rudalics Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Thu Nov 15 01:30:23 2018 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gN5Y7-000318-7y for geb-bug-gnu-emacs@m.gmane.org; Thu, 15 Nov 2018 01:30:23 +0100 Original-Received: from localhost ([::1]:35058 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gN5aD-0002c0-KH for geb-bug-gnu-emacs@m.gmane.org; Wed, 14 Nov 2018 19:32:33 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:60464) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gN5Zo-0002Sw-T8 for bug-gnu-emacs@gnu.org; Wed, 14 Nov 2018 19:32:09 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gN5Zj-0002AJ-Ua for bug-gnu-emacs@gnu.org; Wed, 14 Nov 2018 19:32:08 -0500 Original-Received: from debbugs.gnu.org ([208.118.235.43]:48479) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gN5Zi-00028w-28 for bug-gnu-emacs@gnu.org; Wed, 14 Nov 2018 19:32:03 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1gN5Zh-0001Pd-Tx for bug-gnu-emacs@gnu.org; Wed, 14 Nov 2018 19:32:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Juri Linkov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 15 Nov 2018 00:32:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 32790 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 32790-submit@debbugs.gnu.org id=B32790.15422419175415 (code B ref 32790); Thu, 15 Nov 2018 00:32:01 +0000 Original-Received: (at 32790) by debbugs.gnu.org; 15 Nov 2018 00:31:57 +0000 Original-Received: from localhost ([127.0.0.1]:52737 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gN5Zc-0001PH-Uz for submit@debbugs.gnu.org; Wed, 14 Nov 2018 19:31:57 -0500 Original-Received: from quail.birch.relay.mailchannels.net ([23.83.209.151]:7406) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gN5ZY-0001Ot-JU for 32790@debbugs.gnu.org; Wed, 14 Nov 2018 19:31:53 -0500 X-Sender-Id: dreamhost|x-authsender|jurta@jurta.org Original-Received: from relay.mailchannels.net (localhost [127.0.0.1]) by relay.mailchannels.net (Postfix) with ESMTP id 150E95E1B55; Thu, 15 Nov 2018 00:31:51 +0000 (UTC) Original-Received: from pdx1-sub0-mail-a77.g.dreamhost.com (unknown [100.96.26.166]) (Authenticated sender: dreamhost) by relay.mailchannels.net (Postfix) with ESMTPA id AFC095E1AE9; Thu, 15 Nov 2018 00:31:50 +0000 (UTC) X-Sender-Id: dreamhost|x-authsender|jurta@jurta.org Original-Received: from pdx1-sub0-mail-a77.g.dreamhost.com (pop.dreamhost.com [64.90.62.162]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384) by 0.0.0.0:2500 (trex/5.16.2); Thu, 15 Nov 2018 00:31:51 +0000 X-MC-Relay: Neutral X-MailChannels-SenderId: dreamhost|x-authsender|jurta@jurta.org X-MailChannels-Auth-Id: dreamhost X-Harmony-Arithmetic: 48fcd3693d8f128c_1542241910879_3692128092 X-MC-Loop-Signature: 1542241910878:2182501512 X-MC-Ingress-Time: 1542241910878 Original-Received: from pdx1-sub0-mail-a77.g.dreamhost.com (localhost [127.0.0.1]) by pdx1-sub0-mail-a77.g.dreamhost.com (Postfix) with ESMTP id 67BAD815FF; Wed, 14 Nov 2018 16:31:50 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=linkov.net; h=from:to:cc :subject:references:date:in-reply-to:message-id:mime-version :content-type:content-transfer-encoding; s=linkov.net; bh=kU+SWE Xd1H4sNXDATgJd6jW5k+I=; b=0UoWmKxoPnsYKnDG2n96rXFJ+WMpgB4cp+8r7i motsTriGgLSAtQxYUveC2GAv3hAZzkkMOKUgn9OjL2E8z9T65HWb3LaRBzDr5RUN rWTuczWN3j6qj/6vQ+n/LSG+TBY9wiKadU/0kHvrDF6qutZamLHxk5JVLzcoiF7Y OUEmg= Original-Received: from mail.jurta.org (m91-129-107-244.cust.tele2.ee [91.129.107.244]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) (Authenticated sender: jurta@jurta.org) by pdx1-sub0-mail-a77.g.dreamhost.com (Postfix) with ESMTPSA id B8CED815FB; Wed, 14 Nov 2018 16:31:48 -0800 (PST) X-DH-BACKEND: pdx1-sub0-mail-a77 In-Reply-To: <5BEBDDCB.6090608@gmx.at> (martin rudalics's message of "Wed, 14 Nov 2018 09:33:15 +0100") X-VR-OUT-STATUS: OK X-VR-OUT-SCORE: -100 X-VR-OUT-SPAMCAUSE: gggruggvucftvghtrhhoucdtuddrgedtkedrleeggddvhecutefuodetggdotefrodftvfcurfhrohhfihhlvgemucggtfgfnhhsuhgsshgtrhhisggvpdfftffgtefojffquffvnecuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenucfjughrpefhvffuohhfffgjkfgfgggtgfesthekredttderjeenucfhrhhomheplfhurhhiucfnihhnkhhovhcuoehjuhhriheslhhinhhkohhvrdhnvghtqeenucfkphepledurdduvdelrddutdejrddvgeegnecurfgrrhgrmhepmhhouggvpehsmhhtphdphhgvlhhopehmrghilhdrjhhurhhtrgdrohhrghdpihhnvghtpeeluddruddvledruddtjedrvdeggedprhgvthhurhhnqdhprghthheplfhurhhiucfnihhnkhhovhcuoehjuhhriheslhhinhhkohhvrdhnvghtqedpmhgrihhlfhhrohhmpehjuhhriheslhhinhhkohhvrdhnvghtpdhnrhgtphhtthhopehruhgurghlihgtshesghhmgidrrghtnecuvehluhhsthgvrhfuihiivgeptd X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.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" Xref: news.gmane.org gmane.emacs.bugs:152401 Archived-At: >>> I'd invert these: The "-display-" infix implies that the buffer is >>> displayed and not popped to. >> >> Then easier just to rename it to windmove-pop-in-direction >> because most commands use pop-to-buffer, so this should be >> the default. > > That would be much better. The name 'windmove-display-in-direction' is more intuitive and still correct because it displays. Select/no-select is a minor detail that depends on the prefix arg and a variable that I propose to name windmove-display-select. >> But currently I'm more concerned about inability to use switch-to-buff= er, >> i.e. trying to display a buffer in another window with =E2=80=98S-M-do= wn C-x b RET=E2=80=99 >> doesn't work. > > You mean wherever we can't use 'pop-to-buffer-same-window' instead? Yes, and 'switch-to-buffer' should not use 'pop-to-buffer-same-window'. > 'switch-to-buffer' is different. Reconciling 'force-same-window' and > 'switch-to-buffer-in-dedicated-window' looks rather painful to me. > >> I tried to temporarily set dedicated-p to an old window, >> but switch-to-buffer removes its dedicatedness. > > What did you try exactly? Naively spoken, I suppose you would have > bound the dedicated flag of the selected window to 't' to make > sure it can't get used and 'switch-to-buffer-in-dedicated-window' to > 'pop' to avoid a user error. I tried to set switch-to-buffer-in-dedicated-window to t instead of 'pop'= . But I see now it's not worth the trouble to handle dedicatedness in 'windmove-display-in-direction' because it's not a general solution. Maybe simpler to rebind 'C-x b' from 'switch-to-buffer' to the command 'pop-to-buffer'? Is 'pop-to-buffer' equivalent to 'switch-to-buffer' as a command with only difference in select/no-select behavior?