How to dock/glue all sub windows together when moving?

Discussions about Winboard/Xboard. News about engines or programs to use with these GUIs (e.g. tournament managers or adapters) belong in this sub forum.

Moderator: Andres Valverde

How to dock/glue all sub windows together when moving?

Postby pstein » 07 Aug 2011, 08:06

After start of Winboard v4.5.2 three (sub) windows appear:

- the board
- Engine output
- evaluation graph

However they seem to be independent for window operations. When I move the board window the others stay at their place on the screen.

is there a way to glue/fix/dock them together so that they are moved together?

Peter
pstein
 
Posts: 18
Joined: 17 Jul 2010, 15:28

Re: How to dock/glue all sub windows together when moving?

Postby H.G.Muller » 07 Aug 2011, 08:50

When you position the auxiliary windows so that they touch the main (= board) window, they should "snap" to it, and then move with the main window when you move or resize that. (But be sure tomove the main window; when you grab any of the others, you will just pull it loose, as this is the way to position them w.r.t. themain window. This behavior is controlled by the option /stickWindows, which should be set to true by default.
User avatar
H.G.Muller
 
Posts: 3453
Joined: 16 Nov 2005, 12:02
Location: Diemen, NL

Re: How to dock/glue all sub windows together when moving?

Postby pstein » 07 Aug 2011, 10:08

H.G.Muller wrote: This behavior is controlled by the option /stickWindows, which should be set to true by default.


Ok, thank you. But where in the Options menu do I find/enable "stickWindow"?
pstein
 
Posts: 18
Joined: 17 Jul 2010, 15:28

Re: How to dock/glue all sub windows together when moving?

Postby EdCollins » 07 Aug 2011, 16:40

I don't believe you will find this option in the pull down menus. Since the option is set to true by default, if you wanted to change it to false, you would have to edit this in your winboard.ini file. You can do so with any text editor. (TextPad, Notepad, etc.)
EdCollins
 
Posts: 71
Joined: 16 May 2010, 09:05
Location: Southern California

Re: How to dock/glue all sub windows together when moving?

Postby pstein » 07 Aug 2011, 17:00

EdCollins wrote:I don't believe you will find this option in the pull down menus. Since the option is set to true by default, if you wanted to change it to false, you would have to edit this in your winboard.ini file. You can do so with any text editor. (TextPad, Notepad, etc.)


Ok, I see.....and it works....for only ONE move.

If I move the three windows a second time then the "engine output window" stays attached but the "Evaluation graph" window gets independent again.
When I attach this eval graph window again then it works again for exactly one step.

This is a bug in Winboard (or in 64bit Win 7 Pro)

Peter
pstein
 
Posts: 18
Joined: 17 Jul 2010, 15:28

Re: How to dock/glue all sub windows together when moving?

Postby EdCollins » 07 Aug 2011, 22:15

pstein, please note it is working fine for me. All windows continue to stick when moving them all over the screen.

(I'm using Windows Vista Home Premium, 64-bit, and WinBoard hgmaster-20110709.)
EdCollins
 
Posts: 71
Joined: 16 May 2010, 09:05
Location: Southern California

Re: How to dock/glue all sub windows together when moving?

Postby Giorgio Medeot » 08 Aug 2011, 12:58

Here, on a couple of different machines, both running Win XP Professional Edition, I get a somewhat erratic behaviour:

1. when I drag the main windows the first time, after launching WB, the other windows get an offset towards the north direction (about little more than the heigth of a title bar); then they are dragged with the main windows, keeping the same relative position. If I rearrange them, from now on they drag correctly, but if I "save settings", close WB, relaunch it, I can reproduce the same behaviour.

2. If I attach a window on another window other than the main one, it doesn't get sticked (e.g. If I put Engine Output on the right of Main, and then Move History on the right of Engine Output).

3. If I attach a window _below_ Main, it gets sticked and drags with it, but if I "save settings", close WB, relaunch it, and try to drag Main, the window attached below doesn't drag.

Note that (1) and (3) happens even if I detach and reattach the windows as soon as I start WB; I need to drag Main window at least once, and then detaching-reattaching cures things.

I hope this can help.
Cheers,
    Giorgio
Giorgio Medeot
 
Posts: 26
Joined: 31 Aug 2009, 11:01

Re: How to dock/glue all sub windows together when moving?

Postby H.G.Muller » 08 Aug 2011, 16:39

Giorgio Medeot wrote:1. when I drag the main windows the first time, after launching WB, the other windows get an offset towards the north direction (about little more than the heigth of a title bar); then they are dragged with the main windows, keeping the same relative position. If I rearrange them, from now on they drag correctly, but if I "save settings", close WB, relaunch it, I can reproduce the same behaviour.


Well, this sounds very pathological. The way it works is that WinBoard, on moving or sizingof the main window asks the OS its new coordinates and dimensions, and then calculates where the windows that were touching it should go to keep touching. I am sure the calculation is OK, because for me it works flawlessly. If on some Windows version it does not work, it can only because the OS islying about the coordinates when it requests them, or not positioning in accordance with the cordinates it was sent (or both). I must say that originally this Winboard_x feature was broken in Win XP, while it worked on Win 2k, and I had to debug that. It turned out that it was counting on getting coordinates of the old position after it had already moved, which in Win 2k amazingly worked, because there apparently was some lag, but not in XP or Vista. I changed it to use the stored coordiantes, which were also available, and then it worked both on 2k and XP. But some Windows versions apparently do behave fishy in this area.

2. If I attach a window on another window other than the main one, it doesn't get sticked (e.g. If I put Engine Output on the right of Main, and then Move History on the right of Engine Output).


This is as designed. Only windows that share an edge with the main window will be dragged along. Note, however that they can "virtually touch", when two edges are on the same line, butdisplaced along it so much that there is no physical contact.

3. If I attach a window _below_ Main, it gets sticked and drags with it, but if I "save settings", close WB, relaunch it, and try to drag Main, the window attached below doesn't drag.


This sounds again very much like the OS is abusing the coordinates. It can be checked in the winboard.ini if the stored settings contain touching windows. All window coordinates (upper-left corners) are stored relative to the main window, and the size of the main window is stored as well. On restarting that size need not be the same (you could have asked for another /boardSize, or play a /variant with another board format), but the coordinates of windows below or to the right of the main window are adapted to such a size change, so you can safely stick on all sides. So in the settings file you can see if the y coordinates of the window stuck on below is indeed equal to the given height of the main window. If not, it must have been stored wrong (becausetheOS has been lying aboutthem), while if they are, the OS is apparently not obeying the window-positioning instructions.

Note that (1) and (3) happens even if I detach and reattach the windows as soon as I start WB; I need to drag Main window at least once, and then detaching-reattaching cures things.

I hope this can help.
Cheers,
    Giorgio
[/quote]
User avatar
H.G.Muller
 
Posts: 3453
Joined: 16 Nov 2005, 12:02
Location: Diemen, NL

Re: How to dock/glue all sub windows together when moving?

Postby Giorgio Medeot » 09 Aug 2011, 13:46

Hi,
I have observed a couple of things maybe worth of noting: first, the erratic behaviour manifests on the first drag, OR after performing a save settings (so no need to close and relaunch the application). If, after the first drag, I rearrange the windows they keep on move correctly until I save the settings again: so my guess is it must be something happening when settings are saved.
Second thing is a little bit more interesting: the problem actually is triggered by the fact that I placed the windows task bar on the top edge of my screen. If I put it on the bottom - as it is usual - no weird things happen, nor if I put it on the right edge. In fact, with the task bar placed on top, at the first drag the auxiliary windows seem to start 30 pixels lower than the main (which also detach the window, if placed on the bottom of the main one), that is, the heigth of the bar; instead, with the task bar placed on the left, the windows are horizontally misplaced by the width of the bar.

Now, I would bet there are not that many winboarder around who like to place their task bar on the top edge, but still, as it could be broken even on Vista or Seven, I think it should be at least worth testing: it would be a very minor bug and could well stay there, but better knowing than not... ;)

Cheers,
    Giorgio
Giorgio Medeot
 
Posts: 26
Joined: 31 Aug 2009, 11:01

Re: How to dock/glue all sub windows together when moving?

Postby H.G.Muller » 09 Aug 2011, 18:05

Well, when saving the settings WinBoard requests the window coordinates from the OS, to save them in the file. Apparently there is a bug in your Windows version which causes it to not consistently subtract the width of the task bar from the Y coordinate...
User avatar
H.G.Muller
 
Posts: 3453
Joined: 16 Nov 2005, 12:02
Location: Diemen, NL


Return to Winboard and related Topics

Who is online

Users browsing this forum: No registered users and 12 guests

cron