New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unable to bind any hotkey under GNOME/Wayland #1642
Comments
When running in verbose mode, I see messages like this:
I wanted to see what was going wrong, so I decided to track this along...
Well, that doesn't look good.
That doesn't look so good either. |
I guess this is due to wayland not supporting hotkeys, so keybinder won't work at all anymore unless you are using XWayland, which is apparently not the case for F30, gnome and gtk3 apps now. That's my understanding right now, anyway. |
I believe I have a similar issue. After updating my system I now get errors when starting up Guake that complain about not being able to bind my "Toggle Guake" hotkey (in my case, that's super+enter).
|
Workaround I stole from #1340 : I've bound super+enter to just "guake" in Gnome. |
So, two things:
I suppose the only path forward right now is to wait for GNOME to offer a hotkey binding service under wayland. |
I went through about the first seven pages of issues (Back to about ~900): These are all effectively duplicates for the "Wayland Hotkey Bug": There are some RFEs on how to remedy it: Various other hotkey issues that are not necessarily related: @gsemet Would you like assistance with github issue triage? I'm willing to spend some time trying to clean up the issue tracker. |
Hi. Thanks. No pbl, if you want to be able to do a little bit of triage. Not enough time from my side to do this. I never used wayland so it is very difficult for me to debug anything related to it. So appart from documenting the work arround, there is no much what I can do. Just go in the ticket and @gsemet me in the ticket you want me to update. If you do good job I'll give you the permission to do it on your own :) |
So, I'm having the same issue here. Asking because here I cannot open Guake anymore (I cannot bind any key to do that). It will be very hard to keep working with Guake this way. =/
|
As suggested by @aurora-of-earth in #1640, under GNOME you can use the following workaround.
|
The workaround works well in single monitor setups. Has varying issues when your active display is not 0 or main though... |
Had the same problem on ubuntu 19.10, did like descibed in #1640, works fine now |
Solution in #1640 is not valid in Fedora 31 (show: works properly / hide: glitch, often the terminal disappear and re-appear) |
Pull request welcome. I do not use wayland so I cannot test anything :( |
I believe it is simply not possible to bind hotkeys on Wayland. This seems to be seen as a security precaution (see albertlauncher/albert#309 for a longer discussion). It seems the best thing to do for now would be to show some note to Wayland users (potentially with a link to one of the related issues) and invest into implementing the GAction mentioned in #1343. |
(at least) in Fedora 31, a possible wordaround, is to simply use xorg instead of wayland clicking on the gear icon before login |
I'm having the same problem running Fedora 31 on Wayland.
but I want to change it a little:
The only annoying thing is that I'm unable to delete the toggle visibility shortcut in guake's settings itself, thus it's notifying me about being unable to bind the key on startup of the system. |
@j-frost and others in the thread with the same issue - the monitor problems are a separate issue. I can confirm that with 3.7.0 installed via |
You can use dconf-editor, apps/guake/keybindings/global/show-hide and set custom value to empty string. |
Setting it to empty string didn't work for me, but setting it to |
One problem with the settings approach is that if you have "hide on lose focus" checked, pressing the hotkey hides guake instead of makes it visible if it is on screen but not focused. It then requires a second key press to show it again. |
Here's a simple bash script you can add to your F-12 gnome keyboard shortcut. It handles the case where guake is not already open and opens it. Otherwise it just toggles it. # guake-toggle only prints to stdout if guake is active
if [ "$(guake-toggle)" == "" ]; then
# If guake isn't running, start it
guake &
# Also run guake-toggle with a delay to open guake
sleep 0.5;
guake-toggle;
fi Note: This doesn't work if using "Hide on lose focus" as pointed out by @gpeal |
@zevdg @gpeal one solution that fixed for me and don't need an extra key is adding with dconf an extra keybinding for guake-toggle. I also made an ansible script for that: - name: Add keybinding for Guake in Wayland
community.general.dconf:
key: "{{ item.key }}"
value: "{{ item.value }}"
state: present
with_items:
# values from gsettings list-recursively /org/gnome/settings-daemon/plugins/media-keys/custom-keybindings
- key: "/org/gnome/settings-daemon/plugins/media-keys/custom-keybindings"
value: ["/org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/guake/"]
- key: "/org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/guake/binding"
value: "'F12'"
- key: "/org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/guake/command"
value: "'/usr/bin/guake-toggle'"
- key: "/org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/guake/name"
value: "'Guake'" Ideally, guake could detect it is running on Wayland and manage himself custom keybindings. |
This did the trick for me! 😄 But I cannot say, how well this works with KDE, since I am using GNOME. For reference: |
Same, distressing to see the years-long issue that may be specific to Wayland and needs the externally-bound I think #1941 and #1942 only made some small changes, not the keybindings system re-implementation or other large changes that may have been mentioned elsewhere. What's strange is I was customizing keyboard shortcuts in GNOME along with this application, and they were all working before some system updates where I'm sure a bunch of packages changed, also including kernel patch version updates, but were only done days apart from a fresh installation a week or 2 ago. I have not performed other serious system changes like at the login screen changing the display server (protocol?) from Wayland to Xorg, or similar through user login shell environment variable changes either. Only messing with NVIDIA drivers where the latest was visually buggy. I just checked, and seems I only ever had that single version of guake, Just a note the relevant code using GTK bind is here: Line 211 in a084a1d
I had started to investigate the issue from pages like this one: https://askubuntu.com/questions/1128705/keyboard-shortcut-get-a-list-of-what-is-already-used My system info:
|
I seem to have this issue too. Gnome shortcuts don't list the key combo I want for Guake ( |
The changes in #1941 were fairly hefty and addressed something completely unrelated to this issue. Preventing programs from being able to pick up keyboard input when the program is not running is a "feature" of Wayland, binding |
Then at least don't show an error message at every launch leading users to believe such. The hotkeys section of the settings interface could also mention a message to this effect depending on display server (protocol?). |
Issue #2011 has been created to put first-time configuration for this on the to-do list |
I am using guake 3.6.3 on Fedora 30 under GNOME with Wayland.
When guake starts up, it renders the message "A problem happened when binding F12 key." and encourages me to pick a different key. The problem is that NO key appears to take at all, so I cannot toggle visibility.
This seems even worse than it used to be; where the hotkey would bind but would simply not work on wayland rendered windows.
I've tried completely resetting all gnome settings, guake settings, etc.
Expected behavior
I should be able to use a hotkey to open guake.
Actual behavior
No hotkey will bind. No key will toggle guake.
To Reproduce
I don't know. I'm using Fedora 30 as close to a vanilla configuration as I know how to create.
$ guake --support
Guake Version: 3.6.3
Vte Version: 0.56.3
Vte Runtime Version: 0.56.3
GTK+ Version: 3.24.10
GDK Backend: gi.GdkWaylandDisplay
Desktop Session: gnome
Display: wayland-0
RGBA visual: True
Composited: True
The text was updated successfully, but these errors were encountered: