~jm-leddy/ubuntu/precise/x11proto-core/micmute

« back to all changes in this revision

Viewing changes to specs/encoding.xml

  • Committer: Bazaar Package Importer
  • Author(s): Cyril Brulebois
  • Date: 2010-11-06 02:33:18 UTC
  • mfrom: (1.1.11 upstream) (3.2.2 sid)
  • Revision ID: james.westby@ubuntu.com-20101106023318-kc4rr6wvm6gt6b0j
Tags: 7.0.19-1
* New upstream release.
* Bump xutils-dev build-dep for new macros.
* Add pkg-config build-dep.
* Add xmlto, xorg-sgml-doctools, and w3m build-dep for the specs.
* Pass --with-xmlto and --without-fop, we want html and txt only.
* Ship *.html, *.css, and *.txt from the doc directory.
* Kill *.xml in the doc directory, no point in shipping them.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
<appendix id="protocol_encoding">
 
2
<title>Protocol Encoding</title>
 
3
<!--
 
4
     The sections in this appendix correspond to their
 
5
     number counterparts in the protocol document.
 
6
-->
 
7
<sect1  id="syntactic_conventions_b">
 
8
<title>Syntactic Conventions</title>
 
9
 
 
10
<para>
 
11
All numbers are in decimal,
 
12
unless prefixed with #x, in which case they are in hexadecimal (base 16).
 
13
</para>
 
14
 
 
15
<para>
 
16
The general syntax used to describe requests, replies, errors, events, and
 
17
compound types is:
 
18
</para>
 
19
 
 
20
<literallayout class="monospaced">
 
21
   <emphasis role='bold'>NameofThing</emphasis>
 
22
   encode-form
 
23
   ...
 
24
   encode-form
 
25
</literallayout>
 
26
 
 
27
<para>
 
28
Each encode-form describes a single component.
 
29
</para>
 
30
<para>
 
31
For components described in the protocol as:
 
32
</para>
 
33
<literallayout class="monospaced">
 
34
   name: TYPE
 
35
</literallayout>
 
36
 
 
37
<para>
 
38
the encode-form is:
 
39
</para>
 
40
 
 
41
<literallayout class="monospaced">
 
42
   N     TYPE     name
 
43
</literallayout>
 
44
 
 
45
<para>
 
46
N is the number of bytes occupied in the data stream,
 
47
and TYPE is the interpretation of those bytes.
 
48
For example,
 
49
</para>
 
50
 
 
51
<literallayout class="monospaced">
 
52
   depth: CARD8
 
53
</literallayout>
 
54
 
 
55
<para>
 
56
becomes:
 
57
</para>
 
58
 
 
59
<literallayout class="monospaced">
 
60
   1     CARD8     depth
 
61
</literallayout>
 
62
 
 
63
<para>
 
64
For components with a static numeric value the encode-form is:
 
65
</para>
 
66
 
 
67
<literallayout class="monospaced">
 
68
   N     value     name
 
69
</literallayout>
 
70
 
 
71
<para>
 
72
The value is always interpreted as an N-byte unsigned integer.
 
73
For example,
 
74
the first two bytes of a
 
75
<emphasis role='bold'>Window </emphasis>
 
76
error are always zero (indicating an
 
77
error in general) and three (indicating the
 
78
<emphasis role='bold'>Window </emphasis>
 
79
error in particular):
 
80
</para>
 
81
 
 
82
<literallayout class="monospaced">
 
83
   1      0      Error
 
84
   1      3      code
 
85
</literallayout>
 
86
 
 
87
<para>
 
88
For components described in the protocol as:
 
89
</para>
 
90
 
 
91
<para>
 
92
name:
 
93
<emphasis role='bold'>{ Name1 ,..., </emphasis>
 
94
<emphasis role='bold'>NameI }</emphasis>
 
95
</para>
 
96
 
 
97
<para>
 
98
the encode-form is:
 
99
</para>
 
100
 
 
101
<literallayout class="monospaced">
 
102
   N          name
 
103
        value1 Name1
 
104
        ...
 
105
        valueI NameI
 
106
</literallayout>
 
107
 
 
108
<para>
 
109
The value is always interpreted as an N-byte unsigned integer.
 
110
Note that the size of N is sometimes larger than that strictly required
 
111
to encode the values.
 
112
For example:
 
113
</para>
 
114
 
 
115
<para>
 
116
class:
 
117
{ <emphasis role='bold'>InputOutput</emphasis>,
 
118
<emphasis role='bold'>InputOnly</emphasis>,
 
119
<emphasis role='bold'>CopyFromParent</emphasis> }
 
120
</para>
 
121
 
 
122
<para>
 
123
becomes:
 
124
</para>
 
125
 
 
126
<literallayout class="monospaced">
 
127
2               class
 
128
     0     CopyFromParent
 
129
     1     InputOutput
 
130
     2     InputOnly
 
131
</literallayout>
 
132
 
 
133
<para>
 
134
For components described in the protocol as:
 
135
</para>
 
136
 
 
137
<para>
 
138
NAME: TYPE or
 
139
<emphasis role='bold'>Alternative1 ...or</emphasis>
 
140
<emphasis role='bold'>AlternativeI</emphasis>
 
141
</para>
 
142
 
 
143
<para>
 
144
the encode-form is:
 
145
</para>
 
146
 
 
147
<literallayout class="monospaced">
 
148
N     TYPE               NAME
 
149
     value1     Alternative1
 
150
     ...
 
151
     valueI     AlternativeI
 
152
</literallayout>
 
153
 
 
154
<para>
 
155
The alternative values are guaranteed not to conflict with the encoding
 
156
of TYPE.
 
157
For example:
 
158
</para>
 
159
 
 
160
<para>
 
161
destination: WINDOW or
 
162
<emphasis role='bold'>PointerWindow </emphasis>
 
163
or
 
164
<emphasis role='bold'>InputFocus</emphasis>
 
165
</para>
 
166
 
 
167
<para>
 
168
becomes:
 
169
</para>
 
170
 
 
171
<literallayout class="monospaced">
 
172
4     WINDOW          destination
 
173
     0     PointerWindow
 
174
     1     InputFocus
 
175
</literallayout>
 
176
 
 
177
<para>
 
178
For components described in the protocol as:
 
179
</para>
 
180
 
 
181
<literallayout class="monospaced">
 
182
   value-mask: BITMASK
 
183
</literallayout>
 
184
 
 
185
<para>
 
186
the encode-form is:
 
187
</para>
 
188
 
 
189
<literallayout class="monospaced">
 
190
N     BITMASK               value-mask
 
191
     mask1     mask-name1
 
192
     ...
 
193
     maskI     mask-nameI
 
194
</literallayout>
 
195
 
 
196
<para>
 
197
The individual bits in the mask are specified and named,
 
198
and N is 2 or 4.
 
199
The most-significant bit in a BITMASK is reserved for use in defining
 
200
chained (multiword) bitmasks, as extensions augment existing core requests.
 
201
The precise interpretation of this bit is not yet defined here,
 
202
although a probable mechanism is that a 1-bit indicates that another N bytes
 
203
of bitmask follows, with bits within the overall mask still interpreted
 
204
from least-significant to most-significant with an N-byte unit,
 
205
with N-byte units
 
206
interpreted in stream order, and with the overall mask being byte-swapped
 
207
in individual N-byte units.
 
208
</para>
 
209
 
 
210
<para>
 
211
For LISTofVALUE encodings, the request is followed by a section of the form:
 
212
</para>
 
213
 
 
214
<literallayout class="monospaced">
 
215
   VALUEs
 
216
   encode-form
 
217
   ...
 
218
   encode-form
 
219
</literallayout>
 
220
 
 
221
<para>
 
222
listing an encode-form for each VALUE.
 
223
The NAME in each encode-form keys to the corresponding BITMASK bit.
 
224
The encoding of a VALUE always occupies four bytes,
 
225
but the number of bytes specified in the encoding-form indicates how
 
226
many of the least-significant bytes are actually used;
 
227
the remaining bytes are unused and their values do not matter.
 
228
</para>
 
229
 
 
230
<para>
 
231
In various cases, the number of bytes occupied by a component will be
 
232
specified
 
233
by a lowercase single-letter variable name instead of a specific numeric
 
234
value, and often some other component will have its value specified as a
 
235
simple numeric expression involving these variables.
 
236
Components specified with such expressions are always interpreted
 
237
as unsigned integers.
 
238
The scope of such variables is always just the enclosing request, reply,
 
239
error, event, or compound type structure.
 
240
For example:
 
241
</para>
 
242
 
 
243
<literallayout class="monospaced">
 
244
2      3+n                  request length
 
245
4n     LISTofPOINT          points
 
246
</literallayout>
 
247
 
 
248
<para>
 
249
For unused bytes (the values of the bytes are undefined and do no matter),
 
250
the encode-form is:
 
251
</para>
 
252
 
 
253
<literallayout class="monospaced">
 
254
   N               unused
 
255
</literallayout>
 
256
 
 
257
<para>
 
258
<!-- .LP -->
 
259
If the number of unused bytes is variable, the encode-form typically is:
 
260
</para>
 
261
 
 
262
<literallayout class="monospaced">
 
263
   p               unused, p=pad(E)
 
264
</literallayout>
 
265
 
 
266
<para>
 
267
where E is some expression,
 
268
and pad(E) is the number of bytes needed to round E up to a multiple of four.
 
269
</para>
 
270
 
 
271
<literallayout class="monospaced">
 
272
   pad(E) = (4 - (E mod 4)) mod 4
 
273
</literallayout>
 
274
</sect1>
 
275
 
 
276
<sect1 id="common_types_2">
 
277
<title>Common Types</title>
 
278
 
 
279
<variablelist>
 
280
  <varlistentry>
 
281
    <term>LISTofFOO</term>
 
282
    <listitem>
 
283
      <para>
 
284
In this document the LISTof notation strictly means some number of repetitions
 
285
of the FOO encoding;
 
286
the actual length of the list is encoded elsewhere.
 
287
      </para>
 
288
    </listitem>
 
289
  </varlistentry>
 
290
  <varlistentry>
 
291
    <term>SETofFOO</term>
 
292
    <listitem>
 
293
      <para>
 
294
A set is always represented by a bitmask, with a 1-bit indicating presence in
 
295
the set.
 
296
      </para>
 
297
    </listitem>
 
298
  </varlistentry>
 
299
</variablelist>
 
300
 
 
301
<informaltable frame='none'>
 
302
  <tgroup cols='1' align='left'>
 
303
  <colspec colname='c1' colsep="0"/>
 
304
  <tbody>
 
305
    <row rowsep='0'>
 
306
      <entry>
 
307
BITMASK: CARD32
 
308
      </entry>
 
309
    </row>
 
310
    <row rowsep='0'>
 
311
      <entry>
 
312
WINDOW: CARD32
 
313
      </entry>
 
314
    </row>
 
315
    <row rowsep='0'>
 
316
      <entry>
 
317
PIXMAP: CARD32
 
318
      </entry>
 
319
    </row>
 
320
    <row rowsep='0'>
 
321
      <entry>
 
322
CURSOR: CARD32
 
323
      </entry>
 
324
    </row>
 
325
    <row rowsep='0'>
 
326
      <entry>
 
327
FONT: CARD32
 
328
      </entry>
 
329
    </row>
 
330
    <row rowsep='0'>
 
331
      <entry>
 
332
GCONTEXT: CARD32
 
333
      </entry>
 
334
    </row>
 
335
    <row rowsep='0'>
 
336
      <entry>
 
337
COLORMAP: CARD32
 
338
      </entry>
 
339
    </row>
 
340
    <row rowsep='0'>
 
341
      <entry>
 
342
DRAWABLE: CARD32
 
343
      </entry>
 
344
    </row>
 
345
    <row rowsep='0'>
 
346
      <entry>
 
347
FONTABLE: CARD32
 
348
      </entry>
 
349
    </row>
 
350
    <row rowsep='0'>
 
351
      <entry>
 
352
ATOM: CARD32
 
353
      </entry>
 
354
    </row>
 
355
    <row rowsep='0'>
 
356
      <entry>
 
357
VISUALID: CARD32
 
358
      </entry>
 
359
    </row>
 
360
    <row rowsep='0'>
 
361
      <entry>
 
362
BYTE: 8-bit value
 
363
      </entry>
 
364
    </row>
 
365
    <row rowsep='0'>
 
366
      <entry>
 
367
INT8: 8-bit signed integer
 
368
      </entry>
 
369
    </row>
 
370
    <row rowsep='0'>
 
371
      <entry>
 
372
INT16: 16-bit signed integer
 
373
      </entry>
 
374
    </row>
 
375
    <row rowsep='0'>
 
376
      <entry>
 
377
INT32: 32-bit signed integer
 
378
      </entry>
 
379
    </row>
 
380
    <row rowsep='0'>
 
381
      <entry>
 
382
CARD8: 8-bit unsigned integer
 
383
      </entry>
 
384
    </row>
 
385
    <row rowsep='0'>
 
386
      <entry>
 
387
CARD16: 16-bit unsigned integer
 
388
      </entry>
 
389
    </row>
 
390
    <row rowsep='0'>
 
391
      <entry>
 
392
CARD32: 32-bit unsigned integer
 
393
      </entry>
 
394
    </row>
 
395
    <row rowsep='0'>
 
396
      <entry>
 
397
TIMESTAMP: CARD32
 
398
      </entry>
 
399
    </row>
 
400
  </tbody>
 
401
  </tgroup>
 
402
</informaltable>
 
403
 
 
404
 
 
405
<literallayout class="monospaced">
 
406
BITGRAVITY
 
407
     0     Forget
 
408
     1     NorthWest
 
409
     2     North
 
410
     3     NorthEast
 
411
     4     West
 
412
     5     Center
 
413
     6     East
 
414
     7     SouthWest
 
415
     8     South
 
416
     9     SouthEast
 
417
     10     Static
 
418
 
 
419
WINGRAVITY
 
420
     0     Unmap
 
421
     1     NorthWest
 
422
     2     North
 
423
     3     NorthEast
 
424
     4     West
 
425
     5     Center
 
426
     6     East
 
427
     7     SouthWest
 
428
     8     South
 
429
     9     SouthEast
 
430
     10     Static
 
431
 
 
432
BOOL
 
433
     0     False
 
434
     1     True
 
435
 
 
436
SETofEVENT
 
437
     #x00000001     KeyPress
 
438
     #x00000002     KeyRelease
 
439
     #x00000004     ButtonPress
 
440
     #x00000008     ButtonRelease
 
441
     #x00000010     EnterWindow
 
442
     #x00000020     LeaveWindow
 
443
     #x00000040     PointerMotion
 
444
     #x00000080     PointerMotionHint
 
445
     #x00000100     Button1Motion
 
446
     #x00000200     Button2Motion
 
447
     #x00000400     Button3Motion
 
448
     #x00000800     Button4Motion
 
449
     #x00001000     Button5Motion
 
450
     #x00002000     ButtonMotion
 
451
     #x00004000     KeymapState
 
452
     #x00008000     Exposure
 
453
     #x00010000     VisibilityChange
 
454
     #x00020000     StructureNotify
 
455
     #x00040000     ResizeRedirect
 
456
     #x00080000     SubstructureNotify
 
457
     #x00100000     SubstructureRedirect
 
458
     #x00200000     FocusChange
 
459
     #x00400000     PropertyChange
 
460
     #x00800000     ColormapChange
 
461
     #x01000000     OwnerGrabButton
 
462
     #xFE000000     unused but must be zero
 
463
 
 
464
SETofPOINTEREVENT
 
465
     encodings are the same as for SETofEVENT, except with
 
466
     #xFFFF8003     unused but must be zero
 
467
 
 
468
SETofDEVICEEVENT
 
469
     encodings are the same as for SETofEVENT, except with
 
470
     #xFFFFC0B0     unused but must be zero
 
