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 XkbSAActionSetCtrls __libmansuffix__ __xorgversion__ "XKB FUNCTIONS"
25 XkbSAActionSetCtrls \- Sets the
35 .B void XkbSAActionSetCtrls
36 .BI "(\^XkbCtrlsAction " "act" "\^,"
37 .BI "unsigned int " "ctrls" "\^);"
43 action in which to set ctrls0-ctrls3
46 value to set in ctrls0-ctrls3
49 Actions associated with the XkbCtrlsAction structure change the state of the
54 field can have any one of the values shown in Table 1.
60 Table 1 Controls Action Types
65 A key press enables any boolean controls specified in the ctrls fields that were
66 not already enabled at
67 the time of the key press.
68 A key release disables any controls enabled by the key press.
69 This action can cause XkbControlsNotify events.
72 If the XkbSA_LockNoLock bit is not set in the flags field, a key press enables
73 any controls specified in
74 the ctrls fields that were not already enabled at the time of the key press.
76 If the XkbSA_LockNoUnlock bit is not set in the flags field, a key release
78 specified in the ctrls fields that were not already disabled at the time of the
81 This action can cause XkbControlsNotify events.
87 field is composed of the bitwise inclusive OR of the masks shown in Table 2.
93 Table 2 Control Action Flags
98 If set, and the action type is XkbSA_LockControls, the server only disables
101 XkbSA_LockNoUnlock T{
102 If set, and the action type is XkbSA_LockControls, the server only enables
107 The XkbSA_SetControls action implements a key that enables a boolean control
108 when pressed and disables it
109 when released. The XkbSA_LockControls action is used to implement a key that
110 toggles the state of a
111 boolean control each time it is pressed and released. The XkbSA_LockNoLock and
112 XkbSA_LockNoUnlock flags
113 allow modifying the toggling behavior to only unlock or only lock the boolean
117 .I ctrls0, ctrls1, ctrls2,
120 fields represent the boolean controls in the
122 field of the controls structure. Xkb macros, to convert between the two formats.
124 .I XkbSAActionSetCtrls
137 typedef struct _XkbCtrlsAction {
138 unsigned char type; /\(** XkbSA_SetControls, XkbSA_LockControls */
139 unsigned char flags; /\(** with type, controls enabling and disabling
141 unsigned char ctrls3; /\(** ctrls0 through ctrls3 represent the boolean
143 unsigned char ctrls2; /\(** ctrls0 through ctrls3 represent the boolean
145 unsigned char ctrls1; /\(** ctrls0 through ctrls3 represent the boolean
147 unsigned char ctrls0; /\(** ctrls0 through ctrls3 represent the boolean