GNU bug report logs - #23621
25.1.50; Buffer in >1 window; winner-undo recover window point

Previous Next

Package: emacs;

Reported by: Tino Calancha <f92capac <at> gmail.com>

Date: Thu, 26 May 2016 15:35:02 UTC

Severity: wishlist

Found in version 25.1.50

Full log


View this message in rfc822 format

From: Michael Heerdegen <michael_heerdegen <at> web.de>
To: Tino Calancha <f92capac <at> gmail.com>
Cc: 23621 <at> debbugs.gnu.org
Subject: bug#23621: PATCH (25.1.50; Buffer in >1 window; winner-undo recover window point)
Date: Fri, 24 Apr 2020 03:45:56 +0200
Tino Calancha <f92capac <at> gmail.com> writes:

> Allow winner-undo to restore the buffer point from deleted
> windows (Bug#23621).
> * lisp/window.el (window--before-delete-windows): New defun.
> (delete-window, delete-other-windows): Use it.

Seems your patch works only partially because it actually changed
`minimize-window' instead of `delete-other-windows'.  Was it by mistake?

I also have a question: why do we need this at all?  Is it because the
window configuations saved are pushed when e.g. a window is split, but
only afterwards the user changes point etc, then a window is closed, and
when that's undone, without the patch, the originally saved window
configuration contains the initial, useless positions, because the
snapshot had actually been taken "too soon"?

If that is the case - we now have `compare-window-configurations' that
compares modulo value of point and such.  Wouldn't it be simpler to
teach delete-window e.a. to update the head window configuration in the
frame's entry of winner-ring-alist with the current version before a
window is deleted?


TIA,

Michael.




This bug report was last modified 2 years and 10 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.