471
 
 
472
KEYSYM: CARD32
 
473
KEYCODE: CARD8
 
474
BUTTON: CARD8
 
475
 
 
476
SETofKEYBUTMASK
 
477
     #x0001     Shift
 
478
     #x0002     Lock
 
479
     #x0004     Control
 
480
     #x0008     Mod1
 
481
     #x0010     Mod2
 
482
     #x0020     Mod3
 
483
     #x0040     Mod4
 
484
     #x0080     Mod5
 
485
     #x0100     Button1
 
486
     #x0200     Button2
 
487
     #x0400     Button3
 
488
     #x0800     Button4
 
489
     #x1000     Button5
 
490
     #xE000     unused but must be zero
 
491
 
 
492
SETofKEYMASK
 
493
     encodings are the same as for SETofKEYBUTMASK, except with
 
494
     #xFF00          unused but must be zero
 
495
STRING8: LISTofCARD8
 
496
STRING16: LISTofCHAR2B
 
497
 
 
498
CHAR2B
 
499
     1     CARD8     byte1
 
500
     1     CARD8     byte2
 
501
 
 
502
POINT
 
503
     2     INT16     x
 
504
     2     INT16     y
 
505
 
 
506
RECTANGLE
 
507
     2     INT16     x
 
508
     2     INT16     y
 
509
     2     CARD16    width
 
510
     2     CARD16    height
 
511
 
 
512
ARC
 
513
     2     INT16     x
 
514
     2     INT16     y
 
515
     2     CARD16    width
 
516
     2     CARD16    height
 
517
     2     INT16     angle1
 
518
     2     INT16     angle2
 
519
 
 
520
HOST
 
521
     1                         family
 
522
           0         Internet
 
523
           1         DECnet
 
524
           2         Chaos
 
525
           5         ServerInterpreted
 
526
           6         InternetV6
 
527
     1                         unused
 
528
     2      n                  length of address
 
529
     n      LISTofBYTE         address
 
530
     p                         unused, p=pad(n)
 
531
 
 
532
STR
 
533
     1      n                  length of name in bytes
 
534
     n      STRING8            name
 
535
 
 
536
</literallayout>
 
537
</sect1>
 
538
 
 
539
<sect1 id="errors_2">
 
540
<title>Errors</title>
 
541
 
 
542
<literallayout class="monospaced">
 
543
<emphasis role='bold'>Request</emphasis>
 
544
     1     0                               Error
 
545
     1     1                               code
 
546
     2     CARD16                          sequence number
 
547
     4                                     unused
 
548
     2     CARD16                          minor opcode
 
549
     1     CARD8                           major opcode
 
550
     21                                    unused
 
551
 
 
552
<emphasis role='bold'>Value</emphasis>
 
553
     1     0                               Error
 
554
     1     2                               code
 
555
     2     CARD16                          sequence number
 
556
     4     &lt;32-bits&gt;                 bad value
 
557
     2     CARD16                          minor opcode
 
558
     1     CARD8                           major opcode
 
559
     21                                    unused
 
560
 
 
561
<emphasis role='bold'>Window</emphasis>
 
562
     1     0                               Error
 
563
     1     3                               code
 
564
     2     CARD16                          sequence number
 
565
     4     CARD32                          bad resource id
 
566
     2     CARD16                          minor opcode
 
567
     1     CARD8                           major opcode
 
568
     21                                    unused
 
569
 
 
570
<emphasis role='bold'>Pixmap</emphasis>
 
571
     1     0                               Error
 
572
     1     4                               code
 
573
     2     CARD16                          sequence number
 
574
     4     CARD32                          bad resource id
 
575
     2     CARD16                          minor opcode
 
576
     1     CARD8                           major opcode
 
577
     21                                    unused
 
578
 
 
579
<emphasis role='bold'>Atom</emphasis>
 
580
     1     0                               Error
 
581
     1     5                               code
 
582
     2     CARD16                          sequence number
 
583
     4     CARD32                          bad atom id
 
584
     2     CARD16                          minor opcode
 
585
     1     CARD8                           major opcode
 
586
     21                                    unused
 
587
 
 
588
<emphasis role='bold'>Cursor</emphasis>
 
589
     1     0                               Error
 
590
     1     6                               code
 
591
     2     CARD16                          sequence number
 
592
     4     CARD32                          bad resource id
 
593
     2     CARD16                          minor opcode
 
594
     1     CARD8                           major opcode
 
595
     21                                    unused
 
596
 
 
597
<emphasis role='bold'>Font</emphasis>
 
598
     1     0                               Error
 
599
     1     7                               code
 
600
     2     CARD16                          sequence number
 
601
     4     CARD32                          bad resource id
 
602
     2     CARD16                          minor opcode
 
603
     1     CARD8                           major opcode
 
604
     21                                    unused
 
605
 
 
606
<emphasis role='bold'>Match</emphasis>
 
607
     1     0                               Error
 
608
     1     8                               code
 
609
     2     CARD16                          sequence number
 
610
     4                                     unused
 
611
     2     CARD16                          minor opcode
 
612
     1     CARD8                           major opcode
 
613
     21                                    unused
 
614
 
 
615
<emphasis role='bold'>Drawable</emphasis>
 
616
     1     0                               Error
 
617
     1     9                               code
 
618
     2     CARD16                          sequence number
 
619
     4     CARD32                          bad resource id
 
620
     2     CARD16                          minor opcode
 
621
     1     CARD8                           major opcode
 
622
     21                                    unused
 
623
 
 
624
<emphasis role='bold'>Access</emphasis>
 
625
     1     0                               Error
 
626
     1     10                              code
 
627
     2     CARD16                          sequence number
 
628
     4                                     unused
 
629
     2     CARD16                          minor opcode
 
630
     1     CARD8                           major opcode
 
631
     21                                    unused
 
632
 
 
633
<emphasis role='bold'>Alloc</emphasis>
 
634
     1     0                               Error
 
635
     1     11                              code
 
636
     2     CARD16                          sequence number
 
637
     4                                     unused
 
638
     2     CARD16                          minor opcode
 
639
     1     CARD8                           major opcode
 
640
     21                                    unused
 
641
 
 
642
<emphasis role='bold'>Colormap</emphasis>
 
643
     1     0                               Error
 
644
     1     12                              code
 
645
     2     CARD16                          sequence number
 
646
     4     CARD32                          bad resource id
 
647
     2     CARD16                          minor opcode
 
648
     1     CARD8                           major opcode
 
649
     21                                    unused
 
650
 
 
651
<emphasis role='bold'>GContext</emphasis>
 
652
     1     0                               Error
 
653
     1     13                              code
 
654
     2     CARD16                          sequence number
 
655
     4     CARD32                          bad resource id
 
656
     2     CARD16                          minor opcode
 
657
     1     CARD8                           major opcode
 
658
     21                                    unused
 
659
 
 
660
<emphasis role='bold'>IDChoice</emphasis>
 
661
     1     0                               Error
 
662
     1     14                              code
 
663
     2     CARD16                          sequence number
 
664
     4     CARD32                          bad resource id
 
665
     2     CARD16                          minor opcode
 
666
     1     CARD8                           major opcode
 
667
     21                                    unused
 
668
 
 
669
<emphasis role='bold'>Name</emphasis>
 
670
     1     0                               Error
 
671
     1     15                              code
 
672
     2     CARD16                          sequence number
 
673
     4                                     unused
 
674
     2     CARD16                          minor opcode
 
675
     1     CARD8                           major opcode
 
676
     21                                    unused
 
677
 
 
678
<emphasis role='bold'>Length</emphasis>
 
679
     1     0                               Error
 
680
     1     16                              code
 
681
     2     CARD16                          sequence number
 
682
     4                                     unused
 
683
     2     CARD16                          minor opcode
 
684
     1     CARD8                           major opcode
 
685
     21                                    unused
 
686
 
 
687
<emphasis role='bold'>Implementation</emphasis>
 
688
     1     0                               Error
 
689
     1     17                              code
 
690
     2     CARD16                          sequence number
 
691
     4                                     unused
 
692
     2     CARD16                          minor opcode
 
693
     1     CARD8                           major opcode
 
694
     21                                    unused
 
695
</literallayout>
 
696
</sect1>
 
697
 
 
698
<sect1 id="keyboards_2">
 
699
<title>Keyboards</title>
 
700
 
 
701
<para>
 
702
KEYCODE values are always greater than 7 (and less than 256).
 
703
</para>
 
704
 
 
705
<para>
 
706
KEYSYM values with the bit #x10000000 set are reserved as vendor-specific.
 
707
</para>
 
708
 
 
709
<para>
 
710
The names and encodings of the standard KEYSYM values are contained in
 
711
Appendix A, Keysym Encoding. <!-- xref -->
 
712
</para>
 
713
</sect1>
 
714
 
 
715
<sect1 id="pointers_2">
 
716
<title>Pointers</title>
 
717
 
 
718
<para>
 
719
BUTTON values are numbered starting with one.
 
720
</para>
 
721
 
 
722
</sect1>
 
723
<sect1 id="predefined">
 
724
<title>Predefined Atoms</title>
 
725
 
 
726
<literallayout class="monospaced">
 
727
PRIMARY           1      WM_NORMAL_HINTS     40
 
728
SECONDARY         2      WM_SIZE_HINTS       41
 
729
ARC               3      WM_ZOOM_HINTS       42
 
730
ATOM              4      MIN_SPACE           43
 
731
BITMAP            5      NORM_SPACE          44
 
732
CARDINAL          6      MAX_SPACE           45
 
733
COLORMAP          7      END_SPACE           46
 
734
CURSOR            8      SUPERSCRIPT_X       47
 
735
CUT_BUFFER0       9      SUPERSCRIPT_Y       48
 
736
CUT_BUFFER1       10     SUBSCRIPT_X         49
 
737
CUT_BUFFER2       11     SUBSCRIPT_Y         50
 
738
CUT_BUFFER3       12     UNDERLINE_POSITION  51
 
739
CUT_BUFFER4       13     UNDERLINE_THICKNESS 52
 
740
CUT_BUFFER5       14     STRIKEOUT_ASCENT    53
 
741
CUT_BUFFER6       15     STRIKEOUT_DESCENT   54
 
742
CUT_BUFFER7       16     ITALIC_ANGLE        55
 
743
DRAWABLE          17     X_HEIGHT            56
 
744
FONT              18     QUAD_WIDTH          57
 
745
INTEGER           19     WEIGHT              58
 
746
PIXMAP            20     POINT_SIZE          59
 
747
POINT             21     RESOLUTION          60
 
748
RECTANGLE         22     COPYRIGHT           61
 
749
RESOURCE_MANAGER  23     NOTICE              62
 
750
RGB_COLOR_MAP     24     FONT_NAME           63
 
751
RGB_BEST_MAP      25     FAMILY_NAME         64
 
752
RGB_BLUE_MAP      26     FULL_NAME           65
 
753
RGB_DEFAULT_MAP   27     CAP_HEIGHT          66
 
754
RGB_GRAY_MAP      28     WM_CLASS            67
 
755
RGB_GREEN_MAP     29     WM_TRANSIENT_FOR    68
 
756
RGB_RED_MAP       30
 
757
STRING            31
 
758
VISUALID          32
 
759
WINDOW            33
 
760
WM_COMMAND        34
 
761
WM_HINTS          35
 
762
WM_CLIENT_MACHINE 36
 
763
WM_ICON_NAME      37
 
764
WM_ICON_SIZE      38
 
765
WM_NAME           39
 
766
</literallayout>
 
767
</sect1>
 
768
 
 
769
<sect1 id="connection_setup_2">
 
770
<title>Connection Setup</title>
 
771
 
 
772
<para>
 
773
For TCP connections,
 
774
displays on a given host are numbered starting from 0,
 
775
and the server for display N listens and accepts connections on port 6000 + N.
 
776
For DECnet connections,
 
777
displays on a given host are numbered starting from 0,
 
778
and the server for display N listens and accepts connections on the object
 
779
name obtained by concatenating "X$X" with the decimal representation of N,
 
780
for example, X$X0 and X$X1.
 
781
</para>
 
782
 
 
783
<para>
 
784
Information sent by the client at connection setup:
 
785
</para>
 
786
 
 
787
<literallayout class="monospaced">
 
788
     1                       byte-order
 
789
          #x42     MSB first
 
790
          #x6C     LSB first
 
791
     1                       unused
 
792
     2     CARD16            protocol-major-version
 
793
     2     CARD16            protocol-minor-version
 
794
     2     n                 length of authorization-protocol-name
 
795
     2     d                 length of authorization-protocol-data
 
796
     2                       unused
 
797
     n     STRING8           authorization-protocol-name
 
798
     p                       unused, p=pad(n)
 
799
     d     STRING8           authorization-protocol-data
 
800
     q                       unused, q=pad(d)
 
801
</literallayout>
 
802
 
 
803
<para>
 
804
Except where explicitly noted in the protocol,
 
805
all 16-bit and 32-bit quantities sent by the client must be transmitted
 
806
with the specified byte order,
 
807
and all 16-bit and 32-bit quantities returned by the server will be transmitted
 
808
with this byte order.
 
809
</para>
 
810
 
 
811
<para>
 
812
Information received by the client if the connection is refused:
 
813
</para>
 
814
 
 
815
<literallayout class="monospaced">
 
816
     1     0                 Failed
 
817
     1     n                 length of reason in bytes
 
818
     2     CARD16            protocol-major-version
 
819
     2     CARD16            protocol-minor-version
 
820
     2     (n+p)/4           length in 4-byte units of "additional data"
 
821
     n     STRING8           reason
 
822
     p                       unused, p=pad(n)
 
823
</literallayout>
 
824
 
 
825
<para>
 
826
Information received by the client if further authentication is required:
 
827
</para>
 
828
 
 
829
<literallayout class="monospaced">
 
830
     1     2                 Authenticate
 
831
     5                       unused
 
832
     2     (n+p)/4           length in 4-byte units of "additional data"
 
833
     n     STRING8           reason
 
834
     p                       unused, p=pad(n)
 
835
</literallayout>
 
836
 
 
837
<para>
 
838
Information received by the client if the connection is accepted:
 
839
</para>
 
840
 
 
841
<literallayout class="monospaced">
 
842
     1     1                               Success
 
843
     1                                     unused
 
844
     2     CARD16                          protocol-major-version
 
845
     2     CARD16                          protocol-minor-version
 
846
     2     8+2n+(v+p+m)/4                  length in 4-byte units of
 
847
                                           "additional data"
 
848
     4     CARD32                          release-number
 
849
     4     CARD32                          resource-id-base
 
850
     4     CARD32                          resource-id-mask
 
851
     4     CARD32                          motion-buffer-size
 
852
     2     v                               length of vendor
 
853
     2     CARD16                          maximum-request-length
 
854
     1     CARD8                           number of SCREENs in roots
 
855
     1     n                               number for FORMATs in
 
856
                                           pixmap-formats
 
857
     1                                     image-byte-order
 
858
          0     LSBFirst
 
859
          1     MSBFirst
 
860
     1                                     bitmap-format-bit-order
 
861
          0     LeastSignificant
 
862
          1     MostSignificant
 
863
     1     CARD8                           bitmap-format-scanline-unit
 
864
     1     CARD8                           bitmap-format-scanline-pad
 
865
     1     KEYCODE                         min-keycode
 
866
     1     KEYCODE                         max-keycode
 
867
     4                                     unused
 
868
     v     STRING8                         vendor
 
869
     p                                     unused, p=pad(v)
 
870
     8n     LISTofFORMAT                   pixmap-formats
 
871
     m     LISTofSCREEN                    roots (m is always a multiple of 4)
 
872
</literallayout>
 
873
 
 
874
<literallayout class="monospaced">
 
875
FORMAT
 
876
     1     CARD8                           depth
 
877
     1     CARD8                           bits-per-pixel
 
878
     1     CARD8                           scanline-pad
 
