2 .\" Title: xiselectevents
3 .\" Author: [FIXME: author] [see http://docbook.sf.net/el/author]
4 .\" Generator: DocBook XSL Stylesheets v1.76.1 <http://docbook.sf.net/>
6 .\" Manual: [FIXME: manual]
7 .\" Source: [FIXME: source]
10 .TH "XISELECTEVENTS" "libmansuffix" "09/23/2011" "[FIXME: source]" "[FIXME: manual]"
11 .\" -----------------------------------------------------------------
12 .\" * Define some portability stuff
13 .\" -----------------------------------------------------------------
14 .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
15 .\" http://bugs.debian.org/507673
16 .\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html
17 .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
20 .\" -----------------------------------------------------------------
21 .\" * set default formatting
22 .\" -----------------------------------------------------------------
23 .\" disable hyphenation
25 .\" disable justification (adjust text to left margin only)
27 .\" -----------------------------------------------------------------
28 .\" * MAIN CONTENT STARTS HERE *
29 .\" -----------------------------------------------------------------
31 XISelectEvents, XIGetSelectedEvents \- select for or get selected XI2 events on the window\&.
35 #include <X11/extensions/XInput2\&.h>
39 Status XISelectEvents( Display *display,
47 Specifies the connection to the X server\&.
57 Number of masks in masks\&.
62 Specifies the window\&.
66 XIEventMask *XIGetSelectedEvents( Display *display,
68 int *num_masks_return);
73 Specifies the connection to the X server\&.
78 Number of masks in the return value\&.
83 Specifies the window\&.
91 XI2 events must be selected using XISelectEvents\&.
101 XISelectEvents sets the event mask for this client on win\&.
102 Further events are only reported to this client if the event
103 type matches the selected event mask\&. The masks overrides the
104 previously selected event mask for the given device\&.
114 If deviceid is a valid device, the event mask is selected only
115 for this device\&. If deviceid is XIAllDevices or
116 XIAllMasterDevices, the event mask is selected for all devices
117 or all master devices, respectively\&. The effective event mask
118 is the bit\-wise OR of the XIAllDevices, XIAllMasterDevices and
119 the respective device\*(Aqs event mask\&.
143 The mask_len specifies the length of mask in bytes\&. mask is a
144 binary mask in the form of (1 << event type)\&. deviceid must be
145 either a device or XIAllDevices or XIAllMasterDevices\&. A client
146 may submit several masks with the same deviceid in one request
147 but only the last mask will be effective\&.
157 XISelectEvents can generate a BadValue, a BadDevice, and a
168 XIGetSelectedEvents returns the events selected by this client on the given
169 window\&. If no events were selected on this window, XIGetSelectedEvents
170 returns NULL and num_masks_return is set to 0\&. If an internal error occurs,
171 XIGetSelectedEvents returns NULL and num_masks_return is set to \-1\&.
172 Otherwise, XIGetSelectedEvent returns the selected event masks for all
173 devices including the masks for XIAllDevices and XIAllMasterDevices
183 The caller must free the returned data using XFree()\&.
195 A value is outside of the permitted range\&.
206 A value for a Window argument does not name a defined
218 An invalid device was specified\&. The device does not