root [transparent] window, transparent to keyboard events, possible with gtk ?

I’d like to write a kind of visual keyboard application and I would know if it’s possible with Gtk :

The application would run as a root transparent window, drawing an “on-screen” semi-transparent keyboard layout, which reacts to key events, but shouldn’t not capture it for itself, but let them delivered to “real” applications below… And the application shouldn’t event know about mouse events.

I’ve already done some small experiments with a root transparent window (running a compositor, picom here, to have transparency enabled), but I wonder if it’s possible to be transparent to key events ? Either getting them but giving them back to windows below, or not getting them at all (perhaps finding another way to get them on another level) ?

Also, I made my first experiments on gtk3, but wonder if it should be better to go directly on gtk4
(I’m using Debian 11, but read that gtk4 is available in experimental…)

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.