Comment 1 for bug 801073

Florian Boucault (fboucault) wrote :

Xlib and Xkb do not provide any API that would allow us to solve the issue but XInput seems to.

$ xinput test DEVICE_ID

where DEVICE_ID is your keyboard's id allows one to monitor any keypress without the need for grabs