Keyboard capture for VNC from qube to external host

When you install Remmina or another VNC or RDP client inside a qube, many keyboard shortcuts like ctrl-tab are forwarded just fine. However, alt-tab is never forwarded to the VNC session. I understand that this is a security feature of Qubes OS. But I would like to temporarily disable that security feature for one specific qube. I read on GitHub about a similar feature-request that some games require mouse capture, see

Of course you could reconfigure the dom0 xfce shortcuts to not conflict with the ones you want to use via remote desktop connections, or remap keyboard shortcuts in the qube or on the remote computer, as explained in Though, I don’t like this workaround much.

As alternative, I’ve been thinking of installing a small VNC/RDP client in dom0. To add security, you could add a “hop-server”. For example, a VNC connection from dom0 to a qube called “vnc-hop” over qvm-connect-tcp, and then an RDP connection from “vnc-hop” to the external computer. That would prevent potential vulnerabilities in the RDP client leading to dom0 compromise. But installing extra software in dom0 is generally discouraged. What is your opinion on this use-case?

Some type 2 hypervisors have a feature for keyboard capture. When activated, most keystrokes and keyboard shortcuts are forwarded to the VM. You can toggle this mode with a global keyboard shortcut, like VirtualBox has right-ctrl as host key by default. How to reach something similar in Qubes OS?

Thanks for the link.

Though I ended up with a different approach. A python script that subscribes to Wnck active-window-changed. When the VNC client window receives focus, it disables many keyboard shortcuts with xfconf-query including alt-tab and ones for the super key. When another window becomes active, the script enables the xfce4 keyboard shortcuts again.