879
     5                                     unused
 
880
</literallayout>
 
881
 
 
882
<literallayout class="monospaced">
 
883
SCREEN
 
884
     4     WINDOW                          root
 
885
     4     COLORMAP                        default-colormap
 
886
     4     CARD32                          white-pixel
 
887
     4     CARD32                          black-pixel
 
888
     4     SETofEVENT                      current-input-masks
 
889
     2     CARD16                          width-in-pixels
 
890
     2     CARD16                          height-in-pixels
 
891
     2     CARD16                          width-in-millimeters
 
892
     2     CARD16                          height-in-millimeters
 
893
     2     CARD16                          min-installed-maps
 
894
     2     CARD16                          max-installed-maps
 
895
     4     VISUALID                        root-visual
 
896
     1                                     backing-stores
 
897
          0     Never
 
898
          1     WhenMapped
 
899
          2     Always
 
900
     1     BOOL                            save-unders
 
901
     1     CARD8                           root-depth
 
902
     1     CARD8                           number of DEPTHs in allowed-depths
 
903
     n     LISTofDEPTH                     allowed-depths (n is always a
 
904
                                           multiple of 4)
 
905
</literallayout>
 
906
 
 
907
<literallayout class="monospaced">
 
908
DEPTH
 
909
     1     CARD8                           depth
 
910
     1                                     unused
 
911
     2     n                               number of VISUALTYPES in visuals
 
912
     4                                     unused
 
913
     24n     LISTofVISUALTYPE              visuals
 
914
</literallayout>
 
915
 
 
916
<literallayout class="monospaced">
 
917
VISUALTYPE
 
918
     4     VISUALID                        visual-id
 
919
     1                                     class
 
920
          0     StaticGray
 
921
          1     GrayScale
 
922
          2     StaticColor
 
923
          3     PseudoColor
 
924
          4     TrueColor
 
925
          5     DirectColor
 
926
     1     CARD8                           bits-per-rgb-value
 
927
     2     CARD16                          colormap-entries
 
928
     4     CARD32                          red-mask
 
929
     4     CARD32                          green-mask
 
930
     4     CARD32                          blue-mask
 
931
     4                                     unused
 
932
</literallayout>
 
933
</sect1>
 
934
 
 
935
<sect1 id="requests_2">
 
936
<title>Requests</title>
 
937
 
 
938
<literallayout class="monospaced">
 
939
<emphasis role='bold'>CreateWindow</emphasis>
 
940
     1     1                               opcode
 
941
     1     CARD8                           depth
 
942
     2     8+n                             request length
 
943
     4     WINDOW                          wid
 
944
     4     WINDOW                          parent
 
945
     2     INT16                           x
 
946
     2     INT16                           y
 
947
     2     CARD16                          width
 
948
     2     CARD16                          height
 
949
     2     CARD16                          border-width
 
950
     2                                     class
 
951
          0     CopyFromParent
 
952
          1     InputOutput
 
953
          2     InputOnly
 
954
     4     VISUALID                        visual
 
955
          0     CopyFromParent
 
956
     4     BITMASK                         value-mask (has n bits set to 1)
 
957
          #x00000001     background-pixmap
 
958
          #x00000002     background-pixel
 
959
          #x00000004     border-pixmap
 
960
          #x00000008     border-pixel
 
961
          #x00000010     bit-gravity
 
962
          #x00000020     win-gravity
 
963
          #x00000040     backing-store
 
964
          #x00000080     backing-planes
 
965
          #x00000100     backing-pixel
 
966
          #x00000200     override-redirect
 
967
          #x00000400     save-under
 
968
          #x00000800     event-mask
 
969
          #x00001000     do-not-propagate-mask
 
970
          #x00002000     colormap
 
971
          #x00004000     cursor
 
972
     4n     LISTofVALUE                    value-list
 
973
 
 
974
  VALUEs
 
975
     4     PIXMAP                          background-pixmap
 
976
          0     None
 
977
          1     ParentRelative
 
978
     4     CARD32                          background-pixel
 
979
     4     PIXMAP                          border-pixmap
 
980
          0     CopyFromParent
 
981
     4     CARD32                          border-pixel
 
982
     1     BITGRAVITY                      bit-gravity
 
983
     1     WINGRAVITY                      win-gravity
 
984
     1                                     backing-store
 
985
          0     NotUseful
 
986
          1     WhenMapped
 
987
          2     Always
 
988
     4     CARD32                          backing-planes
 
989
     4     CARD32                          backing-pixel
 
990
     1     BOOL                            override-redirect
 
991
     1     BOOL                            save-under
 
992
     4     SETofEVENT                      event-mask
 
993
     4     SETofDEVICEEVENT                do-not-propagate-mask
 
994
     4     COLORMAP                        colormap
 
995
          0     CopyFromParent
 
996
     4     CURSOR                          cursor
 
997
          0     None
 
998
 
 
999
<emphasis role='bold'>ChangeWindowAttributes</emphasis>
 
1000
     1     2                               opcode
 
1001
     1                                     unused
 
1002
     2     3+n                             request length
 
1003
     4     WINDOW                          window
 
1004
     4     BITMASK                         value-mask (has n bits set to 1)
 
1005
          encodings are the same as for CreateWindow
 
1006
     4n     LISTofVALUE                    value-list
 
1007
          encodings are the same as for CreateWindow
 
1008
 
 
1009
<emphasis role='bold'>GetWindowAttributes</emphasis>
 
1010
     1     3                               opcode
 
1011
     1                                     unused
 
1012
     2     2                               request length
 
1013
     4     WINDOW                          window
 
1014
 
 
1015
-&gt;
 
1016
     1     1                               Reply
 
1017
     1                                     backing-store
 
1018
          0     NotUseful
 
1019
          1     WhenMapped
 
1020
          2     Always
 
1021
     2     CARD16                          sequence number
 
1022
     4     3                               reply length
 
1023
     4     VISUALID                        visual
 
1024
     2                                     class
 
1025
          1     InputOutput
 
1026
          2     InputOnly
 
1027
     1     BITGRAVITY                      bit-gravity
 
1028
     1     WINGRAVITY                      win-gravity
 
1029
     4     CARD32                          backing-planes
 
1030
     4     CARD32                          backing-pixel
 
1031
     1     BOOL                            save-under
 
1032
     1     BOOL                            map-is-installed
 
1033
     1                                     map-state
 
1034
          0     Unmapped
 
1035
          1     Unviewable
 
1036
          2     Viewable
 
1037
     1     BOOL                            override-redirect
 
1038
     4     COLORMAP                        colormap
 
1039
          0     None
 
1040
     4     SETofEVENT                      all-event-masks
 
1041
     4     SETofEVENT                      your-event-mask
 
1042
     2     SETofDEVICEEVENT                do-not-propagate-mask
 
1043
     2                                     unused
 
1044
 
 
1045
<emphasis role='bold'>DestroyWindow</emphasis>
 
1046
     1     4                               opcode
 
1047
     1                                     unused
 
1048
     2     2                               request length
 
1049
     4     WINDOW                          window
 
1050
 
 
1051
<emphasis role='bold'>DestroySubwindows</emphasis>
 
1052
     1     5                               opcode
 
1053
     1                                     unused
 
1054
     2     2                               request length
 
1055
     4     WINDOW                          window
 
1056
 
 
1057
<emphasis role='bold'>ChangeSaveSet</emphasis>
 
1058
     1     6                               opcode
 
1059
     1                                     mode
 
1060
          0     Insert
 
1061
          1     Delete
 
1062
     2     2                               request length
 
1063
     4     WINDOW                          window
 
1064
 
 
1065
<emphasis role='bold'>ReparentWindow</emphasis>
 
1066
     1     7                               opcode
 
1067
     1                                     unused
 
1068
     2     4                               request length
 
1069
     4     WINDOW                          window
 
1070
     4     WINDOW                          parent
 
1071
     2     INT16                           x
 
1072
     2     INT16                           y
 
1073
 
 
1074
<emphasis role='bold'>MapWindow</emphasis>
 
1075
     1     8                               opcode
 
1076
     1                                     unused
 
1077
     2     2                               request length
 
1078
     4     WINDOW                          window
 
1079
 
 
1080
<emphasis role='bold'>MapSubwindows</emphasis>
 
1081
     1     9                               opcode
 
1082
     1                                     unused
 
1083
     2     2                               request length
 
1084
     4     WINDOW                          window
 
1085
 
 
1086
<emphasis role='bold'>UnmapWindow</emphasis>
 
1087
     1     10                              opcode
 
1088
     1                                     unused
 
1089
     2     2                               request length
 
1090
     4     WINDOW                          window
 
1091
 
 
1092
<emphasis role='bold'>UnmapSubwindows</emphasis>
 
1093
     1     11                              opcode
 
1094
     1                                     unused
 
1095
     2     2                               request length
 
1096
     4     WINDOW                          window
 
1097
 
 
1098
<emphasis role='bold'>ConfigureWindow</emphasis>
 
1099
     1     12                              opcode
 
1100
     1                                     unused
 
1101
     2     3+n                             request length
 
1102
     4     WINDOW                          window
 
1103
     2     BITMASK                         value-mask (has n bits set to 1)
 
1104
          #x0001     x
 
1105
          #x0002     y
 
1106
          #x0004     width
 
1107
          #x0008     height
 
1108
          #x0010     border-width
 
1109
          #x0020     sibling
 
1110
          #x0040     stack-mode
 
1111
     2               unused
 
1112
     4n     LISTofVALUE                    value-list
 
1113
 
 
1114
  VALUEs
 
1115
     2     INT16                           x
 
1116
     2     INT16                           y
 
1117
     2     CARD16                          width
 
1118
     2     CARD16                          height
 
1119
     2     CARD16                          border-width
 
1120
     4     WINDOW                          sibling
 
1121
     1                                     stack-mode
 
1122
          0     Above
 
1123
          1     Below
 
1124
          2     TopIf
 
1125
          3     BottomIf
 
1126
          4     Opposite
 
1127
 
 
1128
<emphasis role='bold'>CirculateWindow</emphasis>
 
1129
     1     13                              opcode
 
1130
     1                                     direction
 
1131
          0     RaiseLowest
 
1132
          1     LowerHighest
 
1133
     2     2                               request length
 
1134
     4     WINDOW                          window
 
1135
 
 
1136
<emphasis role='bold'>GetGeometry</emphasis>
 
1137
     1     14                              opcode
 
1138
     1                                     unused
 
1139
     2     2                               request length
 
1140
     4     DRAWABLE                        drawable
 
1141
 
 
1142
-&gt;
 
1143
     1     1                               Reply
 
1144
     1     CARD8                           depth
 
1145
     2     CARD16                          sequence number
 
1146
     4     0                               reply length
 
1147
     4     WINDOW                          root
 
1148
     2     INT16                           x
 
1149
     2     INT16                           y
 
1150
     2     CARD16                          width
 
1151
     2     CARD16                          height
 
1152
     2     CARD16                          border-width
 
1153
     10                                    unused
 
1154
 
 
1155
<emphasis role='bold'>QueryTree</emphasis>
 
1156
     1     15                              opcode
 
1157
     1                                     unused
 
1158
     2     2                               request length
 
1159
     4     WINDOW                          window
 
1160
 
 
1161
-&gt;
 
1162
     1     1                               Reply
 
1163
     1                                     unused
 
1164
     2     CARD16                          sequence number
 
1165
     4     n                               reply length
 
1166
     4     WINDOW                          root
 
1167
     4     WINDOW                          parent
 
1168
          0     None
 
1169
     2     n                               number of WINDOWs in children
 
1170
     14                                    unused
 
1171
     4n     LISTofWINDOW                   children
 
1172
 
 
1173
<emphasis role='bold'>InternAtom</emphasis>
 
1174
     1     16                              opcode
 
1175
     1     BOOL                            only-if-exists
 
1176
     2     2+(n+p)/4                       request length
 
1177
     2     n                               length of name
 
1178
     2                                     unused
 
1179
     n     STRING8                         name
 
1180
     p                                     unused, p=pad(n)
 
1181
 
 
1182
-&gt;
 
1183
     1     1                               Reply
 
1184
     1                                     unused
 
1185
     2     CARD16                          sequence number
 
1186
     4     0                               reply length
 
1187
     4     ATOM                            atom
 
1188
           0     None
 
1189
     20                                    unused
 
1190
 
 
1191
<emphasis role='bold'>GetAtomName</emphasis>
 
1192
     1     17                              opcode
 
1193
     1                                     unused
 
1194
     2     2                               request length
 
1195
     4     ATOM                            atom
 
1196
 
 
1197
-&gt;
 
1198
     1     1                               Reply
 
1199
     1                                     unused
 
1200
     2     CARD16                          sequence number
 
1201
     4     (n+p)/4                         reply length
 
1202
     2     n                               length of name
 
1203
     22                                    unused
 
1204
     n     STRING8                         name
 
1205
     p                                     unused, p=pad(n)
 
1206
 
 
1207
<emphasis role='bold'>ChangeProperty</emphasis>
 
1208
     1     18                              opcode
 
1209
     1                                     mode
 
1210
          0     Replace
 
1211
          1     Prepend
 
1212
          2     Append
 
1213
     2     6+(n+p)/4                       request length
 
1214
     4     WINDOW                          window
 
1215
     4     ATOM                            property
 
1216
     4     ATOM                            type
 
1217
     1     CARD8                           format
 
1218
     3                                     unused
 
1219
     4     CARD32                          length of data in format units
 
1220
                    (= n for format = 8)
 
1221
                    (= n/2 for format = 16)
 
1222
                    (= n/4 for format = 32)
 
1223
     n     LISTofBYTE                      data
 
1224
                    (n is a multiple of 2 for format = 16)
 
1225
                    (n is a multiple of 4 for format = 32)
 
1226
     p                                     unused, p=pad(n)
 
1227
 
 
1228
 
 
1229
<emphasis role='bold'>DeleteProperty</emphasis>
 
1230
     1     19                              opcode
 
1231
     1                                     unused
 
1232
     2     3                               request length
 
1233
     4     WINDOW                          window
 
1234
     4     ATOM                            property
 
1235
 
 
1236
<emphasis role='bold'>GetProperty</emphasis>
 
1237
     1     20                              opcode
 
1238
     1     BOOL                            delete
 
1239
     2     6                               request length
 
1240
     4     WINDOW                          window
 
1241
     4     ATOM                            property
 
1242
     4     ATOM                            type
 
1243
          0     AnyPropertyType
 
1244
     4     CARD32                          long-offset
 
1245
     4     CARD32                          long-length
 
1246
 
 
1247
-&gt;
 
1248
     1     1                               Reply
 
1249
     1     CARD8                           format
 
1250
     2     CARD16                          sequence number
 
1251
     4     (n+p)/4                         reply length
 
1252
     4     ATOM                            type
 
1253
          0     None
 
1254
     4     CARD32                          bytes-after
 
1255
     4     CARD32                          length of value in format units
 
1256
                    (= 0 for format = 0)
 
1257
                    (= n for format = 8)
 
1258
                    (= n/2 for format = 16)
 
1259
                    (= n/4 for format = 32)
 
1260
     12                                    unused
 
1261
     n     LISTofBYTE                      value
 
1262
                    (n is zero for format = 0)
 
1263
                    (n is a multiple of 2 for format = 16)
 
1264
                    (n is a multiple of 4 for format = 32)
 
1265
     p                                     unused, p=pad(n)
 
1266
 
 
1267
<emphasis role='bold'>ListProperties</emphasis>
 
1268
     1     21                              opcode
 
1269
     1                                     unused
 
1270
     2     2                               request length
 
1271
     4     WINDOW                          window
 
1272
 
 
1273
-&gt;
 
1274
     1     1                               Reply
 
1275
     1                                     unused
 
1276
     2     CARD16                          sequence number
 
1277
     4     n                               reply length
 
1278
     2     n                               number of ATOMs in atoms
 
