This request is to add a new feature to this wm that lets windows be arranged by drag-and-drop. (re: #43)
With this, the wm will be able to move the drag-and-drop-ed window to the position where seems to be most intuitive according to the position where the window was released.
We consider four cases to select to where move the window.
Container
To make explanation easy before our looking up the four cases, I'll introduce the concept of containers.
We call it container that is a sequence of windows (or other intenal containers) which are tiled vertically or horizontally.
That is the containers are equivalent to the internal/root nodes in the client tree.
Arrangement Methods
1 Insertion (Inner)
When a window is released near the spaces between windows in the container or the end of the container,
the wm inserts the window to the container.
2 Insertion (Outer)
When a window is released on the side of the continer, the wm inserts the window beside the container.
3 Splitting
When a window is released on the middle (neither center nor edge) area of another tiling window,
the wm replaces the window with a new container containing those two windwos.
4 Swapping
When a window is released on the center of another window or on the another floating window, then the wm swaps those two windows.
Hint of Inside
Discussing more formally, we divide the window (and gaps around it) into some areas to determinate how to move the dropped window as shown below.
Assuming that the window is tiled horizontally, then the red area causes the first pattern we discussed above, the orrange area causes the second pattern, the green or blue areas cause the third, and the yellow causes the fourth.
Overview
This request is to add a new feature to this wm that lets windows be arranged by drag-and-drop. (re: #43) With this, the wm will be able to move the drag-and-drop-ed window to the position where seems to be most intuitive according to the position where the window was released. We consider four cases to select to where move the window.
Container
To make explanation easy before our looking up the four cases, I'll introduce the concept of containers. We call it container that is a sequence of windows (or other intenal containers) which are tiled vertically or horizontally. That is the containers are equivalent to the internal/root nodes in the client tree.
Arrangement Methods
1 Insertion (Inner)
When a window is released near the spaces between windows in the container or the end of the container, the wm inserts the window to the container.
2 Insertion (Outer)
When a window is released on the side of the continer, the wm inserts the window beside the container.
3 Splitting
When a window is released on the middle (neither center nor edge) area of another tiling window, the wm replaces the window with a new container containing those two windwos.
4 Swapping
When a window is released on the center of another window or on the another floating window, then the wm swaps those two windows.
Hint of Inside
Discussing more formally, we divide the window (and gaps around it) into some areas to determinate how to move the dropped window as shown below.
Assuming that the window is tiled horizontally, then the red area causes the first pattern we discussed above, the orrange area causes the second pattern, the green or blue areas cause the third, and the yellow causes the fourth.
Thank you!