window: Add new tiling code

Desktop / GNOME / Mutter - Jasper St. Pierre [mecheye.net] - 9 January 2016 20:09 UTC

The new tiling code, instead of based around "tiling states", is instead based around constrained edges. This allows us to have windows that have three constrained edges, but keep one free-floating, e.g. a window tiled to the left has the left, top, and bottom edges constrained, but the right edge can be left resizable.

This system also is easily extended to support corner tiling. We also, using the new "size state" system, also keep normal, tiled, and maximized sizes independently, allowing the maximize button to bounce between maximized and tiled states without reverting to normal in between. Dragging from the top will always restore the normal state, though.

https://bugzilla.gnome.org/show_bug.cgi?id=751857

50e3e3b window: Add new tiling code
src/core/constraints.c | 46 +++++++-
src/core/keybindings.c | 2 +
src/core/screen-private.h | 17 ++-
src/core/screen.c | 54 +++++++---
src/core/window-private.h | 5 +-
src/core/window.c | 261 +++++++++++++++++++++++++++++++++++++++------
src/meta/common.h | 20 ++++
src/meta/window.h | 3 +
8 files changed, 353 insertions(+), 55 deletions(-)

Upstream: git.gnome.org


  • Share