From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: martin rudalics via "Bug reports for GNU Emacs, the Swiss army knife of text editors" Newsgroups: gmane.emacs.bugs Subject: bug#33871: 27.0.50; Revert Dired window saved in window configuration Date: Sun, 24 Mar 2024 10:54:11 +0100 Message-ID: <578de52d-364b-4961-b4e2-7f91cdcaa0b9@gmx.at> References: <87bm59mglk.fsf@mail.linkov.net> <86fsoezsw3.fsf@mail.linkov.net> <86sfsewvxr.fsf@mail.linkov.net> <9d741b43-e3bb-669b-b345-6b877c902b33@gmx.at> <86fsoaq4lo.fsf@mail.linkov.net> <86tucp7dbp.fsf@mail.linkov.net> <37e2129c-464f-7f0a-0870-f7360ca21dc3@gmx.at> <86zfw07tbw.fsf@mail.linkov.net> <96fd3170-e5d2-4d16-93ec-c6fff3efb787@gmx.at> <86wmr2w7to.fsf@mail.linkov.net> <3808f9f8-624a-449c-8572-085582395859@gmx.at> <86y1bffvya.fsf@mail.linkov.net> <8634skstio.fsf@mail.linkov.net> <86msqr79n8.fsf@mail.linkov.net> <532c59dc-59af-4454-b926-2f80fe711fe9@gmx.at> <86zfuq5jxj.fsf@mail.linkov.net> <5cf2b85e-9e24-4a7d-b175-ce140580df32@gmx.at> <86plvksv1e.fsf@mail.linkov.net> Reply-To: martin rudalics Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="15735"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla Thunderbird Cc: 33871@debbugs.gnu.org To: Juri Linkov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sun Mar 24 10:55:37 2024 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1roKZk-0003s2-VP for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 24 Mar 2024 10:55:37 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1roKZW-0000eF-7i; Sun, 24 Mar 2024 05:55:22 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1roKZU-0000dx-C1 for bug-gnu-emacs@gnu.org; Sun, 24 Mar 2024 05:55:20 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1roKZU-0000l2-45 for bug-gnu-emacs@gnu.org; Sun, 24 Mar 2024 05:55:20 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1roKa9-0006bw-P3 for bug-gnu-emacs@gnu.org; Sun, 24 Mar 2024 05:56:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: martin rudalics Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 24 Mar 2024 09:56:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 33871 X-GNU-PR-Package: emacs Original-Received: via spool by 33871-submit@debbugs.gnu.org id=B33871.171127411225263 (code B ref 33871); Sun, 24 Mar 2024 09:56:01 +0000 Original-Received: (at 33871) by debbugs.gnu.org; 24 Mar 2024 09:55:12 +0000 Original-Received: from localhost ([127.0.0.1]:45130 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1roKZL-0006ZM-DV for submit@debbugs.gnu.org; Sun, 24 Mar 2024 05:55:11 -0400 Original-Received: from mout.gmx.net ([212.227.17.21]:53861) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1roKZB-0006YH-OM for 33871@debbugs.gnu.org; Sun, 24 Mar 2024 05:55:11 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmx.at; s=s31663417; t=1711274052; x=1711878852; i=rudalics@gmx.at; bh=1YJMAdGv05cOThbYqP5FpYCsWctqHQpUAOHdl8tMaA4=; h=X-UI-Sender-Class:Date:Subject:To:Cc:References:From: In-Reply-To; b=lT+xkrohHlyHp0SbJqLHhhiMvDz4SLlxcnx6j87be+yhSMzz7JPj7gl8Hl8JmKfF jkzxkkrxEA10QMRGA6QpXHffC73bzGUhDQi7yBzZmGQVYnAWw/kr1KzFcCEx1pYSg WjO5fZsG1TONVfHl5utNJOuOG5XyGPKyPAR5miB10/0FX4sIythM4U+8nKk9rqpNC 8Cubr39s9tBCY1je6wBdyq7qT3nQnEhUcV9+C5ZZvoXlNuwcQ6BkmEaZonRZxZpY2 YrkNEE/JclxQN3xwNVPcf3ev8GrViD3eii0jQvmNM4GvxdhFFbJKK7tEOKvYo9Byz 9mmJfWLADUgDwPjuRA== X-UI-Sender-Class: 724b4f7f-cbec-4199-ad4e-598c01a50d3a Original-Received: from [192.168.31.113] ([46.125.249.63]) by mail.gmx.net (mrgmx104 [212.227.17.168]) with ESMTPSA (Nemesis) id 1MEUz4-1rYK8U2Ris-00Fzcc; Sun, 24 Mar 2024 10:54:12 +0100 Content-Language: en-US In-Reply-To: <86plvksv1e.fsf@mail.linkov.net> X-Provags-ID: V03:K1:IjaIYYlSdnQ4MLW/ysHxEbh5wHJD5xA0WjR5eU2GNsBzm1YMAg6 ke69i7odN1iY5rgnTcHkAJ/MhhY8bP08UL+gz/ZYOQ+0mWe0X1ypSwhrfMEdm+bTzUAmRSI GzAapdmL8jXESXdjr3woJkWRVQtV/pK8JW6WABfuBW/rQNgYGkG61roUv9/AQTQ91cOniv6 qNsF/Cv6GcHleW2fWC/GA== UI-OutboundReport: notjunk:1;M01:P0:rBHHV8ZWuJ0=;zwx+ow9aF52aHpnOLu+KClhyCtc GEGGGvFNXl04FSUx9jOLrclPdNckeIKJFwD3JN61HN83OLiQoVrLcpIfnj44wzlVYhVAwp3Au dr/Dj7wXBnwcxNliwaS50LqEh2Z513nH0ute8hi6AiNzfx2VyINaN4NlBUtq2fC5SCwSAdJBx JgQltlMq9JVW+3KDqJZpMOpy3ScYZh8io0QafIjSwO1Y8Po8JaYGHO5nBxK901Y6hAMZOCF14 2s7Yg0IjoZN/cWWkfFuVuUX/JT3XB/UvewEzlGc7rgTY22iSsgmXTLMG9n6EqNfy1/+o1xw8K tivTNQqU0SN7yKD8sTmIO57MFyV3C3FD/ZLeAjYG8c7vsbnjNzU6bIXCa2ekzEm9rKUsi7hdk 8MBQoYhyyJ+HcoXXdQ7fkuZ3mhMrIw4zWeSK3BD9/C4QSK+zrEwRmS3sS5lO2wJGnle0nU21D /E1zGd9YXeAvsQHRTmH23A56dWpADs0iQCQTtCiy6fplpRBKSzXAiyG3oCjFe904r6DIDthB1 eG6LNIgM0J+yEpC3OPpD0AD9fP6Fft27aajS6caEc9CGw3mpjfpmdp4jRsb9uCajZYJ3HIObL R6wZ1778Eovj184ArN0o6pNuWrFxjwtL0aIIY//PSIuZjAWIFatkrm1FQ/otttSO8BdRqCxCx KEjFwIRDhsuRbJ1T6G8QT6hZ3/4gPdgn/gbUl8ayIS0Q1oYbXlK3gQ6AK6oLMlkFz8esFLhqY zEmvmmg29H7NsJf6OF6ufumGmdOQufm0a0KcnKWv4Mn9tziS0LLsyBlEadzBgNY3mJ0xEqJB X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:282018 Archived-At: > OTOH, tab-bar.el is preloaded as well, so no problem to leave this > in tab-bar.el, since window.el is too large already. Then I would give them a 'tab-bar-' prefix. >> Maybe 'window-restore-set-context' and 'window-restore-use-context' >> would be more indicative names. > > The name 'window-restore-set-context' looks quite self-contradictory. > If your intention was to use a unique prefix, then maybe we could use the > prefix 'window-context' like in 'window-context-set', 'window-context-use'. I'd say the context of a window are the other windows of the same frame. >> Note that when a buffer is killed, the values of its local variables may >> be lost. I don't know whether this is an issue here. Alternatively, we >> could have 'set_window_buffer' set the 'context' window parameter from >> the buffer-local value which would, however, mean that whenever one >> changes the buffer-local value, one would have to simultaneously update >> the parameters in all windows showing that buffer. Something that could >> be done with the help of an advice, though... > > This doesn't look like an issue here because the context is stored > in a window parameter. IIUC the context is stored but not the function to restore the position from the context. > And when the buffer is killed, there is no need > to restore a context in the killed buffer. If you don't intend to restore the context from the file the buffer was visiting. Are you sure you don't want to do that? > The format of the window parameter > > '(BUFFER-NAME . ((dired-filename . FILENAME))) > > uses BUFFER-NAME to check whether the buffer was killed, > and when the current window's buffer doesn't match BUFFER-NAME, > then do nothing. What do you do when you want to restore a configuration from a tab, that configuration contains a window whose buffer was killed but whose file still exists and you wanted to revisit that file in the window with its previous point? Ignore any context for that window? martin