File: XIQueryVersion.man

package info (click to toggle)
libxi 2%3A1.8.2-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 3,528 kB
  • sloc: xml: 9,446; ansic: 7,627; sh: 4,402; makefile: 244
file content (181 lines) | stat: -rw-r--r-- 4,294 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
'\" t
.\"     Title: xiqueryversion
.\"    Author: [FIXME: author] [see http://www.docbook.org/tdg5/en/html/author]
.\" Generator: DocBook XSL Stylesheets vsnapshot <http://docbook.sf.net/>
.\"      Date: 09/05/2024
.\"    Manual: \ \&
.\"    Source: \ \&
.\"  Language: English
.\"
.TH "XIQUERYVERSION" "libmansuffix" "09/05/2024" "\ \&" "\ \&"
.\" -----------------------------------------------------------------
.\" * Define some portability stuff
.\" -----------------------------------------------------------------
.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.\" http://bugs.debian.org/507673
.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html
.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.ie \n(.g .ds Aq \(aq
.el       .ds Aq '
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.\" -----------------------------------------------------------------
.\" * MAIN CONTENT STARTS HERE *
.\" -----------------------------------------------------------------
.SH "NAME"
XIQueryVersion \- announce and query the support XI2 version\&.
.SH "SYNOPSIS"
.sp
.nf
#include <X11/extensions/XInput2\&.h>
.fi
.sp
.nf
Status XIQueryVersion( Display *display,
                       int *major_version_inout,
                       int *minor_version_inout);
.fi
.sp
.nf
display
       Specifies the connection to the X server\&.
.fi
.sp
.nf
major_version_inout
       Specifies the client\*(Aqs supported XI2 version, and
       returns the server\*(Aqs supported version\&.
.fi
.sp
.nf
minor_version_inout
       Specifies the client\*(Aqs supported XI2 version, and
       returns the server\*(Aqs supported version\&.
.fi
.SH "DESCRIPTION"
.sp
.if n \{\
.RS 4
.\}
.nf
XIQueryVersion announces the client\*(Aqs supported XI2 version to
the server and returns server\*(Aqs supported X Input version\&. Clients
are required to use XIQueryVersion instead of XGetExtensionVersion
if they use XI2 calls\&. The server may treat a client differently
depending on the supported version announced by the client\&.
The major_version_inout must be 2 or greater, otherwise a BadValue
error occurs\&.
.fi
.if n \{\
.RE
.\}
.sp
.if n \{\
.RS 4
.\}
.nf
If the server does not support XI2, XIQueryVersion returns BadRequest
to the client\&. Otherwise, XIQueryVersion returns Success\&. In both
cases major_version_inout and minor_version_inout are set to the
server\*(Aqs supported version\&.
.fi
.if n \{\
.RE
.\}
.sp
.if n \{\
.RS 4
.\}
.nf
If the client has previously called XIQueryVersion, then the result
depends on the previously requested version and the currently
requested version\&.
.fi
.if n \{\
.RE
.\}
.sp
.if n \{\
.RS 4
.\}
.nf
If either the previous or current requested versions is less than
2\&.2, or if the requested major version numbers do not match, then
consecutive calls to XIQueryVersion by the same client always
return the first returned major\&.minor version\&. If the client
requests a version lower than the first returned major\&.minor
version in a subsequent call, a BadValue error occurs\&.
.fi
.if n \{\
.RE
.\}
.sp
.if n \{\
.RS 4
.\}
.nf
If all of the requested versions are 2\&.2 or greater, then
consecutive calls to XIQueryVersion by the same client with the
same major version will return the requested version, but the server
will operate according to the highest requested version number or
the highest supported version, whichever is lower\&.
.fi
.if n \{\
.RE
.\}
.sp
.if n \{\
.RS 4
.\}
.nf
XIQueryVersion can generate a BadValue error\&.
.fi
.if n \{\
.RE
.\}
.SH "EXAMPLES"
.sp
.if n \{\
.RS 4
.\}
.nf
int rc;
int major = 2;
int minor = 0;
.fi
.if n \{\
.RE
.\}
.sp
.if n \{\
.RS 4
.\}
.nf
rc = XIQueryVersion(dpy, &major, &minor);
if (rc == Success)
    printf("XI2 supported\&. (%d\&.%d)\en", major, minor);
else if (rc == BadRequest)
    printf("No XI2 support\&. (%d\&.%d only)\en", major, minor);
else
    printf("Internal error\en");
.fi
.if n \{\
.RE
.\}
.SH "DIAGNOSTICS"
.sp
.if n \{\
.RS 4
.\}
.nf
BadValue
       A value is outside of the permitted range\&.
.fi
.if n \{\
.RE
.\}