1279
     22                                    unused
 
1280
     4n     LISTofATOM                     atoms
 
1281
 
 
1282
<emphasis role='bold'>SetSelectionOwner</emphasis>
 
1283
     1     22                              opcode
 
1284
     1                                     unused
 
1285
     2     4                               request length
 
1286
     4     WINDOW                          owner
 
1287
          0     None
 
1288
     4     ATOM                            selection
 
1289
     4     TIMESTAMP                       time
 
1290
          0     CurrentTime
 
1291
 
 
1292
<emphasis role='bold'>GetSelectionOwner</emphasis>
 
1293
     1     23                              opcode
 
1294
     1                                     unused
 
1295
     2     2                               request length
 
1296
     4     ATOM                            selection
 
1297
 
 
1298
-&gt;
 
1299
     1     1                               Reply
 
1300
     1                                     unused
 
1301
     2     CARD16                          sequence number
 
1302
     4     0                               reply length
 
1303
     4     WINDOW                          owner
 
1304
          0     None
 
1305
     20                                    unused
 
1306
 
 
1307
<emphasis role='bold'>ConvertSelection</emphasis>
 
1308
     1     24                              opcode
 
1309
     1                                     unused
 
1310
     2     6                               request length
 
1311
     4     WINDOW                          requestor
 
1312
     4     ATOM                            selection
 
1313
     4     ATOM                            target
 
1314
     4     ATOM                            property
 
1315
          0     None
 
1316
     4     TIMESTAMP                       time
 
1317
          0     CurrentTime
 
1318
 
 
1319
<emphasis role='bold'>SendEvent</emphasis>
 
1320
     1     25                              opcode
 
1321
     1     BOOL                            propagate
 
1322
     2     11                              requestlength
 
1323
     4     WINDOW                          destination
 
1324
          0     PointerWindow
 
1325
          1     InputFocus
 
1326
     4     SETofEVENT                      event-mask
 
1327
     32                                    event
 
1328
          standard event format (see the Events section)
 
1329
 
 
1330
<emphasis role='bold'>GrabPointer</emphasis>
 
1331
     1     26                              opcode
 
1332
     1     BOOL                            owner-events
 
1333
     2     6                               request length
 
1334
     4     WINDOW                          grab-window
 
1335
     2     SETofPOINTEREVENT               event-mask
 
1336
     1                                     pointer-mode
 
1337
          0     Synchronous
 
1338
          1     Asynchronous
 
1339
     1                                     keyboard-mode
 
1340
          0     Synchronous
 
1341
          1     Asynchronous
 
1342
     4     WINDOW                          confine-to
 
1343
          0     None
 
1344
     4     CURSOR                          cursor
 
1345
          0     None
 
1346
     4     TIMESTAMP                       time
 
1347
          0     CurrentTime
 
1348
 
 
1349
-&gt;
 
1350
     1     1                               Reply
 
1351
     1                                     status
 
1352
          0     Success
 
1353
          1     AlreadyGrabbed
 
1354
          2     InvalidTime
 
1355
          3     NotViewable
 
1356
          4     Frozen
 
1357
     2     CARD16                          sequence number
 
1358
     4     0                               reply length
 
1359
     24                                    unused
 
1360
 
 
1361
<emphasis role='bold'>UngrabPointer</emphasis>
 
1362
     1     27                              opcode
 
1363
     1                                     unused
 
1364
     2     2                               request length
 
1365
     4     TIMESTAMP                       time
 
1366
          0     CurrentTime
 
1367
 
 
1368
<emphasis role='bold'>GrabButton</emphasis>
 
1369
     1     28                              opcode
 
1370
     1     BOOL                            owner-events
 
1371
     2     6                               request length
 
1372
     4     WINDOW                          grab-window
 
1373
     2     SETofPOINTEREVENT               event-mask
 
1374
     1                                     pointer-mode
 
1375
          0     Synchronous
 
1376
          1     Asynchronous
 
1377
     1                                     keyboard-mode
 
1378
          0     Synchronous
 
1379
          1     Asynchronous
 
1380
     4     WINDOW                          confine-to
 
1381
          0     None
 
1382
     4     CURSOR                          cursor
 
1383
          0     None
 
1384
     1     BUTTON                          button
 
1385
          0     AnyButton
 
1386
     1                                     unused
 
1387
     2     SETofKEYMASK                    modifiers
 
1388
          #x8000                           AnyModifier
 
1389
 
 
1390
<emphasis role='bold'>UngrabButton</emphasis>
 
1391
     1     29                              opcode
 
1392
     1     BUTTON                          button
 
1393
          0     AnyButton
 
1394
     2     3                               request length
 
1395
     4     WINDOW                          grab-window
 
1396
     2     SETofKEYMASK                    modifiers
 
1397
          #x8000                           AnyModifier
 
1398
     2                                     unused
 
1399
 
 
1400
<emphasis role='bold'>ChangeActivePointerGrab</emphasis>
 
1401
     1     30                              opcode
 
1402
     1                                     unused
 
1403
     2     4                               request length
 
1404
     4     CURSOR                          cursor
 
1405
          0     None
 
1406
     4     TIMESTAMP                       time
 
1407
          0     CurrentTime
 
1408
     2     SETofPOINTEREVENT               event-mask
 
1409
     2                                     unused
 
1410
 
 
1411
<emphasis role='bold'>GrabKeyboard</emphasis>
 
1412
     1     31                              opcode
 
1413
     1     BOOL                            owner-events
 
1414
     2     4                               request length
 
1415
     4     WINDOW                          grab-window
 
1416
     4     TIMESTAMP                       time
 
1417
          0     CurrentTime
 
1418
     1                                     pointer-mode
 
1419
          0     Synchronous
 
1420
          1     Asynchronous
 
1421
     1                                     keyboard-mode
 
1422
          0     Synchronous
 
1423
          1     Asynchronous
 
1424
     2                                     unused
 
1425
 
 
1426
-&gt;
 
1427
     1     1                               Reply
 
1428
     1                                     status
 
1429
          0     Success
 
1430
          1     AlreadyGrabbed
 
1431
          2     InvalidTime
 
1432
          3     NotViewable
 
1433
          4     Frozen
 
1434
     2     CARD16                          sequence number
 
1435
     4     0                               reply length
 
1436
     24                                    unused
 
1437
 
 
1438
<emphasis role='bold'>UngrabKeyboard</emphasis>
 
1439
     1     32                              opcode
 
1440
     1                                     unused
 
1441
     2     2                               request length
 
1442
     4     TIMESTAMP                       time
 
1443
          0     CurrentTime
 
1444
 
 
1445
<emphasis role='bold'>GrabKey</emphasis>
 
1446
     1     33                              opcode
 
1447
     1     BOOL                            owner-events
 
1448
     2     4                               request length
 
1449
     4     WINDOW                          grab-window
 
1450
     2     SETofKEYMASK                    modifiers
 
1451
          #x8000     AnyModifier
 
1452
     1     KEYCODE                         key
 
1453
          0     AnyKey
 
1454
     1                                     pointer-mode
 
1455
          0     Synchronous
 
1456
          1     Asynchronous
 
1457
     1                                     keyboard-mode
 
1458
          0     Synchronous
 
1459
          1     Asynchronous
 
1460
     3                                     unused
 
1461
 
 
1462
<emphasis role='bold'>UngrabKey</emphasis>
 
1463
     1     34                              opcode
 
1464
     1     KEYCODE                         key
 
1465
          0     AnyKey
 
1466
     2     3                               request length
 
1467
     4     WINDOW                          grab-window
 
1468
     2     SETofKEYMASK                    modifiers
 
1469
          #x8000     AnyModifier
 
1470
     2                                     unused
 
1471
 
 
1472
<emphasis role='bold'>AllowEvents</emphasis>
 
1473
     1     35                              opcode
 
1474
     1                                     mode
 
1475
          0     AsyncPointer
 
1476
          1     SyncPointer
 
1477
          2     ReplayPointer
 
1478
          3     AsyncKeyboard
 
1479
          4     SyncKeyboard
 
1480
          5     ReplayKeyboard
 
1481
          6     AsyncBoth
 
1482
          7     SyncBoth
 
1483
     2     2                               request length
 
1484
     4     TIMESTAMP                       time
 
1485
          0     CurrentTime
 
1486
 
 
1487
<emphasis role='bold'>GrabServer</emphasis>
 
1488
     1     36                              opcode
 
1489
     1                                     unused
 
1490
     2     1                               request length
 
1491
 
 
1492
<emphasis role='bold'>UngrabServer</emphasis>
 
1493
     1     37                              opcode
 
1494
     1                                     unused
 
1495
     2     1                               request length
 
1496
 
 
1497
<emphasis role='bold'>QueryPointer</emphasis>
 
1498
     1     38                              opcode
 
1499
     1                                     unused
 
1500
     2     2                               request length
 
1501
     4     WINDOW                          window
 
1502
 
 
1503
-&gt;
 
1504
     1     1                               Reply
 
1505
     1     BOOL                            same-screen
 
1506
     2     CARD16                          sequence number
 
1507
     4     0                               reply length
 
1508
     4     WINDOW                          root
 
1509
     4     WINDOW                          child
 
1510
          0     None
 
1511
     2     INT16                           root-x
 
1512
     2     INT16                           root-y
 
1513
     2     INT16                           win-x
 
1514
     2     INT16                           win-y
 
1515
     2     SETofKEYBUTMASK                 mask
 
1516
     6                                     unused
 
1517
 
 
1518
<emphasis role='bold'>GetMotionEvents</emphasis>
 
1519
     1     39                              opcode
 
1520
     1                                     unused
 
1521
     2     4                               request length
 
1522
     4     WINDOW                          window
 
1523
     4     TIMESTAMP                       start
 
1524
          0     CurrentTime
 
1525
     4     TIMESTAMP                       stop
 
1526
          0     CurrentTime
 
1527
 
 
1528
-&gt;
 
1529
     1     1                               Reply
 
1530
     1                                     unused
 
1531
     2     CARD16                          sequence number
 
1532
     4     2n                              reply length
 
1533
     4     n                               number of TIMECOORDs in events
 
1534
     20                                    unused
 
1535
     8n     LISTofTIMECOORD                events
 
1536
 
 
1537
  TIMECOORD
 
1538
     4     TIMESTAMP                       time
 
1539
     2     INT16                           x
 
1540
     2     INT16                           y
 
1541
 
 
1542
<emphasis role='bold'>TranslateCoordinates</emphasis>
 
1543
     1     40                              opcode
 
1544
     1                                     unused
 
1545
     2     4                               request length
 
1546
     4     WINDOW                          src-window
 
1547
     4     WINDOW                          dst-window
 
1548
     2     INT16                           src-x
 
1549
     2     INT16                           src-y
 
1550
-&gt;
 
1551
     1     1                               Reply
 
1552
     1     BOOL                            same-screen
 
1553
     2     CARD16                          sequence number
 
1554
     4     0                               reply length
 
1555
     4     WINDOW                          child
 
1556
          0     None
 
1557
     2     INT16                           dst-x
 
1558
     2     INT16                           dst-y
 
1559
     16                                    unused
 
1560
 
 
1561
<emphasis role='bold'>WarpPointer</emphasis>
 
1562
     1     41                              opcode
 
1563
     1                                     unused
 
1564
     2     6                               request length
 
1565
     4     WINDOW                          src-window
 
1566
          0     None
 
1567
     4     WINDOW                          dst-window
 
1568
          0     None
 
1569
     2     INT16                           src-x
 
1570
     2     INT16                           src-y
 
1571
     2     CARD16                          src-width
 
1572
     2     CARD16                          src-height
 
1573
     2     INT16                           dst-x
 
1574
     2     INT16                           dst-y
 
1575
 
 
1576
<emphasis role='bold'>SetInputFocus</emphasis>
 
1577
     1     42                              opcode
 
1578
     1                                     revert-to
 
1579
          0     None
 
1580
          1     PointerRoot
 
1581
          2     Parent
 
1582
     2     3                               request length
 
1583
     4     WINDOW                          focus
 
1584
          0     None
 
1585
          1     PointerRoot
 
1586
     4     TIMESTAMP                       time
 
1587
          0     CurrentTime
 
1588
 
 
1589
<emphasis role='bold'>GetInputFocus</emphasis>
 
1590
     1     43                              opcode
 
1591
     1                                     unused
 
1592
     2     1                               request length
 
1593
 
 
1594
-&gt;
 
1595
     1     1                               Reply
 
1596
     1                                     revert-to
 
1597
          0     None
 
1598
          1     PointerRoot
 
1599
          2     Parent
 
1600
     2     CARD16                          sequence number
 
1601
     4     0                               reply length
 
1602
     4     WINDOW                          focus
 
1603
          0     None
 
1604
          1     PointerRoot
 
1605
     20                                    unused
 
1606
 
 
1607
<emphasis role='bold'>QueryKeymap</emphasis>
 
1608
     1     44                              opcode
 
1609
     1                                     unused
 
1610
     2     1                               request length
 
1611
 
 
1612
-&gt;
 
1613
     1     1                               Reply
 
1614
     1                                     unused
 
1615
     2     CARD16                          sequence number
 
1616
     4     2                               reply length
 
1617
     32     LISTofCARD8                    keys
 
1618
 
 
1619
<emphasis role='bold'>OpenFont</emphasis>
 
1620
     1     45                              opcode
 
1621
     1                                     unused
 
1622
     2     3+(n+p)/4                       request length
 
1623
     4     FONT                            fid
 
1624
     2     n                               length of name
 
1625
     2                                     unused
 
1626
     n     STRING8                         name
 
1627
     p                                     unused, p=pad(n)
 
1628
 
 
1629
<emphasis role='bold'>CloseFont</emphasis>
 
1630
     1     46                              opcode
 
1631
     1                                     unused
 
1632
     2     2                               request length
 
1633
     4     FONT                            font
 
1634
 
 
1635
<emphasis role='bold'>QueryFont</emphasis>
 
1636
     1     47                              opcode
 
1637
     1                                     unused
 
1638
     2     2                               request length
 
1639
     4     FONTABLE                        font
 
1640
 
 
1641
-&gt;
 
1642
     1     1                               Reply
 
1643
     1                                     unused
 
1644
     2     CARD16                          sequence number
 
1645
     4     7+2n+3m                         reply length
 
1646
     12     CHARINFO                       min-bounds
 
1647
     4                                     unused
 
1648
     12     CHARINFO                       max-bounds
 
1649
     4                                     unused
 
1650
     2     CARD16                          min-char-or-byte2
 
1651
     2     CARD16                          max-char-or-byte2
 
1652
     2     CARD16                          default-char
 
1653
     2     n                               number of FONTPROPs in properties
 
1654
     1                                     draw-direction
 
1655
          0     LeftToRight
 
1656
          1     RightToLeft
 
1657
     1     CARD8                           min-byte1
 
1658
     1     CARD8                           max-byte1
 
1659
     1     BOOL                            all-chars-exist
 
1660
     2     INT16                           font-ascent
 
1661
     2     INT16                           font-descent
 
1662
     4     m                               number of CHARINFOs in char-infos
 
1663
     8n     LISTofFONTPROP                 properties
 
1664
     12m     LISTofCHARINFO                char-infos
 
1665
 
 
1666
  FONTPROP
 
1667
     4     ATOM                            name
 
1668
     4     &lt;32-bits&gt;                 value
 
1669
 
 
1670
  CHARINFO
 
1671
     2     INT16                           left-side-bearing
 
1672
     2     INT16                           right-side-bearing
 
1673
     2     INT16                           character-width
 
1674
     2     INT16                           ascent
 
1675
     2     INT16                           descent
 
1676
     2     CARD16                          attributes
 
1677
 
 
1678
<emphasis role='bold'>QueryTextExtents</emphasis>
 
1679
     1     48                              opcode
 
1680
     1     BOOL                            odd length, True if p = 2
 
