1 XISELECTEVENTS(libmansuffix)
2 ============================
7 XISelectEvents, XIGetSelectedEvents - select for or get selected XI2 events on the window.
12 #include <X11/extensions/XInput2.h>
14 Status XISelectEvents( Display *display,
20 Specifies the connection to the X server.
26 Number of masks in masks.
31 XIEventMask *XIGetSelectedEvents( Display *display,
33 int *num_masks_return);
36 Specifies the connection to the X server.
39 Number of masks in the return value.
47 XI2 events must be selected using XISelectEvents.
49 XISelectEvents sets the event mask for this client on win.
50 Further events are only reported to this client if the event
51 type matches the selected event mask. The masks overrides the
52 previously selected event mask for the given device.
54 If deviceid is a valid device, the event mask is selected only
55 for this device. If deviceid is XIAllDevices or
56 XIAllMasterDevices, the event mask is selected for all devices
57 or all master devices, respectively. The effective event mask
58 is the bit-wise OR of the XIAllDevices, XIAllMasterDevices and
59 the respective device's event mask.
67 The mask_len specifies the length of mask in bytes. mask is a
68 binary mask in the form of (1 << event type). deviceid must be
69 either a device or XIAllDevices or XIAllMasterDevices. A client
70 may submit several masks with the same deviceid in one request
71 but only the last mask will be effective.
73 XISelectEvents can generate a BadValue, a BadDevice, and a
76 XIGetSelectedEvents returns the events selected by this client on the given
77 window. If no events were selected on this window, XIGetSelectedEvents
78 returns NULL and num_masks_return is set to 0. If an internal error occurs,
79 XIGetSelectedEvents returns NULL and num_masks_return is set to -1.
80 Otherwise, XIGetSelectedEvent returns the selected event masks for all
81 devices including the masks for XIAllDevices and XIAllMasterDevices
83 The caller must free the returned data using XFree().
90 A value is outside of the permitted range.
93 A value for a Window argument does not name a defined
97 An invalid device was specified. The device does not