On kde there’s a feature where you can pass all keys to x11 apps and on hyprland you can specify which keys get globally passed to which apps and maybe all keys.
If all else fails you can create a script that uses obs sockets and runs as root to capture keys globally. They seem to be looking into a global keys portal though.
This is already possible
Mind elaborating a bit more?
On kde there’s a feature where you can pass all keys to x11 apps and on hyprland you can specify which keys get globally passed to which apps and maybe all keys.
If all else fails you can create a script that uses obs sockets and runs as root to capture keys globally. They seem to be looking into a global keys portal though.