Guake / guake

Drop-down terminal for GNOME
https://guake.github.io
GNU General Public License v2.0
4.37k stars 577 forks source link

Lose focus/toggle focus shortcut? #2181

Open justanhduc opened 1 year ago

justanhduc commented 1 year ago

Is there an option to lose focus to switch back to the app prior to guake? Since guake doesn't show on alt+tab, there is no keyboard shortcut to switch back the the previous app from guake and currently I have to use mouse for that. Please note that losing focus doesn't mean toggling visibility; the guake window is still there, but I can still work with another app.

I think it would be a nice feature if there hasn't been already.

Davidy22 commented 1 year ago

This would need to be something that you add to global shortcuts since it's a keyboard shortcut when guake doesn't have focus and Wayland blocks that. Been doing some testing and the gtk window .focus() functions seem to not actually do anything under wayland. The functionality can be approximated by hiding and showing the window, which grabs focus everywhere, but that's a little weird and also something that can already be done by hitting the show/hide button twice. Maybe there's another way it's done in wayland, though I'm somewhat blanking on finding any examples in wayland of programs that can grab focus without the user manually switching to them that I can use as reference aid

ferenczy commented 7 months ago

This is also driving me crazy! I often need to switch between Guake and some other window back and forth repeatedly without Guake losing the focus so I can still see it. Currently, without using the mouse, I have to press Alt+Tab, keep Alt pressed, and press Alt+Shift+Tab to move the focus where I need, which is super annoying.

The most simple solution would be to just add a configuration option to enable showing of Guake window on the taskbar, so it would also appear on the Alt+Tab list and allow me to switch between Guake and another window back and forth simply using Alt+Tab.

This would need to be something that you add to global shortcuts since it's a keyboard shortcut when guake doesn't have focus and Wayland blocks that.

@Davidy22 Why would you want to trigger the "Lose focus" action when the Guake already doesn't have the focus? Both the "Toggle Guake visibility" and "Show and focus Guake window" actions work when Guake doesn't have the focus, but the "Lose focus" would be the exact opposite.