1681
     2     2+(2n+p)/4                      request length
 
1682
     4     FONTABLE                        font
 
1683
     2n     STRING16                       string
 
1684
     p                                     unused, p=pad(2n)
 
1685
 
 
1686
-&gt;
 
1687
     1     1                               Reply
 
1688
     1                                     draw-direction
 
1689
          0     LeftToRight
 
1690
          1     RightToLeft
 
1691
     2     CARD16                          sequence number
 
1692
     4     0                               reply length
 
1693
     2     INT16                           font-ascent
 
1694
     2     INT16                           font-descent
 
1695
     2     INT16                           overall-ascent
 
1696
     2     INT16                           overall-descent
 
1697
     4     INT32                           overall-width
 
1698
     4     INT32                           overall-left
 
1699
     4     INT32                           overall-right
 
1700
     4                                     unused
 
1701
 
 
1702
<emphasis role='bold'>ListFonts</emphasis>
 
1703
     1     49                              opcode
 
1704
     1                                     unused
 
1705
     2     2+(n+p)/4                       request length
 
1706
     2     CARD16                          max-names
 
1707
     2     n                               length of pattern
 
1708
     n     STRING8                         pattern
 
1709
     p                                     unused, p=pad(n)
 
1710
 
 
1711
-&gt;
 
1712
     1     1                               Reply
 
1713
     1                                     unused
 
1714
     2     CARD16                          sequence number
 
1715
     4     (n+p)/4                         reply length
 
1716
     2     CARD16                          number of STRs in names
 
1717
     22                                    unused
 
1718
     n     LISTofSTR                       names
 
1719
     p                                     unused, p=pad(n)
 
1720
 
 
1721
<emphasis role='bold'>ListFontsWithInfo</emphasis>
 
1722
     1     50                              opcode
 
1723
     1                                     unused
 
1724
     2     2+(n+p)/4                       request length
 
1725
     2     CARD16                          max-names
 
1726
     2     n                               length of pattern
 
1727
     n     STRING8                         pattern
 
1728
     p                                     unused, p=pad(n)
 
1729
 
 
1730
-&gt; (except for last in series)
 
1731
     1     1                               Reply
 
1732
     1     n                               length of name in bytes
 
1733
     2     CARD16                          sequence number
 
1734
     4     7+2m+(n+p)/4                    reply length
 
1735
     12     CHARINFO                       min-bounds
 
1736
     4                                     unused
 
1737
     12     CHARINFO                       max-bounds
 
1738
     4                                     unused
 
1739
     2     CARD16                          min-char-or-byte2
 
1740
     2     CARD16                          max-char-or-byte2
 
1741
     2     CARD16                          default-char
 
1742
     2     m                               number of FONTPROPs in properties
 
1743
     1                                     draw-direction
 
1744
          0     LeftToRight
 
1745
          1     RightToLeft
 
1746
     1     CARD8                           min-byte1
 
1747
     1     CARD8                           max-byte1
 
1748
     1     BOOL                            all-chars-exist
 
1749
     2     INT16                           font-ascent
 
1750
     2     INT16                           font-descent
 
1751
     4     CARD32                          replies-hint
 
1752
     8m     LISTofFONTPROP                 properties
 
1753
     n     STRING8                         name
 
1754
     p                                     unused, p=pad(n)
 
1755
 
 
1756
  FONTPROP
 
1757
     encodings are the same as for QueryFont
 
1758
 
 
1759
  CHARINFO
 
1760
     encodings are the same as for QueryFont
 
1761
 
 
1762
-&gt; (last in series)
 
1763
     1     1                               Reply
 
1764
     1     0                               last-reply indicator
 
1765
     2     CARD16                          sequence number
 
1766
     4     7                               reply length
 
1767
     52                                    unused
 
1768
 
 
1769
<emphasis role='bold'>SetFontPath</emphasis>
 
1770
     1     51                              opcode
 
1771
     1                                     unused
 
1772
     2     2+(n+p)/4                       request length
 
1773
     2     CARD16                          number of STRs in path
 
1774
     2                                     unused
 
1775
     n     LISTofSTR                       path
 
1776
     p                                     unused, p=pad(n)
 
1777
 
 
1778
<emphasis role='bold'>GetFontPath</emphasis>
 
1779
     1     52                              opcode
 
1780
     1                                     unused
 
1781
     2     1                               request list
 
1782
 
 
1783
-&gt;
 
1784
     1     1                               Reply
 
1785
     1                                     unused
 
1786
     2     CARD16                          sequence number
 
1787
     4     (n+p)/4                         reply length
 
1788
     2     CARD16                          number of STRs in path
 
1789
     22                                    unused
 
1790
     n     LISTofSTR                       path
 
1791
     p                                     unused, p=pad(n)
 
1792
 
 
1793
<emphasis role='bold'>CreatePixmap</emphasis>
 
1794
     1     53                              opcode
 
1795
     1     CARD8                           depth
 
1796
     2     4                               request length
 
1797
     4     PIXMAP                          pid
 
1798
     4     DRAWABLE                        drawable
 
1799
     2     CARD16                          width
 
1800
     2     CARD16                          height
 
1801
 
 
1802
<emphasis role='bold'>FreePixmap</emphasis>
 
1803
     1     54                              opcode
 
1804
     1                                     unused
 
1805
     2     2                               request length
 
1806
     4     PIXMAP                          pixmap
 
1807
 
 
1808
<emphasis role='bold'>CreateGC</emphasis>
 
1809
     1     55                              opcode
 
1810
     1                                     unused
 
1811
     2     4+n                             request length
 
1812
     4     GCONTEXT                        cid
 
1813
     4     DRAWABLE                        drawable
 
1814
     4     BITMASK                         value-mask (has n bits set to 1)
 
1815
          #x00000001     function
 
1816
          #x00000002     plane-mask
 
1817
          #x00000004     foreground
 
1818
          #x00000008     background
 
1819
          #x00000010     line-width
 
1820
          #x00000020     line-style
 
1821
          #x00000040     cap-style
 
1822
          #x00000080     join-style
 
1823
          #x00000100     fill-style
 
1824
          #x00000200     fill-rule
 
1825
          #x00000400     tile
 
1826
          #x00000800     stipple
 
1827
          #x00001000     tile-stipple-x-origin
 
1828
          #x00002000     tile-stipple-y-origin
 
1829
          #x00004000     font
 
1830
          #x00008000     subwindow-mode
 
1831
          #x00010000     graphics-exposures
 
1832
          #x00020000     clip-x-origin
 
1833
          #x00040000     clip-y-origin
 
1834
          #x00080000     clip-mask
 
1835
          #x00100000     dash-offset
 
1836
          #x00200000     dashes
 
1837
          #x00400000     arc-mode
 
1838
     4n     LISTofVALUE                    value-list
 
1839
 
 
1840
  VALUEs
 
1841
     1                                     function
 
1842
           0     Clear
 
1843
           1     And
 
1844
           2     AndReverse
 
1845
           3     Copy
 
1846
           4     AndInverted
 
1847
           5     NoOp
 
1848
           6     Xor
 
1849
           7     Or
 
1850
           8     Nor
 
1851
           9     Equiv
 
1852
          10     Invert
 
1853
          11     OrReverse
 
1854
          12     CopyInverted
 
1855
          13     OrInverted
 
1856
          14     Nand
 
1857
          15     Set
 
1858
     4     CARD32                          plane-mask
 
1859
     4     CARD32                          foreground
 
1860
     4     CARD32                          background
 
1861
     2     CARD16                          line-width
 
1862
     1                                     line-style
 
1863
          0     Solid
 
1864
          1     OnOffDash
 
1865
          2     DoubleDash
 
1866
     1                                     cap-style
 
1867
          0     NotLast
 
1868
          1     Butt
 
1869
          2     Round
 
1870
          3     Projecting
 
1871
     1                                     join-style
 
1872
          0     Miter
 
1873
          1     Round
 
1874
          2     Bevel
 
1875
     1                                     fill-style
 
1876
          0     Solid
 
1877
          1     Tiled
 
1878
          2     Stippled
 
1879
          3     OpaqueStippled
 
1880
     1                                     fill-rule
 
1881
          0     EvenOdd
 
1882
          1     Winding
 
1883
     4     PIXMAP                          tile
 
1884
     4     PIXMAP                          stipple
 
1885
     2     INT16                           tile-stipple-x-origin
 
1886
     2     INT16                           tile-stipple-y-origin
 
1887
     4     FONT                            font
 
1888
     1                                     subwindow-mode
 
1889
          0     ClipByChildren
 
1890
          1     IncludeInferiors
 
1891
     1     BOOL                            graphics-exposures
 
1892
     2     INT16                           clip-x-origin
 
1893
     2     INT16                           clip-y-origin
 
1894
     4     PIXMAP                          clip-mask
 
1895
          0     None
 
1896
     2     CARD16                          dash-offset
 
1897
     1     CARD8                           dashes
 
1898
     1                                     arc-mode
 
1899
          0     Chord
 
1900
          1     PieSlice
 
1901
 
 
1902
<emphasis role='bold'>ChangeGC</emphasis>
 
1903
     1     56                              opcode
 
1904
     1                                     unused
 
1905
     2     3+n                             request length
 
1906
     4     GCONTEXT                        gc
 
1907
     4     BITMASK                         value-mask (has n bits set to 1)
 
1908
          encodings are the same as for CreateGC
 
1909
     4n     LISTofVALUE                    value-list
 
1910
          encodings are the same as for CreateGC
 
1911
 
 
1912
<emphasis role='bold'>CopyGC</emphasis>
 
1913
     1     57                              opcode
 
1914
     1                                     unused
 
1915
     2     4                               request length
 
1916
     4     GCONTEXT                        src-gc
 
1917
     4     GCONTEXT                        dst-gc
 
1918
     4     BITMASK                         value-mask
 
1919
          encodings are the same as for CreateGC
 
1920
 
 
1921
<emphasis role='bold'>SetDashes</emphasis>
 
1922
     1     58                              opcode
 
1923
     1                                     unused
 
1924
     2     3+(n+p)/4                       request length
 
1925
     4     GCONTEXT                        gc
 
1926
     2     CARD16                          dash-offset
 
1927
     2     n                               length of dashes
 
1928
     n     LISTofCARD8                     dashes
 
1929
     p                                     unused, p=pad(n)
 
1930
 
 
1931
<emphasis role='bold'>SetClipRectangles</emphasis>
 
1932
     1     59                              opcode
 
1933
     1                                     ordering
 
1934
          0     UnSorted
 
1935
          1     YSorted
 
1936
          2     YXSorted
 
1937
          3     YXBanded
 
1938
     2     3+2n                            request length
 
1939
     4     GCONTEXT                        gc
 
1940
     2     INT16                           clip-x-origin
 
1941
     2     INT16                           clip-y-origin
 
1942
     8n     LISTofRECTANGLE                rectangles
 
1943
 
 
1944
<emphasis role='bold'>FreeGC</emphasis>
 
1945
     1     60                              opcode
 
1946
     1                                     unused
 
1947
     2     2                               request length
 
1948
     4     GCONTEXT                        gc
 
1949
 
 
1950
<emphasis role='bold'>ClearArea</emphasis>
 
1951
     1     61                              opcode
 
1952
     1     BOOL                            exposures
 
1953
     2     4                               request length
 
1954
     4     WINDOW                          window
 
1955
     2     INT16                           x
 
1956
     2     INT16                           y
 
1957
     2     CARD16                          width
 
1958
     2     CARD16                          height
 
1959
 
 
1960
<emphasis role='bold'>CopyArea</emphasis>
 
1961
     1     62                              opcode
 
1962
     1                                     unused
 
1963
     2     7                               request length
 
1964
     4     DRAWABLE                        src-drawable
 
1965
     4     DRAWABLE                        dst-drawable
 
1966
     4     GCONTEXT                        gc
 
1967
     2     INT16                           src-x
 
1968
     2     INT16                           src-y
 
1969
     2     INT16                           dst-x
 
1970
     2     INT16                           dst-y
 
1971
     2     CARD16                          width
 
1972
     2     CARD16                          height
 
1973
 
 
1974
<emphasis role='bold'>CopyPlane</emphasis>
 
1975
     1     63                              opcode
 
1976
     1                                     unused
 
1977
     2     8                               request length
 
1978
     4     DRAWABLE                        src-drawable
 
1979
     4     DRAWABLE                        dst-drawable
 
1980
     4     GCONTEXT                        gc
 
1981
     2     INT16                           src-x
 
1982
     2     INT16                           src-y
 
1983
     2     INT16                           dst-x
 
1984
     2     INT16                           dst-y
 
1985
     2     CARD16                          width
 
1986
     2     CARD16                          height
 
1987
     4     CARD32                          bit-plane
 
1988
 
 
1989
<emphasis role='bold'>PolyPoint</emphasis>
 
1990
     1     64                              opcode
 
1991
     1                                     coordinate-mode
 
1992
          0     Origin
 
1993
          1     Previous
 
1994
     2     3+n                             request length
 
1995
     4     DRAWABLE                        drawable
 
1996
     4     GCONTEXT                        gc
 
1997
     4n     LISTofPOINT                    points
 
1998
 
 
1999
<emphasis role='bold'>PolyLine</emphasis>
 
2000
     1     65                              opcode
 
2001
     1                                     coordinate-mode
 
2002
          0     Origin
 
2003
          1     Previous
 
2004
     2     3+n                             request length
 
2005
     4     DRAWABLE                        drawable
 
2006
     4     GCONTEXT                        gc
 
2007
     4n     LISTofPOINT                    points
 
2008
 
 
2009
<emphasis role='bold'>PolySegment</emphasis>
 
2010
     1     66                              opcode
 
2011
     1                                     unused
 
2012
     2     3+2n                            request length
 
2013
     4     DRAWABLE                        drawable
 
2014
     4     GCONTEXT                        gc
 
2015
     8n     LISTofSEGMENT                  segments
 
2016
 
 
2017
  SEGMENT
 
2018
     2     INT16                           x1
 
2019
     2     INT16                           y1
 
2020
     2     INT16                           x2
 
2021
     2     INT16                           y2
 
2022
 
 
2023
<emphasis role='bold'>PolyRectangle</emphasis>
 
2024
     1     67                              opcode
 
2025
     1                                     unused
 
2026
     2     3+2n                            request length
 
2027
     4     DRAWABLE                        drawable
 
2028
     4     GCONTEXT                        gc
 
2029
     8n     LISTofRECTANGLE                rectangles
 
2030
 
 
2031
<emphasis role='bold'>PolyArc</emphasis>
 
2032
     1     68                              opcode
 
2033
     1                                     unused
 
2034
     2     3+3n                            request length
 
2035
     4     DRAWABLE                        drawable
 
2036
     4     GCONTEXT                        gc
 
2037
     12n     LISTofARC                     arcs
 
2038
 
 
2039
<emphasis role='bold'>FillPoly</emphasis>
 
2040
     1     69                              opcode
 
2041
     1                                     unused
 
2042
     2     4+n                             request length
 
2043
     4     DRAWABLE                        drawable
 
2044
     4     GCONTEXT                        gc
 
2045
     1                                     shape
 
2046
          0     Complex
 
2047
          1     Nonconvex
 
2048
          2     Convex
 
2049
     1                                     coordinate-mode
 
2050
          0     Origin
 
2051
          1     Previous
 
2052
     2                                     unused
 
2053
     4n     LISTofPOINT                    points
 
2054
 
 
2055
<emphasis role='bold'>PolyFillRectangle</emphasis>
 
2056
     1     70                              opcode
 
2057
     1                                     unused
 
2058
     2     3+2n                            request length
 
2059
     4     DRAWABLE                        drawable
 
2060
     4     GCONTEXT                        gc
 
2061
     8n     LISTofRECTANGLE                rectangles
 
2062
 
 
2063
<emphasis role='bold'>PolyFillArc</emphasis>
 
