unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#4812: 23.1.50; delete-window move point to the wrong window
@ 2009-10-27  8:29 Leo
  2009-10-27  9:46 ` martin rudalics
  2011-09-05  8:53 ` martin rudalics
  0 siblings, 2 replies; 3+ messages in thread
From: Leo @ 2009-10-27  8:29 UTC (permalink / raw)
  To: emacs-pretest-bug

Please describe exactly what actions triggered the bug
and the precise symptoms of the bug:

A frame is setup as follows with point in window 1.

    +------------------+----------+
    |                  |          |
    |        1         |     2    |
    |                  |          |
    |                  |          |
    |------------------+----------+
    |                  |          |
    |        4         |     3    |
    |                  |          |
    |                  |          |
    +------------------+----------+


Assume each window is displaying different buffers. If I move point to
window 4 and `M-x delete-window', the point is moved to window 2.

It seems to me it is more intuitive if the point is remained in the
window that is enlarged due to delete-window, in this case, window 1.


In GNU Emacs 23.1.50.1 (i386-apple-darwin9.8.0, NS apple-appkit-949.54)
 of 2009-09-22 on neutron.local
Windowing system distributor `Apple', version 10.3.949
configured using `configure  '--with-ns''

Leo





^ permalink raw reply	[flat|nested] 3+ messages in thread

* bug#4812: 23.1.50; delete-window move point to the wrong window
  2009-10-27  8:29 bug#4812: 23.1.50; delete-window move point to the wrong window Leo
@ 2009-10-27  9:46 ` martin rudalics
  2011-09-05  8:53 ` martin rudalics
  1 sibling, 0 replies; 3+ messages in thread
From: martin rudalics @ 2009-10-27  9:46 UTC (permalink / raw)
  To: Leo, 4812

 > A frame is setup as follows with point in window 1.
 >
 >     +------------------+----------+
 >     |                  |          |
 >     |        1         |     2    |
 >     |                  |          |
 >     |                  |          |
 >     |------------------+----------+
 >     |                  |          |
 >     |        4         |     3    |
 >     |                  |          |
 >     |                  |          |
 >     +------------------+----------+
 >
 >
 > Assume each window is displaying different buffers. If I move point to
 > window 4 and `M-x delete-window', the point is moved to window 2.

When describing window-layouts please alway describe the sequence of
events that got you there.  In the layout above it's not clear whether
the initial split was a horizontal one or a vertical one.

 > It seems to me it is more intuitive if the point is remained in the
 > window that is enlarged due to delete-window, in this case, window 1.

I suppose you refer to the case where window 4 is selected at the time
you delete it and want window 1 get selected thereafter.  `point' is
never changed by deleting windows.

The situation is not that simple, unfortunately.  In your first bug
report you talked about quitting the calc window.  In that case, I
suppose, you'd rather want to select the window that was selected at the
time you invoked calc (unless another window got selected in between).
So suppose you're in window 1, invoke calc which splits window 4, and
quit calc, you'd rather go back to window 1 instead of window 4.  But
you might have, in between, selected window 3 so quitting calc should
get you back to window 3.  Handling all possible scenarios (including
those that create/delete other windows in between) is tricky.

Also, note that in a configuration like

  -----------
|  1  |  2  |
|-----------|
|     3     |
  -----------

deleting window 3 will enlarge windows 1 and 2 so you still need another
strategy to decide which window should get selected.

martin





^ permalink raw reply	[flat|nested] 3+ messages in thread

* bug#4812: 23.1.50; delete-window move point to the wrong window
  2009-10-27  8:29 bug#4812: 23.1.50; delete-window move point to the wrong window Leo
  2009-10-27  9:46 ` martin rudalics
@ 2011-09-05  8:53 ` martin rudalics
  1 sibling, 0 replies; 3+ messages in thread
From: martin rudalics @ 2011-09-05  8:53 UTC (permalink / raw)
  To: 4812-done

> A frame is setup as follows with point in window 1.
> 
>     +------------------+----------+
>     |                  |          |
>     |        1         |     2    |
>     |                  |          |
>     |                  |          |
>     |------------------+----------+
>     |                  |          |
>     |        4         |     3    |
>     |                  |          |
>     |                  |          |
>     +------------------+----------+
> 
> 
> Assume each window is displaying different buffers. If I move point to
> window 4 and `M-x delete-window', the point is moved to window 2.
> 
> It seems to me it is more intuitive if the point is remained in the
> window that is enlarged due to delete-window, in this case, window 1.

Point now moves to the most recently selected window.

Closed, martin.






^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2011-09-05  8:53 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-10-27  8:29 bug#4812: 23.1.50; delete-window move point to the wrong window Leo
2009-10-27  9:46 ` martin rudalics
2011-09-05  8:53 ` martin rudalics

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).