2 .\" Copyright 1999 Oracle and/or its affiliates. All rights reserved.
4 .\" Permission is hereby granted, free of charge, to any person obtaining a
5 .\" copy of this software and associated documentation files (the "Software"),
6 .\" to deal in the Software without restriction, including without limitation
7 .\" the rights to use, copy, modify, merge, publish, distribute, sublicense,
8 .\" and/or sell copies of the Software, and to permit persons to whom the
9 .\" Software is furnished to do so, subject to the following conditions:
11 .\" The above copyright notice and this permission notice (including the next
12 .\" paragraph) shall be included in all copies or substantial portions of the
15 .\" THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 .\" IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 .\" FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
18 .\" THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 .\" LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
20 .\" FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
21 .\" DEALINGS IN THE SOFTWARE.
23 .TH XkbSetAccessXTimeout __libmansuffix__ __xorgversion__ "XKB FUNCTIONS"
25 XkbSetAccessXTimeout \- Configures the AccessXTimeout options for a keyboard
29 .B Bool XkbSetAccessXTimeout
30 .BI "(\^Display *" "display" "\^,"
31 .BI "unsigned int " "device_spec" "\^,"
32 .BI "unsigned short " "timeout" "\^,"
33 .BI "unsigned int " "ctrls_mask" "\^,"
34 .BI "unsigned int " "ctrls_values" "\^,"
35 .BI "unsigned short " "opts_mask" "\^,"
36 .BI "unsigned short " "opts_values" "\^);"
42 connection to X server
45 device to configure, or XkbUseCoreKbd
48 seconds idle until AccessXTimeout occurs
51 boolean controls to modify
54 new bits for controls selected by ctrls_mask
60 new bits for ax_options selected by opts_mask
63 In environments where computers are shared, features such as SlowKeys present a
64 problem: if SlowKeys is on, the keyboard can appear to be unresponsive because
65 keys are not accepted until they are held for a certain period of time. To help
66 solve this problem, Xkb provides an AccessXTimeout control to automatically
67 change the enabled/disabled state of any boolean controls and to change the
68 value of the AccessXKeys and AccessXFeedback control attributes if the keyboard
69 is idle for a specified period of time.
71 When a timeout as specified by AccessXTimeout occurs and a control is
72 consequently modified, Xkb generates an XkbControlsNotify event. For more
73 information on XkbControlsNotify events.
76 specifies the number of seconds the keyboard must be idle before the controls
79 specifies what controls are to be enabled or disabled, and
81 specifies whether those controls are to be enabled or disabled. The bit values
82 correspond to those for enabling and disabling boolean controls using
83 .I XkbChangeEnabledControls.
86 field specifies which attributes of the AccessXKeys and AccessXFeedback controls
87 are to be changed, and
89 specifies the new values for those options. The bit values correspond to those
92 field of an XkbDescRec.
94 .I XkbSetAccessXTimeout
95 sends a request to configure the AccessXTimeout control to the server. It does
96 not wait for a reply, and normally returns True. If a compatible version of the
97 Xkb extension is not available in the server,
98 .I XkbSetAccessXTimeout
104 .I XkbSetAccessXTimeout
105 function returns True when a compatible version of the Xkb extension is available in the server.
109 .I XkbSetAccessXTimeout
110 function returns False when a compatible version of the Xkb extension is not available in the server.
113 The complete description of an Xkb keyboard is given by an XkbDescRec. The component
114 structures in the XkbDescRec represent the major Xkb components.
118 struct _XDisplay * display; /\(** connection to X server */
119 unsigned short flags; /\(** private to Xkb, do not modify */
120 unsigned short device_spec; /\(** device of interest */
121 KeyCode min_key_code; /\(** minimum keycode for device */
122 KeyCode max_key_code; /\(** maximum keycode for device */
123 XkbControlsPtr ctrls; /\(** controls */
124 XkbServerMapPtr server; /\(** server keymap */
125 XkbClientMapPtr map; /\(** client keymap */
126 XkbIndicatorPtr indicators; /\(** indicator map */
127 XkbNamesPtr names; /\(** names for all components */
128 XkbCompatMapPtr compat; /\(** compatibility map */
129 XkbGeometryPtr geom; /\(** physical geometry of keyboard */
130 } XkbDescRec, *XkbDescPtr;
135 field points to an X display structure. The
136 .I flags field is private to the library: modifying
138 may yield unpredictable results. The
140 field specifies the device identifier of the keyboard input device, or
141 XkbUseCoreKeyboard, which specifies the core keyboard device. The
145 fields specify the least and greatest keycode that can be returned by the keyboard.
147 Each structure component has a corresponding mask bit that is used in function calls to
148 indicate that the structure should be manipulated in some manner, such as allocating it
149 or freeing it. These masks and their relationships to the fields in the XkbDescRec are
156 Table 1 Mask Bits for XkbDescRec
158 Mask Bit XkbDescRec Field Value
160 XkbControlsMask ctrls (1L<<0)
161 XkbServerMapMask server (1L<<1)
162 XkbIClientMapMask map (1L<<2)
163 XkbIndicatorMapMask indicators (1L<<3)
164 XkbNamesMask names (1L<<4)
165 XkbCompatMapMask compat (1L<<5)
166 XkbGeometryMask geom (1L<<6)
167 XkbAllComponentsMask All Fields (0x7f)
170 The structure for the XkbControlsNotify event is defined as follows:
174 int type; /\(** Xkb extension base event code */
175 unsigned long serial; /\(** X server serial number for event */
176 Bool send_event; /\(** True => synthetically generated */
177 Display * display; /\(** server connection where event generated */
178 Time time; /\(** server time when event generated */
179 int xkb_type; /\(** XkbCompatMapNotify */
180 int device; /\(** Xkb device ID, will not be XkbUseCoreKbd */
181 unsigned int changed_ctrls; /\(** bits indicating which controls data have changed*/
182 unsigned int enabled_ctrls; /\(** controls currently enabled in server */
183 unsigned int enabled_ctrl_changes; /\(** bits indicating enabled/disabled controls */
184 int num_groups; /\(** current number of keyboard groups */
185 KeyCode keycode; /\(** != 0 => keycode of key causing change */
186 char event_type; /\(** Type of event causing change */
187 char req_major; /\(** major event code of event causing change */
188 char req_minor; /\(** minor event code of event causing change */
189 } XkbControlsNotifyEvent;
193 .BR XkbChangeEnabledControls (__libmansuffix__)