PowerToys icon indicating copy to clipboard operation
PowerToys copied to clipboard

[FZ] - hotkey to switch focus between zones

Open mgpinf opened this issue 3 years ago • 22 comments

Description of the new feature / enhancement

Powertoys fancyzones shortcut or hotkey to switch between zones. Just like shortcuts to new feature of switching to next window in current zone, adding shortcuts to this would be nice :)

Scenario when this would be used?

Makes it convenient to switch between zones, rather than having to use alt+tab

Supporting information

No response

mgpinf avatar Dec 18 '21 18:12 mgpinf

What version are you using? 'cause this is already a thing. You can find it in the settings for individual (custom) zones.

Jay-o-Way avatar Dec 18 '21 23:12 Jay-o-Way

v0.51.1. Unable to view any option like hotkey to switch between zones. Any help would be appreciated

mgpinf avatar Dec 19 '21 04:12 mgpinf

I don't mean switching between layouts or opening the layout editor. I mean switching between zones, suppose a layout has 2 zones, I need a shortcut or hotkey to switch between 2 zones in the layout

mgpinf avatar Dec 19 '21 04:12 mgpinf

Oh sorry, i misread.

Jay-o-Way avatar Dec 19 '21 08:12 Jay-o-Way

I meant shortcut key to move between zones

mgpinf avatar Dec 19 '21 10:12 mgpinf

Ditto; this would be incredible and bring this ever so closer to a twm.

Specifically: the ability to switch the focused window based on the zone Further: the ability to exchange two windows

ianelletson avatar Dec 19 '21 17:12 ianelletson

I'm probably just very sceptic, but technically you can't really focus on a zone, just on a window. So, you mean you want a hotkey to focus to a different window in a specific zone? I'd circle back to Alt+Tab.

Jay-o-Way avatar Dec 20 '21 12:12 Jay-o-Way

Topmost window in a zone

mgpinf avatar Dec 20 '21 12:12 mgpinf

image Suppose, there are 2 zones, and I want to switch to zone 2 (currently in zone 1), my suggestion is that as long as there is a window in that zone, switch focus to topmost (the one that is displayed) in the new zone)

So, to switch to topmost window on zone2 from zone1, some combination of modifier keys with 2, should focus window on zone 2, likewise for zone1, if no window exists in that particular zone, focus should remain in the currently focused zone

mgpinf avatar Dec 20 '21 12:12 mgpinf

I feel like this is a really good idea, because alt tab to change window focus is kind of finicky when you have more than two windows. I was trying out a layout with three windows and sometimes if I want to switch between my current window and the window that I used before the window I used last time I would have to alt tab two times.

This is too complicated to remember if the window I want to use was the window I used last time or the window even older so I have to alt tab and make sure that I am focusing on the correct window. I think this would simplify things especially for layouts with more than two zones.

I remedied my desire for quick switching by changing my layout to a 2 window layout and just use win pgdn/pgup when I need to swap between window A and window B in my left zone

ninja542 avatar Dec 23 '21 05:12 ninja542

/dup https://github.com/microsoft/PowerToys/issues/492

crutkas avatar Mar 21 '22 05:03 crutkas

Hi! We've identified this issue as a duplicate of another one that already exists on this Issue Tracker. This specific instance is being closed in favor of tracking the concern over on the referenced thread. Thanks for your report!

ghost avatar Mar 21 '22 05:03 ghost

actually, i misread this, that was moving window to zone, this is gaining focus

crutkas avatar Mar 21 '22 05:03 crutkas

This issue has been marked as duplicate and has not had any activity for 1 day. It will be closed for housekeeping purposes.

ghost avatar Mar 22 '22 09:03 ghost

This seems like it would be very helpful for users who have many zones/windows/monitors. I would love to contribute if it's not being worked on already

ParshavKothary avatar Apr 12 '22 18:04 ParshavKothary

This sounds useful, I'll dig around and see how feasible this is to implement.

GOATS2K avatar Jun 30 '22 02:06 GOATS2K

This sounds extremely useful. Here's my current use case: 3 zones evenly stacked vertically on a vertical monitor. While on zone1 I can already cycle between the windows in zone1. I can also move the focused window from zone1 to other zones with the windows + arrow keys.

It would be great if rather than using alt + tab to cycle through my many windows system wide, I can use a shortcut to focus on the topmost window of the next zone, in this case I would simply cycle to zone 2, then to zone 3's topmost window, and then back to zone 1's topmost window.

Also, it would be cool if you can swap windows between zones. Example: Zones 1, 2, 3 all have a window on top. From Zone 1, I would use a shortcut like Win + Shift + direction arrow to evaluate a swap from the topmost window of Zone 2 (if I pressed down) or zone 3 (if I pressed up). Just like alt tab, the change would only actually complete once you let go of Windows + Shift.

cloudnothings avatar Sep 01 '22 00:09 cloudnothings

Check out GlazeWM, it's a very cool app and works very well for me.

https://github.com/lars-berger/GlazeWM

KiLLeRRaT avatar Sep 01 '22 21:09 KiLLeRRaT

Yep. +1 for this feature. It make the fancyzones more useful, and avoid distracting from using mouse to switch focus between programs within different zones in one layout, hope this issuse can be pushed forward more quickly. Many thanks!

sylph520 avatar Jun 04 '23 09:06 sylph520

+1 for this issue, would be incredibly useful

OreoLamp avatar Dec 11 '23 19:12 OreoLamp

I am willing to put some hours into this. The absence of having a working TWM on windows is the biggest blocker for me switching entirely from Linux to Windows as my base OS running linux inside WSL and ditch dual boot altogether. And Fancy Zones feels the most native from what I have tried so far.

nicolaiunrein avatar Jan 07 '24 23:01 nicolaiunrein

To add to this, in addition to having a shortcut for focusing each zone (e.g. using number keys), a way to focus zones based on relative position using arrow keys much like the current option for the Relative position Snap override would be very useful.

TheColorman avatar Jan 13 '24 15:01 TheColorman

Implemented basic support for this in a fork: https://github.com/cprusprus/PowerToys/commit/94fbca498bcbd0d52255d289514155f987433d3e

See commit comments for what works, what's still TODO, and building. I'm not sure I have time to get this PR ready but if someone wants to collab on that to submit the feature back let me know.

Also, #25831 is another dup of this thread.

cprusprus avatar Feb 19 '24 18:02 cprusprus

#16052 also seems related.

blm768 avatar Feb 21 '24 00:02 blm768