unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#10381: 24.0.92; delete-other-windows-vertically depends on the window split order
@ 2011-12-27 21:32 Sam Steingold
  2011-12-28  9:50 ` martin rudalics
  0 siblings, 1 reply; 6+ messages in thread
From: Sam Steingold @ 2011-12-27 21:32 UTC (permalink / raw)
  To: 10381

In GNU Emacs 24.0.92.4 (x86_64-unknown-linux-gnu, X toolkit, Xaw3d scroll bars)
 of 2011-12-26 on t520sds
Windowing system distributor `The X.Org Foundation', version 11.0.11004000
configured using `configure  '--with-wide-int''

`delete-other-windows-vertically' behavior depends on the order in which
the windows were created.

emacs -Q
C-x 3
C-x 2
C-x o
C-x o
C-x 2

there are now 4 windows like this:
-------
|  |  |
-------
|  |  |
-------

M-x delete-other-windows-vertically RET

now there are 3 windows like this:
-------
|  |  |
---|  |
|  |  |
-------

which is correct.

Now, create the 4 windows in a different order:

emacs -Q
C-x 2
C-x 3
C-x o
C-x o
C-x 3

there are now 4 windows like this:
-------
|  |  |
-------
|  |  |
-------

M-x delete-other-windows-vertically RET

now there are 3 windows like this:
-------
|     |
-------
|  |  |
-------

which is _WRONG_.


