This page is a general info page about the X Input Extension 2.x.
XI2 provides a number of features over the previous X Input Extension 1.x:
- Explicit support for the master/slave device hierarchy. In X servers supporting XI2 there are two general types of devices - master devices and slave devices. Slave devices (SDs) usually represent a physical input device connected to the host computer. Master devices (MDs) are virtual input devices that are controlled by the physical input devices. Master devices appear as master pointers (i.e. a visible cursor) and master keyboards (i.e. a keyboard focus). Each time an SD generates an event, this event is passed through the MD to the respective application.
- Support for multiple master devices. XI2 provides applications with the ability to create additional pairs of master devices (i.e one cursor and one keyboard focus). Through dynamic reattachment of SDs applications can control which physical device controls which visible cursor/keyboard focus. This allows multiple co-located users to collaborate on a single screen.
- Support for 32 bit keycodes. Many multimedia keys cannot be processed in current X servers as the core protocol limits keycodes to a maximum of 255. Applications built against XI2 may receive keycodes up to 32 bit.
- Support for latched/locked/base modifiers in input events.
- Support for sub-pixel coordinates in input events.
- Support for dynamic devices. Device may change capabilities at runtime (e.g. attaching additional buttons)
- Support for relative motion events
- Simplified API for retrieving device information and selecting and receiving input events.
API Documentation: http://cgit.freedesktop.org/xorg/lib/libXi/tree/man
Protocol extension specification: http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XI2proto.txt
XI2 recipes for a general intro into how to program:
Please add the required feature followed by an explanation what this feature is and why this is needed by your application. Do not add features here without discussing them on the xorg-devel mailing list first.
- = See Also =