GNOME Bugzilla – Bug 677106
Enable on-screen-keyboard if no kbd is found
Last modified: 2014-08-29 16:28:54 UTC
It would be good if we'd automatically show an on-screen keyboard if no real keyboard is plugged in but a pointing device/touch screen is. Unless the user explicitly turned off or turned on the on-screen keyboard this should be the automatic logic. Since users can plug in keyboards at any time this logic needs to follow the current hotplug state. Note that the logic that detects whether a keyboard is plugged in should probably ignore input devices such as ACPI buttons, and look for real keyboards only (maybe consider only input devices that have at least the following keys: 'G', 'N', 'O', 'M', 'E'? Sounds much nicer to look for specific keys than to filter by driver name or so). Moreover, it probably is a good idea to store whether the on-screen keyboard is explicitly enabled/disabled by the user individually for seats. i.e. use the "Xorg_Seat" root window property to find the seat identifier, and then store the user choice for each seat individually. Seat names are stable so that this works correctly. This is useful for setups where a multitude of different seats are plugged into the same machine. For example a PC with one built-in classic seat of screen, mouse, keyboard, plus one MIMO device which is a seat of a screen and touchscreen (http://www.mimomonitors.com/). On the first seat you want no on-screen keyboard, on the second one you do, and it would be great if this would work automatically, and if the user undoes the change stays that way individually.
I think this probably goes to gnome-settings-daemon, who already watches over keyboards coming and going...
We have no way of detecting whether there are keyboards present reliably as most devices will show you a "PS/2 keyboard" type interface even if no keyboards are plugged into the system. But I guess this doesn't mean that we cannot make this work when the hardware is well-behaved.
Also, in multi-seat scenarios there might be seats actually really lacking a kbd... For example, if you plug in a MIMO display (as mentioned above) you get a seat with no kbd but with touch device... Also, most BIOSes are capable of detecting whether there's something connected to the atkbd controller... If the BIOS can do that, Linux could too? Maybe we can hook that up with xinput?
(In reply to comment #3) > Also, in multi-seat scenarios there might be seats actually really lacking a > kbd... For example, if you plug in a MIMO display (as mentioned above) you get > a seat with no kbd but with touch device... In multi-seat env. the split would already be made before, and only the devices pertaining to that seat would appear through xinput. > Also, most BIOSes are capable of detecting whether there's something connected > to the atkbd controller... If the BIOS can do that, Linux could too? Maybe we > can hook that up with xinput? Sure, the problem being horrible legacy hardware of which there is plenty. At the end of the day, we only use XInput's view of the available devices.
Bug 692771 has the gnome-settings-daemon patches for that. *** This bug has been marked as a duplicate of bug 692771 ***