-- 
Sam Steingold (http://sds.podval.org/) on Ubuntu 11.10 (oneiric) X 11.0.11004000
http://thereligionofpeace.com http://jihadwatch.org http://truepeace.org
http://honestreporting.com http://openvotingconsortium.org http://camera.org
Those who can't write, write manuals.





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

* bug#10381: 24.0.92; delete-other-windows-vertically depends on the window split order
  2011-12-27 21:32 bug#10381: 24.0.92; delete-other-windows-vertically depends on the window split order Sam Steingold
@ 2011-12-28  9:50 ` martin rudalics
  2011-12-28 17:50   ` Sam Steingold
  2011-12-28 18:02   ` Sam Steingold
  0 siblings, 2 replies; 6+ messages in thread
From: martin rudalics @ 2011-12-28  9:50 UTC (permalink / raw)
  To: sds; +Cc: 10381

 > `delete-other-windows-vertically' behavior depends on the order in which
 > the windows were created.

Yes.

 > M-x delete-other-windows-vertically RET
 >
 > now there are 3 windows like this:
 > -------
 > |     |
 > -------
 > |  |  |
 > -------
 >
 > which is _WRONG_.

Why?  Your doc-string says

   Delete the windows in the same column with WINDOW, but not WINDOW itself.

That sentence is vague but doesn't contradict what the function does.

If you want the function do something different, I'd suggest reading
section 28.2 Windows and Frames of the Elisp manual first and make
yourself acquainted with internal windows.  Then you will probably
understand that the behavior you apparently strive for cannot be
obtained when the first split of a frame's root window creates windows
one above the other.

martin





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

* bug#10381: 24.0.92; delete-other-windows-vertically depends on the window split order
  2011-12-28  9:50 ` martin rudalics
@ 2011-12-28 17:50   ` Sam Steingold
  2011-12-28 18:34     ` martin rudalics
  2011-12-28 18:02   ` Sam Steingold
  1 sibling, 1 reply; 6+ messages in thread
From: Sam Steingold @ 2011-12-28 17:50 UTC (permalink / raw)
  To: martin rudalics; +Cc: 10381

> * martin rudalics <ehqnyvpf@tzk.ng> [2011-12-28 10:50:23 +0100]:
>
>> `delete-other-windows-vertically' behavior depends on the order in which
>> the windows were created.
>
> Yes.
>
>> M-x delete-other-windows-vertically RET
>>
>> now there are 3 windows like this:
>> -------
>> |     |
>> -------
>> |  |  |
>> -------
>>
>> which is _WRONG_.
>
> Why?

Because in this case delete-other-windows-vertically deletes windows
horizontally.
I would have understood if the function did _nothing_, but deleting
windows horizontally is clearly wrong.

> Your doc-string says
>
>   Delete the windows in the same column with WINDOW, but not WINDOW itself.
>
> That sentence is vague but doesn't contradict what the function does.

this makes for a very unintuitive notion of a column.

> If you want the function do something different, I'd suggest reading
> section 28.2 Windows and Frames of the Elisp manual first and make
> yourself acquainted with internal windows.  Then you will probably
> understand that the behavior you apparently strive for cannot be
> obtained when the first split of a frame's root window creates windows
> one above the other.

this is very unfortunate.


-- 
Sam Steingold (http://sds.podval.org/) on Ubuntu 11.10 (oneiric) X 11.0.11004000
http://www.PetitionOnline.com/tap12009/ http://memri.org http://dhimmi.com
http://pmw.org.il http://jihadwatch.org http://palestinefacts.org
A professor is someone who talks in someone else's sleep.





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

* bug#10381: 24.0.92; delete-other-windows-vertically depends on the window split order
  2011-12-28  9:50 ` martin rudalics
  2011-12-28 17:50   ` Sam Steingold
@ 2011-12-28 18:02   ` Sam Steingold
  2011-12-28 18:35     ` martin rudalics
  1 sibling, 1 reply; 6+ messages in thread
From: Sam Steingold @ 2011-12-28 18:02 UTC (permalink / raw)
  To: martin rudalics; +Cc: 10381

> * martin rudalics <ehqnyvpf@tzk.ng> [2011-12-28 10:50:23 +0100]:
>
> If you want the function do something different, I'd suggest reading
> section 28.2 Windows and Frames of the Elisp manual first and make

C-h i runs the command info:
in Elisp manual:

28 Maintaining Large Programs
28.2 Change Logs

you probably meant

20.2 Splitting Windows

which does not speak about columns of windows.

> yourself acquainted with internal windows.

C-s in info does not find "internal w"


The bottom line is that there should be an easy way to merge two windows
which is one under the other, no matter what the history of their
creation was.

-- 
Sam Steingold (http://sds.podval.org/) on Ubuntu 11.10 (oneiric) X 11.0.11004000
http://memri.org http://mideasttruth.com http://honestreporting.com
http://jihadwatch.org http://pmw.org.il http://thereligionofpeace.com
Flying is not dangerous; crashing is.





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

* bug#10381: 24.0.92; delete-other-windows-vertically depends on the window split order
  2011-12-28 17:50   ` Sam Steingold
@ 2011-12-28 18:34     ` martin rudalics
  0 siblings, 0 replies; 6+ messages in thread
From: martin rudalics @ 2011-12-28 18:34 UTC (permalink / raw)
  To: sds; +Cc: 10381

 > Because in this case delete-other-windows-vertically deletes windows
 > horizontally.

Really?

 > I would have understood if the function did _nothing_, but deleting
 > windows horizontally is clearly wrong.

If you want the function to do nothing in that case, you would have to
tell it do nothing.  `window-combined-p' can help here.

 >>   Delete the windows in the same column with WINDOW, but not WINDOW itself.
 >>
 >> That sentence is vague but doesn't contradict what the function does.
 >
 > this makes for a very unintuitive notion of a column.

You probably should use the term "edge" instead of "column".  Then you
would see that the function indeed deletes every window whose
corresponding edge has the same coordinate value as that of WINDOW.

 >>  Then you will probably
 >> understand that the behavior you apparently strive for cannot be
 >> obtained when the first split of a frame's root window creates windows
 >> one above the other.
 >
 > this is very unfortunate.

... but deeply rooted in the way Emacs splits windows ever since.

martin





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

* bug#10381: 24.0.92; delete-other-windows-vertically depends on the window split order
  2011-12-28 18:02   ` Sam Steingold
@ 2011-12-28 18:35     ` martin rudalics
  0 siblings, 0 replies; 6+ messages in thread
From: martin rudalics @ 2011-12-28 18:35 UTC (permalink / raw)
  To: sds; +Cc: 10381

 > C-h i runs the command info:
 > in Elisp manual:
 >
 > 28 Maintaining Large Programs
 > 28.2 Change Logs

If you read this your are in the Emacs manual.  Elisp manual stands for
the "The Emacs Lisp Reference Manual".

martin





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

end of thread, other threads:[~2011-12-28 18:35 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-12-27 21:32 bug#10381: 24.0.92; delete-other-windows-vertically depends on the window split order Sam Steingold
2011-12-28  9:50 ` martin rudalics
2011-12-28 17:50   ` Sam Steingold
2011-12-28 18:34     ` martin rudalics
2011-12-28 18:02   ` Sam Steingold
2011-12-28 18:35     ` 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).