2064
     1     71                              opcode
 
2065
     1                                     unused
 
2066
     2     3+3n                            request length
 
2067
     4     DRAWABLE                        drawable
 
2068
     4     GCONTEXT                        gc
 
2069
     12n     LISTofARC                     arcs
 
2070
 
 
2071
<emphasis role='bold'>PutImage</emphasis>
 
2072
     1     72                              opcode
 
2073
     1                                     format
 
2074
          0     Bitmap
 
2075
          1     XYPixmap
 
2076
          2     ZPixmap
 
2077
     2     6+(n+p)/4                       request length
 
2078
     4     DRAWABLE                        drawable
 
2079
     4     GCONTEXT                        gc
 
2080
     2     CARD16                          width
 
2081
     2     CARD16                          height
 
2082
     2     INT16                           dst-x
 
2083
     2     INT16                           dst-y
 
2084
     1     CARD8                           left-pad
 
2085
     1     CARD8                           depth
 
2086
     2                                     unused
 
2087
     n     LISTofBYTE                      data
 
2088
     p                                     unused, p=pad(n)
 
2089
 
 
2090
<emphasis role='bold'>GetImage</emphasis>
 
2091
     1     73                              opcode
 
2092
     1                                     format
 
2093
          1     XYPixmap
 
2094
          2     ZPixmap
 
2095
     2     5                               request length
 
2096
     4     DRAWABLE                        drawable
 
2097
     2     INT16                           x
 
2098
     2     INT16                           y
 
2099
     2     CARD16                          width
 
2100
     2     CARD16                          height
 
2101
     4     CARD32                          plane-mask
 
2102
 
 
2103
-&gt;
 
2104
     1     1                               Reply
 
2105
     1     CARD8                           depth
 
2106
     2     CARD16                          sequence number
 
2107
     4     (n+p)/4                         reply length
 
2108
     4     VISUALID                        visual
 
2109
          0     None
 
2110
     20                                    unused
 
2111
     n     LISTofBYTE                      data
 
2112
     p                                     unused, p=pad(n)
 
2113
 
 
2114
<emphasis role='bold'>PolyText8</emphasis>
 
2115
     1     74                              opcode
 
2116
     1                                     unused
 
2117
     2     4+(n+p)/4                       request length
 
2118
     4     DRAWABLE                        drawable
 
2119
     4     GCONTEXT                        gc
 
2120
     2     INT16                           x
 
2121
     2     INT16                           y
 
2122
     n     LISTofTEXTITEM8                 items
 
2123
     p                                     unused, p=pad(n)  (p is always 0
 
2124
                                           or 1)
 
2125
 
 
2126
  TEXTITEM8
 
2127
     1     m                               length of string (cannot be 255)
 
2128
     1     INT8                            delta
 
2129
     m     STRING8                         string
 
2130
  or
 
2131
     1     255                             font-shift indicator
 
2132
     1                                     font byte 3 (most-significant)
 
2133
     1                                     font byte 2
 
2134
     1                                     font byte 1
 
2135
     1                                     font byte 0 (least-significant)
 
2136
 
 
2137
<emphasis role='bold'>PolyText16</emphasis>
 
2138
     1     75                              opcode
 
2139
     1                                     unused
 
2140
     2     4+(n+p)/4                       request length
 
2141
     4     DRAWABLE                        drawable
 
2142
     4     GCONTEXT                        gc
 
2143
     2     INT16                           x
 
2144
     2     INT16                           y
 
2145
     n     LISTofTEXTITEM16                items
 
2146
     p                                     unused, p=pad(n)  (p must be 0 or
 
2147
                                           1)
 
2148
 
 
2149
  TEXTITEM16
 
2150
     1     m                               number of CHAR2Bs in string
 
2151
                                           (cannot be 255)
 
2152
     1     INT8                            delta
 
2153
     2m     STRING16                       string
 
2154
  or
 
2155
     1     255                             font-shift indicator
 
2156
     1                                     font byte 3 (most-significant)
 
2157
     1                                     font byte 2
 
2158
     1                                     font byte 1
 
2159
     1                                     font byte 0 (least-significant)
 
2160
 
 
2161
<emphasis role='bold'>ImageText8</emphasis>
 
2162
     1     76                              opcode
 
2163
     1     n                               length of string
 
2164
     2     4+(n+p)/4                       request length
 
2165
     4     DRAWABLE                        drawable
 
2166
     4     GCONTEXT                        gc
 
2167
     2     INT16                           x
 
2168
     2     INT16                           y
 
2169
     n     STRING8                         string
 
2170
     p                                     unused, p=pad(n)
 
2171
 
 
2172
<emphasis role='bold'>ImageText16</emphasis>
 
2173
     1     77                              opcode
 
2174
     1     n                               number of CHAR2Bs in string
 
2175
     2     4+(2n+p)/4                      request length
 
2176
     4     DRAWABLE                        drawable
 
2177
     4     GCONTEXT                        gc
 
2178
     2     INT16                           x
 
2179
     2     INT16                           y
 
2180
     2n     STRING16                       string
 
2181
     p                                     unused, p=pad(2n)
 
2182
 
 
2183
<emphasis role='bold'>CreateColormap</emphasis>
 
2184
     1     78                              opcode
 
2185
     1                                     alloc
 
2186
          0     None
 
2187
          1     All
 
2188
     2     4                               request length
 
2189
     4     COLORMAP                        mid
 
2190
     4     WINDOW                          window
 
2191
     4     VISUALID                        visual
 
2192
 
 
2193
<emphasis role='bold'>FreeColormap</emphasis>
 
2194
     1     79                              opcode
 
2195
     1                                     unused
 
2196
     2     2                               request length
 
2197
     4     COLORMAP                        cmap
 
2198
 
 
2199
<emphasis role='bold'>CopyColormapAndFree</emphasis>
 
2200
     1     80                              opcode
 
2201
     1                                     unused
 
2202
     2     3                               request length
 
2203
     4     COLORMAP                        mid
 
2204
     4     COLORMAP                        src-cmap
 
2205
 
 
2206
<emphasis role='bold'>InstallColormap</emphasis>
 
2207
     1     81                              opcode
 
2208
     1                                     unused
 
2209
     2     2                               request length
 
2210
     4     COLORMAP                        cmap
 
2211
 
 
2212
<emphasis role='bold'>UninstallColormap</emphasis>
 
2213
     1     82                              opcode
 
2214
     1                                     unused
 
2215
     2     2                               request length
 
2216
     4     COLORMAP                        cmap
 
2217
 
 
2218
<emphasis role='bold'>ListInstalledColormaps</emphasis>
 
2219
     1     83                              opcode
 
2220
     1                                     unused
 
2221
     2     2                               request length
 
2222
     4     WINDOW                          window
 
2223
 
 
2224
-&gt;
 
2225
     1     1                               Reply
 
2226
     1                                     unused
 
2227
     2     CARD16                          sequence number
 
2228
     4     n                               reply length
 
2229
     2     n                               number of COLORMAPs in cmaps
 
2230
     22                                    unused
 
2231
     4n     LISTofCOLORMAP                 cmaps
 
2232
 
 
2233
<emphasis role='bold'>AllocColor</emphasis>
 
2234
     1     84                              opcode
 
2235
     1                                     unused
 
2236
     2     4                               request length
 
2237
     4     COLORMAP                        cmap
 
2238
     2     CARD16                          red
 
2239
     2     CARD16                          green
 
2240
     2     CARD16                          blue
 
2241
     2                                     unused
 
2242
 
 
2243
-&gt;
 
2244
     1     1                               Reply
 
2245
     1                                     unused
 
2246
     2     CARD16                          sequence number
 
2247
     4     0                               reply length
 
2248
     2     CARD16                          red
 
2249
     2     CARD16                          green
 
2250
     2     CARD16                          blue
 
2251
     2                                     unused
 
2252
     4     CARD32                          pixel
 
2253
     12                                    unused
 
2254
 
 
2255
<emphasis role='bold'>AllocNamedColor</emphasis>
 
2256
     1     85                              opcode
 
2257
     1                                     unused
 
2258
     2     3+(n+p)/4                       request length
 
2259
     4     COLORMAP                        cmap
 
2260
     2     n                               length of name
 
2261
     2                                     unused
 
2262
     n     STRING8                         name
 
2263
     p                                     unused, p=pad(n)
 
2264
 
 
2265
-&gt;
 
2266
     1     1                               Reply
 
2267
     1                                     unused
 
2268
     2     CARD16                          sequence number
 
2269
     4     0                               reply length
 
2270
     4     CARD32                          pixel
 
2271
     2     CARD16                          exact-red
 
2272
     2     CARD16                          exact-green
 
2273
     2     CARD16                          exact-blue
 
2274
     2     CARD16                          visual-red
 
2275
     2     CARD16                          visual-green
 
2276
     2     CARD16                          visual-blue
 
2277
     8                                     unused
 
2278
 
 
2279
<emphasis role='bold'>AllocColorCells</emphasis>
 
2280
     1     86                              opcode
 
2281
     1     BOOL                            contiguous
 
2282
     2     3                               request length
 
2283
     4     COLORMAP                        cmap
 
2284
     2     CARD16                          colors
 
2285
     2     CARD16                          planes
 
2286
 
 
2287
-&gt;
 
2288
     1     1                               Reply
 
2289
     1                                     unused
 
2290
     2     CARD16                          sequence number
 
2291
     4     n+m                             reply length
 
2292
     2     n                               number of CARD32s in pixels
 
2293
     2     m                               number of CARD32s in masks
 
2294
     20                                    unused
 
2295
     4n     LISTofCARD32                   pixels
 
2296
     4m     LISTofCARD32                   masks
 
2297
 
 
2298
<emphasis role='bold'>AllocColorPlanes</emphasis>
 
2299
     1     87                              opcode
 
2300
     1     BOOL                            contiguous
 
2301
     2     4                               request length
 
2302
     4     COLORMAP                        cmap
 
2303
     2     CARD16                          colors
 
2304
     2     CARD16                          reds
 
2305
     2     CARD16                          greens
 
2306
     2     CARD16                          blues
 
2307
 
 
2308
-&gt;
 
2309
     1     1                               Reply
 
2310
     1                                     unused
 
2311
     2     CARD16                          sequence number
 
2312
     4     n                               reply length
 
2313
     2     n                               number of CARD32s in pixels
 
2314
     2                                     unused
 
2315
     4     CARD32                          red-mask
 
2316
     4     CARD32                          green-mask
 
2317
     4     CARD32                          blue-mask
 
2318
     8                                     unused
 
2319
     4n     LISTofCARD32                   pixels
 
2320
 
 
2321
<emphasis role='bold'>FreeColors</emphasis>
 
2322
     1     88                              opcode
 
2323
     1                                     unused
 
2324
     2     3+n                             request length
 
2325
     4     COLORMAP                        cmap
 
2326
     4     CARD32                          plane-mask
 
2327
     4n     LISTofCARD32                   pixels
 
2328
 
 
2329
<emphasis role='bold'>StoreColors</emphasis>
 
2330
     1     89                              opcode
 
2331
     1                                     unused
 
2332
     2     2+3n                            request length
 
2333
     4     COLORMAP                        cmap
 
2334
     12n     LISTofCOLORITEM               items
 
2335
 
 
2336
  COLORITEM
 
2337
     4     CARD32                          pixel
 
2338
     2     CARD16                          red
 
2339
     2     CARD16                          green
 
2340
     2     CARD16                          blue
 
2341
     1                                     do-red, do-green, do-blue
 
2342
          #x01     do-red (1 is True, 0 is False)
 
2343
          #x02     do-green (1 is True, 0 is False)
 
2344
          #x04     do-blue (1 is True, 0 is False)
 
2345
          #xF8     unused
 
2346
     1                                     unused
 
2347
 
 
2348
<emphasis role='bold'>StoreNamedColor</emphasis>
 
2349
     1     90                              opcode
 
2350
     1                                     do-red, do-green, do-blue
 
2351
          #x01     do-red (1 is True, 0 is False)
 
2352
          #x02     do-green (1 is True, 0 is False)
 
2353
          #x04     do-blue (1 is True, 0 is False)
 
2354
          #xF8     unused
 
2355
     2     4+(n+p)/4                       request length
 
2356
     4     COLORMAP                        cmap
 
2357
     4     CARD32                          pixel
 
2358
     2     n                               length of name
 
2359
     2                                     unused
 
2360
     n     STRING8                         name
 
2361
     p                                     unused, p=pad(n)
 
2362
 
 
2363
<emphasis role='bold'>QueryColors</emphasis>
 
2364
     1     91                              opcode
 
2365
     1                                     unused
 
2366
     2     2+n                             request length
 
2367
     4     COLORMAP                        cmap
 
2368
     4n     LISTofCARD32                   pixels
 
2369
 
 
2370
-&gt;
 
2371
     1     1                               Reply
 
2372
     1                                     unused
 
2373
     2     CARD16                          sequence number
 
2374
     4     2n                              reply length
 
2375
     2     n                               number of RGBs in colors
 
2376
     22                                    unused
 
2377
     8n     LISTofRGB                      colors
 
2378
 
 
2379
  RGB
 
2380
     2     CARD16                          red
 
2381
     2     CARD16                          green
 
2382
     2     CARD16                          blue
 
2383
     2                                     unused
 
2384
 
 
2385
<emphasis role='bold'>LookupColor</emphasis>
 
2386
     1     92                              opcode
 
2387
     1                                     unused
 
2388
     2     3+(n+p)/4                       request length
 
2389
     4     COLORMAP                        cmap
 
2390
     2     n                               length of name
 
2391
     2                                     unused
 
2392
     n     STRING8                         name
 
2393
     p                                     unused, p=pad(n)
 
2394
 
 
2395
-&gt;
 
2396
     1     1                               Reply
 
2397
     1                                     unused
 
2398
     2     CARD16                          sequence number
 
2399
     4     0                               reply length
 
2400
     2     CARD16                          exact-red
 
2401
     2     CARD16                          exact-green
 
2402
     2     CARD16                          exact-blue
 
2403
     2     CARD16                          visual-red
 
2404
     2     CARD16                          visual-green
 
2405
     2     CARD16                          visual-blue
 
2406
     12                                    unused
 
2407
 
 
2408
<emphasis role='bold'>CreateCursor</emphasis>
 
2409
     1     93                              opcode
 
2410
     1                                     unused
 
2411
     2     8                               request length
 
2412
     4     CURSOR                          cid
 
2413
     4     PIXMAP                          source
 
2414
     4     PIXMAP                          mask
 
2415
          0     None
 
2416
     2     CARD16                          fore-red
 
2417
     2     CARD16                          fore-green
 
2418
     2     CARD16                          fore-blue
 
2419
     2     CARD16                          back-red
 
2420
     2     CARD16                          back-green
 
2421
     2     CARD16                          back-blue
 
2422
     2     CARD16                          x
 
2423
     2     CARD16                          y
 
2424
 
 
2425
<emphasis role='bold'>CreateGlyphCursor</emphasis>
 
2426
     1     94                              opcode
 
2427
     1                                     unused
 
2428
     2     8                               request length
 
2429
     4     CURSOR                          cid
 
2430
     4     FONT                            source-font
 
2431
     4     FONT                            mask-font
 
2432
          0     None
 
2433
     2     CARD16                          source-char
 
2434
     2     CARD16                          mask-char
 
2435
     2     CARD16                          fore-red
 
2436
     2     CARD16                          fore-green
 
2437
     2     CARD16                          fore-blue
 
2438
     2     CARD16                          back-red
 
2439
     2     CARD16                          back-green
 
2440
     2     CARD16                          back-blue
 
2441
 
 
2442
<emphasis role='bold'>FreeCursor</emphasis>
 
2443
     1     95                              opcode
 
2444
     1                                     unused
 
2445
     2     2                               request length
 
2446
     4     CURSOR                          cursor
 
