tarkah / grout

Simple tiling window manager for Windows
MIT License
205 stars 8 forks source link

Full Keyboard support #38

Open mborejdo opened 4 years ago

mborejdo commented 4 years ago

Hey! Thanks for grout! I am wondering, if a "full keyboard mode" would be possible. I am thinking about something like:

  1. Hotkey to show grout controls
  2. Numbered or lettered "areas" e.g. 1,2,3,4 on a 2x2 Layout, type number/letter
  3. To select multiple areas, type Shift + Number/letter

This would work properly for 3x3 Grids with numbers.

tarkah commented 4 years ago

Thanks for the feature request! The biggest issue I see here is that you can't assign to more than 9 zones (3x3 grid) using numbers. I'm hesitant to try and implement a solution that doesn't work for all configurations.

What about using the arrow keys to move / resize the window along the grid? The problem I see here is that I can't capture the arrow keys once focus is moved away from the grid to a window. So initially it'll work, but if you alt-tab to another window, or click on a window, the keyboard based movements will no longer work. Unless I make this mode aggressively steal back focus to always capture key inputs until disabled.

matthjes commented 3 years ago

This would be a great improvement! I would suggest not using numbers but letters, this would maybe be easier and you can have 26 zones. If more zones are needed you could start using two letters.

Maybe use two key presses: one for the uppler left corner, one for the lower right corner. Here is an example.

Untitled Diagram(1)

To move a window to the highlighted area I would simply enter "bt".

But I can see your argument that this could only work for the "show grid, enter coordinates, hide grid" scenario.

eugenesvk commented 2 years ago

I'd like to suggest user-predefined-area shortcuts rather than trying to cover all the box combos. It's based on the idea that there is a small subset of areas that cover most of your needs, so you can map those an easier to remember set of shortcuts It's also mostly focused on a a single/couple of apps rather than the more complicated positioning of multiple apps at once, though that's for me also the most common use case, so it's in general much faster

For example:

Win` for a hotkey_quick_resize Then press either of these:

Would also be great if you could mark some shortcuts are requiring "hints" that would show in the grid (e.g. you'd likely never need a hint that f is fullscreen, but for something a bit more rarely/not yet memorized you might)