nikitabobko / AeroSpace

AeroSpace is an i3-like tiling window manager for macOS
https://nikitabobko.github.io/AeroSpace/guide
MIT License
3.43k stars 52 forks source link

Feature request: restore-size command #282

Closed karadnik-flutterint closed 2 weeks ago

karadnik-flutterint commented 2 weeks ago

Hi, I want to propose a restore-size command

Use case: When i messed up the resizing of my tilings, i want to be able to restore it back to every app taking the same space in the respective parent.

Alternative approaches:

Use flatten-workspace-tree - it does resize all apps back to taking same amount of space, but it also resets the layout to only one parent and I need to recreate my layout.

Synopsis:

USAGE: restore-size [-h|--help] OPTIONS: -h, --help Print help

I am not a swift guy at all, but I am willing to work on this feature if it will be useful, Let me know!

nikitabobko commented 2 weeks ago

Hi! Such functionality is indeed would be nice to have #114 My favorite name for the command is balance-sizes

Feel free to submit a PR, it should be fairly easy to implement. You need to traverse the tiling tree, and call setWeight(parent.orientation, /*weight: */1) on every child of h_tiles and v_tiles

nikitabobko commented 2 weeks ago

Duplicate of #114