2447
 
 
2448
<emphasis role='bold'>RecolorCursor</emphasis>
 
2449
     1     96                              opcode
 
2450
     1                                     unused
 
2451
     2     5                               request length
 
2452
     4     CURSOR                          cursor
 
2453
     2     CARD16                          fore-red
 
2454
     2     CARD16                          fore-green
 
2455
     2     CARD16                          fore-blue
 
2456
     2     CARD16                          back-red
 
2457
     2     CARD16                          back-green
 
2458
     2     CARD16                          back-blue
 
2459
 
 
2460
<emphasis role='bold'>QueryBestSize</emphasis>
 
2461
     1     97                              opcode
 
2462
     1                                     class
 
2463
          0     Cursor
 
2464
          1     Tile
 
2465
          2     Stipple
 
2466
     2     3                               request length
 
2467
     4     DRAWABLE                        drawable
 
2468
     2     CARD16                          width
 
2469
     2     CARD16                          height
 
2470
 
 
2471
-&gt;
 
2472
     1     1                               Reply
 
2473
     1                                     unused
 
2474
     2     CARD16                          sequence number
 
2475
     4     0                               reply length
 
2476
     2     CARD16                          width
 
2477
     2     CARD16                          height
 
2478
     20                                    unused
 
2479
 
 
2480
<emphasis role='bold'>QueryExtension</emphasis>
 
2481
     1     98                              opcode
 
2482
     1                                     unused
 
2483
     2     2+(n+p)/4                       request length
 
2484
     2     n                               length of name
 
2485
     2                                     unused
 
2486
     n     STRING8                         name
 
2487
     p                                     unused, p=pad(n)
 
2488
 
 
2489
-&gt;
 
2490
     1     1                               Reply
 
2491
     1                                     unused
 
2492
     2     CARD16                          sequence number
 
2493
     4     0                               reply length
 
2494
     1     BOOL                            present
 
2495
     1     CARD8                           major-opcode
 
2496
     1     CARD8                           first-event
 
2497
     1     CARD8                           first-error
 
2498
     20                                    unused
 
2499
 
 
2500
<emphasis role='bold'>ListExtensions</emphasis>
 
2501
     1     99                              opcode
 
2502
     1                                     unused
 
2503
     2     1                               request length
 
2504
 
 
2505
-&gt;
 
2506
     1     1                               Reply
 
2507
     1     CARD8                           number of STRs in names
 
2508
     2     CARD16                          sequence number
 
2509
     4     (n+p)/4                         reply length
 
2510
     24                                    unused
 
2511
     n     LISTofSTR                       names
 
2512
     p                                     unused, p=pad(n)
 
2513
 
 
2514
<emphasis role='bold'>ChangeKeyboardMapping</emphasis>
 
2515
     1     100                             opcode
 
2516
     1     n                               keycode-count
 
2517
     2     2+nm                            request length
 
2518
     1     KEYCODE                         first-keycode
 
2519
     1     m                               keysyms-per-keycode
 
2520
     2                                     unused
 
2521
     4nm     LISTofKEYSYM                  keysyms
 
2522
 
 
2523
<emphasis role='bold'>GetKeyboardMapping</emphasis>
 
2524
     1     101                             opcode
 
2525
     1                                     unused
 
2526
     2     2                               request length
 
2527
     1     KEYCODE                         first-keycode
 
2528
     1     m                               count
 
2529
     2                                     unused
 
2530
 
 
2531
-&gt;
 
2532
     1     1                               Reply
 
2533
     1     n                               keysyms-per-keycode
 
2534
     2     CARD16                          sequence number
 
2535
     4     nm                              reply length (m = count field
 
2536
                                           from the request)
 
2537
     24                                    unused
 
2538
     4nm     LISTofKEYSYM                  keysyms
 
2539
 
 
2540
<emphasis role='bold'>ChangeKeyboardControl</emphasis>
 
2541
     1     102                             opcode
 
2542
     1                                     unused
 
2543
     2     2+n                             request length
 
2544
     4     BITMASK                         value-mask (has n bits set to 1)
 
2545
          #x0001     key-click-percent
 
2546
          #x0002     bell-percent
 
2547
          #x0004     bell-pitch
 
2548
          #x0008     bell-duration
 
2549
          #x0010     led
 
2550
          #x0020     led-mode
 
2551
          #x0040     key
 
2552
          #x0080     auto-repeat-mode
 
2553
     4n     LISTofVALUE                    value-list
 
2554
 
 
2555
  VALUEs
 
2556
     1     INT8                            key-click-percent
 
2557
     1     INT8                            bell-percent
 
2558
     2     INT16                           bell-pitch
 
2559
     2     INT16                           bell-duration
 
2560
     1     CARD8                           led
 
2561
     1                                     led-mode
 
2562
          0     Off
 
2563
          1     On
 
2564
     1     KEYCODE                         key
 
2565
     1                                     auto-repeat-mode
 
2566
          0     Off
 
2567
          1     On
 
2568
          2     Default
 
2569
 
 
2570
<emphasis role='bold'>GetKeyboardControl</emphasis>
 
2571
     1     103                             opcode
 
2572
     1                                     unused
 
2573
     2     1                               request length
 
2574
 
 
2575
-&gt;
 
2576
     1     1                               Reply
 
2577
     1                                     global-auto-repeat
 
2578
          0     Off
 
2579
          1     On
 
2580
     2     CARD16                          sequence number
 
2581
     4     5                               reply length
 
2582
     4     CARD32                          led-mask
 
2583
     1     CARD8                           key-click-percent
 
2584
     1     CARD8                           bell-percent
 
2585
     2     CARD16                          bell-pitch
 
2586
     2     CARD16                          bell-duration
 
2587
     2                                     unused
 
2588
     32     LISTofCARD8                    auto-repeats
 
2589
 
 
2590
<emphasis role='bold'>Bell</emphasis>
 
2591
     1     104                             opcode
 
2592
     1     INT8                            percent
 
2593
     2     1                               request length
 
2594
 
 
2595
<emphasis role='bold'>ChangePointerControl</emphasis>
 
2596
     1     105                             opcode
 
2597
     1                                     unused
 
2598
     2     3                               request length
 
2599
     2     INT16                           acceleration-numerator
 
2600
     2     INT16                           acceleration-denominator
 
2601
     2     INT16                           threshold
 
2602
     1     BOOL                            do-acceleration
 
2603
     1     BOOL                            do-threshold
 
2604
 
 
2605
<emphasis role='bold'>GetPointerControl</emphasis>
 
2606
     1     106                             opcode
 
2607
     1                                     unused
 
2608
     2     1                               request length
 
2609
 
 
2610
-&gt;
 
2611
     1     1                               Reply
 
2612
     1                                     unused
 
2613
     2     CARD16                          sequence number
 
2614
     4     0                               reply length
 
2615
     2     CARD16                          acceleration-numerator
 
2616
     2     CARD16                          acceleration-denominator
 
2617
     2     CARD16                          threshold
 
2618
     18                                    unused
 
2619
 
 
2620
<emphasis role='bold'>SetScreenSaver</emphasis>
 
2621
     1     107                             opcode
 
2622
     1                                     unused
 
2623
     2     3                               request length
 
2624
     2     INT16                           timeout
 
2625
     2     INT16                           interval
 
2626
     1                                     prefer-blanking
 
2627
          0     No
 
2628
          1     Yes
 
2629
          2     Default
 
2630
     1                                     allow-exposures
 
2631
          0     No
 
2632
          1     Yes
 
2633
          2     Default
 
2634
     2                                     unused
 
2635
 
 
2636
<emphasis role='bold'>GetScreenSaver</emphasis>
 
2637
     1     108                             opcode
 
2638
     1                                     unused
 
2639
     2     1                               request length
 
2640
 
 
2641
-&gt;
 
2642
     1     1                               Reply
 
2643
     1                                     unused
 
2644
     2     CARD16                          sequence number
 
2645
     4     0                               reply length
 
2646
     2     CARD16                          timeout
 
2647
     2     CARD16                          interval
 
2648
     1                                     prefer-blanking
 
2649
          0     No
 
2650
          1     Yes
 
2651
     1                                     allow-exposures
 
2652
          0     No
 
2653
          1     Yes
 
2654
     18                                    unused
 
2655
 
 
2656
<emphasis role='bold'>ChangeHosts</emphasis>
 
2657
     1     109                             opcode
 
2658
     1                                     mode
 
2659
          0     Insert
 
2660
          1     Delete
 
2661
     2     2+(n+p)/4                       request length
 
2662
     1                                     family
 
2663
          0     Internet
 
2664
          1     DECnet
 
2665
          2     Chaos
 
2666
     1                                     unused
 
2667
     2     n                               length of address
 
2668
     n     LISTofCARD8                     address
 
2669
     p                                     unused, p=pad(n)
 
2670
 
 
2671
<emphasis role='bold'>ListHosts</emphasis>
 
2672
     1     110                             opcode
 
2673
     1                                     unused
 
2674
     2     1                               request length
 
2675
 
 
2676
-&gt;
 
2677
     1     1                               Reply
 
2678
     1                                     mode
 
2679
          0     Disabled
 
2680
          1     Enabled
 
2681
     2     CARD16                          sequence number
 
2682
     4     n/4                             reply length
 
2683
     2     CARD16                          number of HOSTs in hosts
 
2684
     22                                    unused
 
2685
     n     LISTofHOST                      hosts (n always a multiple of 4)
 
2686
 
 
2687
<emphasis role='bold'>SetAccessControl</emphasis>
 
2688
     1     111                             opcode
 
2689
     1                                     mode
 
2690
          0     Disable
 
2691
          1     Enable
 
2692
     2     1                               request length
 
2693
 
 
2694
<emphasis role='bold'>SetCloseDownMode</emphasis>
 
2695
     1     112                             opcode
 
2696
     1                                     mode
 
2697
          0     Destroy
 
2698
          1     RetainPermanent
 
2699
          2     RetainTemporary
 
2700
     2     1                               request length
 
2701
 
 
2702
<emphasis role='bold'>KillClient</emphasis>
 
2703
     1     113                             opcode
 
2704
     1                                     unused
 
2705
     2     2                               request length
 
2706
     4     CARD32                          resource
 
2707
          0     AllTemporary
 
2708
 
 
2709
<emphasis role='bold'>RotateProperties</emphasis>
 
2710
     1     114                             opcode
 
2711
     1                                     unused
 
2712
     2     3+n                             request length
 
2713
     4     WINDOW                          window
 
2714
     2     n                               number of properties
 
2715
     2     INT16                           delta
 
2716
     4n    LISTofATOM                      properties
 
2717
 
 
2718
<emphasis role='bold'>ForceScreenSaver</emphasis>
 
2719
     1     115                             opcode
 
2720
     1                                     mode
 
2721
          0     Reset
 
2722
          1     Activate
 
2723
     2     1                               request length
 
2724
 
 
2725
<emphasis role='bold'>SetPointerMapping</emphasis>
 
2726
     1     116                             opcode
 
2727
     1     n                               length of map
 
2728
     2     1+(n+p)/4                       request length
 
2729
     n     LISTofCARD8                     map
 
2730
     p                                     unused, p=pad(n)
 
2731
 
 
2732
-&gt;
 
2733
     1     1                               Reply
 
2734
     1                                     status
 
2735
          0     Success
 
2736
          1     Busy
 
2737
     2     CARD16                          sequence number
 
2738
     4     0                               reply length
 
2739
     24                                    unused
 
2740
 
 
2741
<emphasis role='bold'>GetPointerMapping</emphasis>
 
2742
     1     117                             opcode
 
2743
     1                                     unused
 
2744
     2     1                               request length
 
2745
 
 
2746
-&gt;
 
2747
     1     1                               Reply
 
2748
     1     n                               length of map
 
2749
     2     CARD16                          sequence number
 
2750
     4     (n+p)/4                         reply length
 
2751
     24                                    unused
 
2752
     n     LISTofCARD8                     map
 
2753
     p                                     unused, p=pad(n)
 
2754
 
 
2755
<emphasis role='bold'>SetModifierMapping</emphasis>
 
2756
     1     118                             opcode
 
2757
     1     n                               keycodes-per-modifier
 
2758
     2     1+2n                            request length
 
2759
     8n    LISTofKEYCODE                   keycodes
 
2760
 
 
2761
-&gt;
 
2762
     1     1                               Reply
 
2763
     1                                     status
 
2764
          0     Success
 
2765
          1     Busy
 
2766
          2     Failed
 
2767
     2     CARD16                          sequence number
 
2768
     4     0                               reply length
 
2769
     24                                    unused
 
2770
 
 
2771
<emphasis role='bold'>GetModifierMapping</emphasis>
 
2772
     1     119                             opcode
 
2773
     1                                     unused
 
2774
     2     1                               request length
 
2775
 
 
2776
-&gt;
 
2777
     1     1                               Reply
 
2778
     1     n                               keycodes-per-modifier
 
2779
     2     CARD16                          sequence number
 
2780
     4     2n                              reply length
 
2781
     24                                    unused
 
2782
     8n     LISTofKEYCODE                  keycodes
 
2783
 
 
2784
<emphasis role='bold'>NoOperation</emphasis>
 
2785
     1     127                             opcode
 
2786
     1                                     unused
 
2787
     2     1+n                             request length
 
2788
     4n                                    unused
 
2789
</literallayout>
 
2790
</sect1>
 
2791
 
 
2792
<sect1 id="events_2">
 
2793
<title>Events</title>
 
2794
 
 
2795
<literallayout class="monospaced">
 
2796
<emphasis role='bold'>KeyPress</emphasis>
 
2797
     1     2                               code
 
2798
     1     KEYCODE                         detail
 
2799
     2     CARD16                          sequence number
 
2800
     4     TIMESTAMP                       time
 
2801
     4     WINDOW                          root
 
2802
     4     WINDOW                          event
 
2803
     4     WINDOW                          child
 
2804
          0     None
 
2805
     2     INT16                           root-x
 
2806
     2     INT16                           root-y
 
2807
     2     INT16                           event-x
 
2808
     2     INT16                           event-y
 
2809
     2     SETofKEYBUTMASK                 state
 
2810
     1     BOOL                            same-screen
 
2811
     1                                     unused
 
2812
 
 
2813
<emphasis role='bold'>KeyRelease</emphasis>
 
2814
     1     3                               code
 
2815
     1     KEYCODE                         detail
 
2816
     2     CARD16                          sequence number
 
2817
     4     TIMESTAMP                       time
 
2818
     4     WINDOW                          root
 
2819
     4     WINDOW                          event
 
2820
     4     WINDOW                          child
 
2821
          0     None
 
2822
     2     INT16                           root-x
 
2823
     2     INT16                           root-y
 
2824
     2     INT16                           event-x
 
2825
     2     INT16                           event-y
 
2826
     2     SETofKEYBUTMASK                 state
 
2827
     1     BOOL                            same-screen
 
2828
     1                                     unused
 
2829
 
 
2830
<emphasis role='bold'>ButtonPress</emphasis>
 
2831
     1     4                               code
 
2832
     1     BUTTON                          detail
 
2833
     2     CARD16                          sequence number
 
2834
     4     TIMESTAMP                       time
 
2835
     4     WINDOW                          root
 
2836
     4     WINDOW                          event
 
2837
     4     WINDOW                          child
 
2838
          0     None
 
2839
     2     INT16                           root-x
 
2840
     2     INT16                           root-y
 
2841
     2     INT16                           event-x
 
2842
     2     INT16                           event-y
 
2843
     2     SETofKEYBUTMASK                 state
 
2844
     1     BOOL                            same-screen
 
2845
     1                                     unused
 
2846
 
 
2847
<emphasis role='bold'>ButtonRelease</emphasis>
 
2848
     1     5                               code
 
2849
     1     BUTTON                          detail
 
2850
     2     CARD16                          sequence number
 
2851
     4     TIMESTAMP                       time
 
2852
     4     WINDOW                          root
 
