upload tizen2.0 source
[framework/uifw/xorg/lib/libx11.git] / man / xkb / XkbGetIndicatorState.man
1 .\" Copyright 1999 Oracle and/or its affiliates. All rights reserved.
2 .\"
3 .\" Permission is hereby granted, free of charge, to any person obtaining a
4 .\" copy of this software and associated documentation files (the "Software"),
5 .\" to deal in the Software without restriction, including without limitation
6 .\" the rights to use, copy, modify, merge, publish, distribute, sublicense,
7 .\" and/or sell copies of the Software, and to permit persons to whom the
8 .\" Software is furnished to do so, subject to the following conditions:
9 .\"
10 .\" The above copyright notice and this permission notice (including the next
11 .\" paragraph) shall be included in all copies or substantial portions of the
12 .\" Software.
13 .\"
14 .\" THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
15 .\" IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
16 .\" FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
17 .\" THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
18 .\" LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
19 .\" FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
20 .\" DEALINGS IN THE SOFTWARE.
21 .\"
22 .TH XkbGetIndicatorState __libmansuffix__ __xorgversion__ "XKB FUNCTIONS"
23 .SH NAME
24 XkbGetIndicatorState \- Obtains the current state of the keyboard indicators
25 .SH SYNOPSIS
26 .HP
27 .B Status XkbGetIndicatorState
28 .BI "(\^Display *" "display" "\^,"
29 .BI "unsigned int " "device_spec" "\^,"
30 .BI "unsigned int " "state_return" "\^);"
31 .if n .ti +5n
32 .if t .ti +.5i
33 .SH ARGUMENTS
34 .TP
35 .I \- display
36 connection to the X server
37 .TP
38 .I \- device_spec
39 device ID, or XkbUseCoreKbd
40 .TP
41 .I \- state_return
42 backfilled with a mask of the indicator state
43 .SH DESCRIPTION
44 .LP
45 Xkb allows applications to obtain information about indicators using two 
46 different methods. The first method, which is similar to the core X 
47 implementation, uses a mask to specify the indicators. The second method, which 
48 is more suitable for applications concerned with interoperability, uses 
49 indicator names. The correspondence between the indicator name and the bit 
50 position in masks is as follows: one of the parameters returned from
51 .I XkbGetNamedIndicators 
52 is an index that is the bit position to use in any function call that requires a 
53 mask of indicator bits, as well as the indicator's index into the 
54 XkbIndicatorRec array of indicator maps.
55
56 .I XkbGetIndicatorState 
57 queries the 
58 .I display 
59 for the state of the indicators on the device specified by the 
60 .I device_spec. 
61 For each indicator that is "turned on" on the device, the associated bit is set 
62 in 
63 .I state_return. 
64 If a compatible version of the Xkb extension is not available in the server,
65 .I XkbGetIndicatorState
66 returns a BadMatch error. Otherwise, it sends the request to the X server, 
67 places the state of the indicators into 
68 .I state_return, 
69 and returns Success. Thus the value reported by 
70 .I XkbGetIndicatorState 
71 is identical to the value reported by the core protocol.
72 .SH DIAGNOSTICS
73 .TP 15
74 .B BadMatch
75 A compatible version of Xkb was not available in the server or an argument has 
76 correct type and range, but is otherwise invalid
77 .SH "SEE ALSO"
78 .BR XkbGetNamedIndicators (__libmansuffix__)
79