2853
     4     WINDOW                          event
 
2854
     4     WINDOW                          child
 
2855
          0     None
 
2856
     2     INT16                           root-x
 
2857
     2     INT16                           root-y
 
2858
     2     INT16                           event-x
 
2859
     2     INT16                           event-y
 
2860
     2     SETofKEYBUTMASK                 state
 
2861
     1     BOOL                            same-screen
 
2862
     1                                     unused
 
2863
 
 
2864
<emphasis role='bold'>MotionNotify</emphasis>
 
2865
     1     6                               code
 
2866
     1                                     detail
 
2867
          0     Normal
 
2868
          1     Hint
 
2869
     2     CARD16                          sequence number
 
2870
     4     TIMESTAMP                       time
 
2871
     4     WINDOW                          root
 
2872
     4     WINDOW                          event
 
2873
     4     WINDOW                          child
 
2874
           0     None
 
2875
     2     INT16                           root-x
 
2876
     2     INT16                           root-y
 
2877
     2     INT16                           event-x
 
2878
     2     INT16                           event-y
 
2879
     2     SETofKEYBUTMASK                 state
 
2880
     1     BOOL                            same-screen
 
2881
     1                                     unused
 
2882
 
 
2883
<emphasis role='bold'>EnterNotify</emphasis>
 
2884
     1     7                               code
 
2885
     1                                     detail
 
2886
          0     Ancestor
 
2887
          1     Virtual
 
2888
          2     Inferior
 
2889
          3     Nonlinear
 
2890
          4     NonlinearVirtual
 
2891
     2     CARD16                          sequence number
 
2892
     4     TIMESTAMP                       time
 
2893
     4     WINDOW                          root
 
2894
     4     WINDOW                          event
 
2895
     4     WINDOW                          child
 
2896
          0     None
 
2897
     2     INT16                           root-x
 
2898
     2     INT16                           root-y
 
2899
     2     INT16                           event-x
 
2900
     2     INT16                           event-y
 
2901
     2     SETofKEYBUTMASK                 state
 
2902
     1                                     mode
 
2903
          0     Normal
 
2904
          1     Grab
 
2905
          2     Ungrab
 
2906
     1                                     same-screen, focus
 
2907
          #x01     focus (1 is True, 0 is False)
 
2908
          #x02     same-screen (1 is True, 0 is False)
 
2909
          #xFC     unused
 
2910
 
 
2911
<emphasis role='bold'>LeaveNotify</emphasis>
 
2912
     1     8                               code
 
2913
     1                                     detail
 
2914
          0     Ancestor
 
2915
          1     Virtual
 
2916
          2     Inferior
 
2917
          3     Nonlinear
 
2918
          4     NonlinearVirtual
 
2919
     2     CARD16                          sequence number
 
2920
     4     TIMESTAMP                       time
 
2921
     4     WINDOW                          root
 
2922
     4     WINDOW                          event
 
2923
     4     WINDOW                          child
 
2924
          0     None
 
2925
     2     INT16                           root-x
 
2926
     2     INT16                           root-y
 
2927
     2     INT16                           event-x
 
2928
     2     INT16                           event-y
 
2929
     2     SETofKEYBUTMASK                 state
 
2930
     1                                     mode
 
2931
          0     Normal
 
2932
          1     Grab
 
2933
          2     Ungrab
 
2934
     1                                     same-screen, focus
 
2935
          #x01     focus (1 is True, 0 is False)
 
2936
          #x02     same-screen (1 is True, 0 is False)
 
2937
          #xFC     unused
 
2938
 
 
2939
<emphasis role='bold'>FocusIn</emphasis>
 
2940
     1     9                               code
 
2941
     1                                     detail
 
2942
          0     Ancestor
 
2943
          1     Virtual
 
2944
          2     Inferior
 
2945
          3     Nonlinear
 
2946
          4     NonlinearVirtual
 
2947
          5     Pointer
 
2948
          6     PointerRoot
 
2949
          7     None
 
2950
     2     CARD16                          sequence number
 
2951
     4     WINDOW                          event
 
2952
     1                                     mode
 
2953
          0     Normal
 
2954
          1     Grab
 
2955
          2     Ungrab
 
2956
          3     WhileGrabbed
 
2957
     23                                    unused
 
2958
 
 
2959
<emphasis role='bold'>FocusOut</emphasis>
 
2960
     1     10                              code
 
2961
     1                                     detail
 
2962
          0     Ancestor
 
2963
          1     Virtual
 
2964
          2     Inferior
 
2965
          3     Nonlinear
 
2966
          4     NonlinearVirtual
 
2967
          5     Pointer
 
2968
          6     PointerRoot
 
2969
          7     None
 
2970
     2     CARD16                          sequence number
 
2971
     4     WINDOW                          event
 
2972
     1                                     mode
 
2973
          0     Normal
 
2974
          1     Grab
 
2975
          2     Ungrab
 
2976
          3     WhileGrabbed
 
2977
     23                                    unused
 
2978
 
 
2979
<emphasis role='bold'>KeymapNotify</emphasis>
 
2980
     1     11                              code
 
2981
     31    LISTofCARD8                     keys (byte for keycodes 0-7 is
 
2982
                                           omitted)
 
2983
 
 
2984
<emphasis role='bold'>Expose</emphasis>
 
2985
     1     12                              code
 
2986
     1                                     unused
 
2987
     2     CARD16                          sequence number
 
2988
     4     WINDOW                          window
 
2989
     2     CARD16                          x
 
2990
     2     CARD16                          y
 
2991
     2     CARD16                          width
 
2992
     2     CARD16                          height
 
2993
     2     CARD16                          count
 
2994
     14                                    unused
 
2995
 
 
2996
<emphasis role='bold'>GraphicsExposure</emphasis>
 
2997
     1     13                              code
 
2998
     1                                     unused
 
2999
     2     CARD16                          sequence number
 
3000
     4     DRAWABLE                        drawable
 
3001
     2     CARD16                          x
 
3002
     2     CARD16                          y
 
3003
     2     CARD16                          width
 
3004
     2     CARD16                          height
 
3005
     2     CARD16                          minor-opcode
 
3006
     2     CARD16                          count
 
3007
     1     CARD8                           major-opcode
 
3008
     11                                    unused
 
3009
 
 
3010
<emphasis role='bold'>NoExposure</emphasis>
 
3011
     1     14                              code
 
3012
     1                                     unused
 
3013
     2     CARD16                          sequence number
 
3014
     4     DRAWABLE                        drawable
 
3015
     2     CARD16                          minor-opcode
 
3016
     1     CARD8                           major-opcode
 
3017
     21                                    unused
 
3018
 
 
3019
<emphasis role='bold'>VisibilityNotify</emphasis>
 
3020
     1     15                              code
 
3021
     1                                     unused
 
3022
     2     CARD16                          sequence number
 
3023
     4     WINDOW                          window
 
3024
     1                                     state
 
3025
          0     Unobscured
 
3026
          1     PartiallyObscured
 
3027
          2     FullyObscured
 
3028
     23                                    unused
 
3029
 
 
3030
<emphasis role='bold'>CreateNotify</emphasis>
 
3031
     1     16                              code
 
3032
     1                                     unused
 
3033
     2     CARD16                          sequence number
 
3034
     4     WINDOW                          parent
 
3035
     4     WINDOW                          window
 
3036
     2     INT16                           x
 
3037
     2     INT16                           y
 
3038
     2     CARD16                          width
 
3039
     2     CARD16                          height
 
3040
     2     CARD16                          border-width
 
3041
     1     BOOL                            override-redirect
 
3042
     9                                     unused
 
3043
 
 
3044
<emphasis role='bold'>DestroyNotify</emphasis>
 
3045
     1     17                              code
 
3046
     1                                     unused
 
3047
     2     CARD16                          sequence number
 
3048
     4     WINDOW                          event
 
3049
     4     WINDOW                          window
 
3050
     20                                    unused
 
3051
 
 
3052
<emphasis role='bold'>UnmapNotify</emphasis>
 
3053
     1     18                              code
 
3054
     1                                     unused
 
3055
     2     CARD16                          sequence number
 
3056
     4     WINDOW                          event
 
3057
     4     WINDOW                          window
 
3058
     1     BOOL                            from-configure
 
3059
     19                                    unused
 
3060
 
 
3061
<emphasis role='bold'>MapNotify</emphasis>
 
3062
     1     19                              code
 
3063
     1                                     unused
 
3064
     2     CARD16                          sequence number
 
3065
     4     WINDOW                          event
 
3066
     4     WINDOW                          window
 
3067
     1     BOOL                            override-redirect
 
3068
     19                                    unused
 
3069
 
 
3070
<emphasis role='bold'>MapRequest</emphasis>
 
3071
     1     20                              code
 
3072
     1                                     unused
 
3073
     2     CARD16                          sequence number
 
3074
     4     WINDOW                          parent
 
3075
     4     WINDOW                          window
 
3076
     20                                    unused
 
3077
 
 
3078
<emphasis role='bold'>ReparentNotify</emphasis>
 
3079
     1     21                              code
 
3080
     1                                     unused
 
3081
     2     CARD16                          sequence number
 
3082
     4     WINDOW                          event
 
3083
     4     WINDOW                          window
 
3084
     4     WINDOW                          parent
 
3085
     2     INT16                           x
 
3086
     2     INT16                           y
 
3087
     1     BOOL                            override-redirect
 
3088
     11                                    unused
 
3089
 
 
3090
<emphasis role='bold'>ConfigureNotify</emphasis>
 
3091
     1     22                              code
 
3092
     1                                     unused
 
3093
     2     CARD16                          sequence number
 
3094
     4     WINDOW                          event
 
3095
     4     WINDOW                          window
 
3096
     4     WINDOW                          above-sibling
 
3097
          0     None
 
3098
     2     INT16                           x
 
3099
     2     INT16                           y
 
3100
     2     CARD16                          width
 
3101
     2     CARD16                          height
 
3102
     2     CARD16                          border-width
 
3103
     1     BOOL                            override-redirect
 
3104
     5                                     unused
 
3105
 
 
3106
<emphasis role='bold'>ConfigureRequest</emphasis>
 
3107
     1     23                              code
 
3108
     1                                     stack-mode
 
3109
          0     Above
 
3110
          1     Below
 
3111
          2     TopIf
 
3112
          3     BottomIf
 
3113
          4     Opposite
 
3114
     2     CARD16                          sequence number
 
3115
     4     WINDOW                          parent
 
3116
     4     WINDOW                          window
 
3117
     4     WINDOW                          sibling
 
3118
          0     None
 
3119
     2     INT16                           x
 
3120
     2     INT16                           y
 
3121
     2     CARD16                          width
 
3122
     2     CARD16                          height
 
3123
     2     CARD16                          border-width
 
3124
     2     BITMASK                         value-mask
 
3125
          #x0001     x
 
3126
          #x0002     y
 
3127
          #x0004     width
 
3128
          #x0008     height
 
3129
          #x0010     border-width
 
3130
          #x0020     sibling
 
3131
          #x0040     stack-mode
 
3132
     4                                     unused
 
3133
 
 
3134
<emphasis role='bold'>GravityNotify</emphasis>
 
3135
     1     24                              code
 
3136
     1                                     unused
 
3137
     2     CARD16                          sequence number
 
3138
     4     WINDOW                          event
 
3139
     4     WINDOW                          window
 
3140
     2     INT16                           x
 
3141
     2     INT16                           y
 
3142
     16                                    unused
 
3143
 
 
3144
<emphasis role='bold'>ResizeRequest</emphasis>
 
3145
     1     25                              code
 
3146
     1                                     unused
 
3147
     2     CARD16                          sequence number
 
3148
     4     WINDOW                          window
 
3149
     2     CARD16                          width
 
3150
     2     CARD16                          height
 
3151
     20                                    unused
 
3152
 
 
3153
<emphasis role='bold'>CirculateNotify</emphasis>
 
3154
     1     26                              code
 
3155
     1                                     unused
 
3156
     2     CARD16                          sequence number
 
3157
     4     WINDOW                          event
 
3158
     4     WINDOW                          window
 
3159
     4     WINDOW                          unused
 
3160
     1                                     place
 
3161
          0     Top
 
3162
          1     Bottom
 
3163
     15                                    unused
 
3164
 
 
3165
<emphasis role='bold'>CirculateRequest</emphasis>
 
3166
     1     27                              code
 
3167
     1                                     unused
 
3168
     2     CARD16                          sequence number
 
3169
     4     WINDOW                          parent
 
3170
     4     WINDOW                          window
 
3171
     4                                     unused
 
3172
     1                                     place
 
3173
          0     Top
 
3174
          1     Bottom
 
3175
     15                                    unused
 
3176
 
 
3177
<emphasis role='bold'>PropertyNotify</emphasis>
 
3178
     1     28                              code
 
3179
     1                                     unused
 
3180
     2     CARD16                          sequence number
 
3181
     4     WINDOW                          window
 
3182
     4     ATOM                            atom
 
3183
     4     TIMESTAMP                       time
 
3184
     1                                     state
 
3185
          0     NewValue
 
3186
          1     Deleted
 
3187
     15                                    unused
 
3188
 
 
3189
<emphasis role='bold'>SelectionClear</emphasis>
 
3190
     1     29                              code
 
3191
     1                                     unused
 
3192
     2     CARD16                          sequence number
 
3193
     4     TIMESTAMP                       time
 
3194
     4     WINDOW                          owner
 
3195
     4     ATOM                            selection
 
3196
     16                                    unused
 
3197
 
 
3198
<emphasis role='bold'>SelectionRequest</emphasis>
 
3199
     1     30                              code
 
3200
     1                                     unused
 
3201
     2     CARD16                          sequence number
 
3202
     4     TIMESTAMP                       time
 
3203
          0     CurrentTime
 
3204
     4     WINDOW                          owner
 
3205
     4     WINDOW                          requestor
 
3206
     4     ATOM                            selection
 
3207
     4     ATOM                            target
 
3208
     4     ATOM                            property
 
3209
          0     None
 
3210
     4                                     unused
 
3211
 
 
3212
<emphasis role='bold'>SelectionNotify</emphasis>
 
3213
     1     31                              code
 
3214
     1                                     unused
 
3215
     2     CARD16                          sequence number
 
3216
     4     TIMESTAMP                       time
 
3217
          0     CurrentTime
 
3218
     4     WINDOW                          requestor
 
3219
     4     ATOM                            selection
 
3220
     4     ATOM                            target
 
3221
     4     ATOM                            property
 
3222
          0     None
 
3223
     8                                     unused
 
3224
 
 
3225
<emphasis role='bold'>ColormapNotify</emphasis>
 
3226
     1     32                              code
 
3227
     1                                     unused
 
3228
     2     CARD16                          sequence number
 
3229
     4     WINDOW                          window
 
3230
     4     COLORMAP                        colormap
 
3231
          0     None
 
3232
     1     BOOL                            new
 
3233
     1                                     state
 
3234
          0     Uninstalled
 
3235
          1     Installed
 
3236
     18                                    unused
 
3237
 
 
3238
<emphasis role='bold'>ClientMessage</emphasis>
 
3239
     1     33                              code
 
3240
     1     CARD8                           format
 
3241
     2     CARD16                          sequence number
 
3242
     4     WINDOW                          window
 
3243
     4     ATOM                            type
 
3244
     20                                    data
 
3245
 
 
3246
<emphasis role='bold'>MappingNotify</emphasis>
 
3247
     1     34                              code
 
3248
     1                                     unused
 
3249
     2     CARD16                          sequence number
 
3250
     1                                     request
 
3251
          0     Modifier
 
3252
          1     Keyboard
 
3253
          2     Pointer
 
3254
     1     KEYCODE                         first-keycode
 
3255
     1     CARD8                           count
 
3256
     25                                    unused
 
3257
</literallayout>
 
3258
 
 
3259
</sect1>
 
3260
</appendix>