free-sw/xcb/proto
9 years agoxinput: remove TODO-entry for sumof and ListInputDevices ListInputDevices-V3
Christian Linhart [Wed, 3 Sep 2014 11:38:30 +0000 (13:38 +0200)]
xinput: remove TODO-entry for sumof and ListInputDevices

Message-ID: <1409744310-4684-1-git-send-email-chris@demorecorder.com>
Patch-Thread-Subject: [Xcb] xinput: make ListInputDevices work, sumof with nested expr, ...
Patch-Set: ListInputDevices
Patch-Number: proto 8/8
Patch-Version: V1
Signed-off-by: Christian Linhart <chris@DemoRecorder.com>
9 years agoxinput: req ListInputDevices: remove obsolete structs
Christian Linhart [Wed, 3 Sep 2014 11:18:00 +0000 (13:18 +0200)]
xinput: req ListInputDevices: remove obsolete structs

Remove structs that are no longer needed because of modeling
this request/reply with new xml-constructs.

Removing these structs modifies the API but maybe it's still OK.

Message-ID: <1409743080-302-7-git-send-email-chris@demorecorder.com>
Patch-Thread-Subject: [Xcb] xinput: make ListInputDevices work, sumof with nested expr, ...
Patch-Set: ListInputDevices
Patch-Number: proto 7/7
Patch-Version: V1
Signed-off-by: Christian Linhart <chris@DemoRecorder.com>
9 years agoxinput: Remove struct DeviceName
Christian Linhart [Wed, 3 Sep 2014 11:17:59 +0000 (13:17 +0200)]
xinput: Remove struct DeviceName

Remove struct DeviceName because it is identical to struct STR from xproto.xml

Message-ID: <1409743080-302-6-git-send-email-chris@demorecorder.com>
Patch-Thread-Subject: [Xcb] xinput: make ListInputDevices work, sumof with nested expr, ...
Patch-Set: ListInputDevices
Patch-Number: proto 6/7
Patch-Version: V1
Signed-off-by: Christian Linhart <chris@DemoRecorder.com>
9 years agoxinput: ListInputDevices: full support
Christian Linhart [Wed, 3 Sep 2014 11:17:58 +0000 (13:17 +0200)]
xinput: ListInputDevices: full support

* define struct InputInfo with switch-case
* define the lists "infos" and "names"
* the list "infos" requires a new xml-construct:
  <sumof> with a nested expression, to access fields
  of the list which is iterated by sumof.

spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt?id=inputproto-2.3.1#n305
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml?id=libXi-1.7.4#n715

code:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/src/XListDev.c?id=libXi-1.7.4

Both specs are misleading ( or buggy ) in the following aspect:

In both specs, struct Deviceinfo is defined to contain a list
of InputInfo and a list of STR.

But, by analyzing the code in libXi, it was clear that
* InputInfo is contained in an extra toplevel list
  in the reply ListInputDevices
* the strings ( struct xproto:STR ) are also contained in a toplevel list
  in the reply

Message-ID: <1409743080-302-5-git-send-email-chris@demorecorder.com>
Patch-Thread-Subject: [Xcb] xinput: make ListInputDevices work, sumof with nested expr, ...
Patch-Set: ListInputDevices
Patch-Number: proto 5/7
Patch-Version: V1
Signed-off-by: Christian Linhart <chris@DemoRecorder.com>
9 years agoxcbgen: sumof with nested expression
Christian Linhart [Wed, 3 Sep 2014 11:17:57 +0000 (13:17 +0200)]
xcbgen: sumof with nested expression

Add parser support for sumof with a nested expression.
For example:
<sumof ref="mylist1">
<fieldref>bar</fieldref>
</sumof>

The nested expression is added as the "rhs"-field of the
expression.object.

Message-ID: <1409743080-302-4-git-send-email-chris@demorecorder.com>
Patch-Thread-Subject: [Xcb] xinput: make ListInputDevices work, sumof with nested expr, ...
Patch-Set: ListInputDevices
Patch-Number: proto 4/7
Patch-Version: V1
Signed-off-by: Christian Linhart <chris@DemoRecorder.com>
9 years agoschema: add rule for sumof with nested expression
Christian Linhart [Wed, 3 Sep 2014 11:17:56 +0000 (13:17 +0200)]
schema: add rule for sumof with nested expression

Message-ID: <1409743080-302-3-git-send-email-chris@demorecorder.com>
Patch-Thread-Subject: [Xcb] xinput: make ListInputDevices work, sumof with nested expr, ...
Patch-Set: ListInputDevices
Patch-Number: proto 3/7
Patch-Version: V1
Signed-off-by: Christian Linhart <chris@DemoRecorder.com>
9 years agoxml-doc: add sumof with nested expression
Christian Linhart [Wed, 3 Sep 2014 11:17:55 +0000 (13:17 +0200)]
xml-doc: add sumof with nested expression

Message-ID: <1409743080-302-2-git-send-email-chris@demorecorder.com>
Patch-Thread-Subject: [Xcb] xinput: make ListInputDevices work, sumof with nested expr, ...
Patch-Set: ListInputDevices
Patch-Number: proto 2/7
Patch-Version: V1
Signed-off-by: Christian Linhart <chris@DemoRecorder.com>
9 years agoxcbgen: fields get a parent reference
Christian Linhart [Wed, 3 Sep 2014 11:17:54 +0000 (13:17 +0200)]
xcbgen: fields get a parent reference

Objects of type Field get a reference to their parent.
This is needed in the generator to differentiate
field handling dependend on properties of their parent.

Message-ID: <1409743080-302-1-git-send-email-chris@demorecorder.com>
Patch-Thread-Subject: [Xcb] xinput: make ListInputDevices work, sumof with nested expr, ...
Patch-Set: ListInputDevices
Patch-Number: proto 1/7
Patch-Version: V1
Signed-off-by: Christian Linhart <chris@DemoRecorder.com>
9 years agoxinput: rep QueryDeviceState struct InputState: full support QueryDeviceState-V3 master
Christian Linhart [Fri, 29 Aug 2014 17:35:50 +0000 (19:35 +0200)]
xinput: rep QueryDeviceState struct InputState: full support

Full support for the QueryDeviceState reply.
This has been done by changing the struct InputState
with using switch-case and implicit-padding="false".

Also fixed the type of field valuators of struct ValuatorState
from CARD32 to INT32.

V2: patch revised:
* removed the implicit-padding="false" attribute, according
  to the discussion in this thread.
* give names to the cases, which generates more beautiful code.

spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt?id=inputproto-2.3.1#n2082
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml?id=libXi-1.7.4#n1728

Message-ID: <5400B9F6.5000208@DemoRecorder.com>
Patch-Thread-Subject: [Xcb] xinput:QueryDeviceState: full-support: generator and xml-changes
Patch-Set: QueryDeviceState
Patch-Number: proto 2/2
Patch-Version: V2
Signed-off-by: Christian Linhart <chris@DemoRecorder.com>
Reviewed-By: Ran Benita <ran234@gmail.com>
9 years agoschema: add switch-case
Christian Linhart [Mon, 25 Aug 2014 14:58:37 +0000 (16:58 +0200)]
schema: add switch-case

Reviewed-by: Peter Harris <pharris@opentext.com>
Reviewed-by: Ran Benita <ran234@gmail.com>
9 years agoxinput: req ChangeDeviceProperty: bitcase to case
Christian Linhart [Tue, 19 Aug 2014 13:55:34 +0000 (15:55 +0200)]
xinput: req ChangeDeviceProperty: bitcase to case

Change the bitcases to cases
and remove the comment which says that bitcases should converted to cases.

Reviewed-by: Peter Harris <pharris@opentext.com>
Reviewed-by: Ran Benita <ran234@gmail.com>
9 years agoxcbgen-parser: support switch-case
Christian Linhart [Tue, 19 Aug 2014 13:55:33 +0000 (15:55 +0200)]
xcbgen-parser: support switch-case

"case" is implemented as a variation of "bitcase" as follows:

The old class "BitCaseType" became the abstract class
"CaseOrBitcaseType" with two derived classes
"CaseType" and "BitcaseType".
(Therefore BitcaseType keeps the old semantic which may
be important for some generators)

There are two additional flags in class Type:
* is_case
* is_case_or_bitcase
The latter is for convenience because case and bitcase
have to be treated the same way in many cases.

The list of cases and bitcases in a SwitchType object
is still called "bitcases".
Reasons:
* Renaming that list would break generators based on the parser.
* Creating an extra list for cases would make other code more
  complicated because you usually want to iterate over all
  case and bitcase members of a switch.

Reviewed-by: Ran Benita <ran234@gmail.com>
9 years agoxml-xcb spec: describe switch-case
Christian Linhart [Wed, 20 Aug 2014 09:10:35 +0000 (11:10 +0200)]
xml-xcb spec: describe switch-case

V2: patch revised according to suggestion from Peter Harris:
* add the restriction that <enumref>
  inside <bitcase> can only refer to an enum's <bit> members, and
  <enumref> inside <case> can only refer to an enum's <value> members.

Reviewed-by: Peter Harris <pharris@opentext.com>
Reviewed-by: Ran Benita <ran234@gmail.com>
9 years agoMerge http://infra-srv1.demorecorder.com/git/free-sw/xcb/proto
Peter Harris [Mon, 25 Aug 2014 23:31:36 +0000 (19:31 -0400)]
Merge infra-srv1.demorecorder.com/git/free-sw/xcb/proto

See the mailing list for Reviewed-bys.

Thread root is
http://lists.freedesktop.org/archives/xcb/2014-August/009632.html

9 years agoAdd "altmask" attribute, like "altenum" for masks
Ran Benita [Mon, 25 Aug 2014 14:20:55 +0000 (17:20 +0300)]
Add "altmask" attribute, like "altenum" for masks

"altmask" means the field is principally a bitmask of bits from the
enum, but in some cases can obtain other values (e.g. "out-of-band" data
in a free bit).

Several fields in xinput will benefit from this extra metadata.

Suggested-by: Peter Harris <pharris@opentext.com>
Signed-off-by: Ran Benita <ran234@gmail.com>
Signed-off-by: Peter Harris <pharris@opentext.com>
9 years agoxinput: add TODO list
Christian Linhart [Fri, 22 Aug 2014 10:11:50 +0000 (12:11 +0200)]
xinput: add TODO list

Add TODO list of things which cannot be done yet
with the current feature-set of xml and the generator.

V2: Fix reference in the parametrized struct-paragraph:
to correctly refer to the GetDeviceMotionEvents-reply
(instead of the ChangeKeyboardDevice-request which
does not need parametrized structs.)

9 years agoxinput: replace initial pad of xinput1.x replies with field
Christian Linhart [Mon, 18 Aug 2014 14:41:22 +0000 (16:41 +0200)]
xinput: replace initial pad of xinput1.x replies with field

Replace the initial 1-byte pad of Xinput-1.x replies
with CARD8-field "xi_reply_type", according to XIproto.h.

This may also help to implement assertions
based on the value of that field.

reference:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XIproto.h#n187
http://cgit.freedesktop.org/xorg/xserver/tree/Xi/getvers.c#n103

9 years agoxinput: rep SetDeviceMode.status: altenum to enum
Christian Linhart [Mon, 18 Aug 2014 14:41:21 +0000 (16:41 +0200)]
xinput: rep SetDeviceMode.status: altenum to enum

Field "status" of the SetDeviceMode-reply
only allows values from enum GrabStatus.

Therefore it has an "enum" and not an "altenum".

Also: Add comment about valid values of field "status".

spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n601

note:
The following spec also mentions value "3 + first_error":
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n891

This is probably an error in this old spec because:
* the X-Server code does not generate that value.
  In case of error-codes, it does the following:
  instead of sending the reply it returns
  rep.status containing the error-code as returnvalue
  of the function ProcXSetDeviceMode.
  This will probably cause the sending of an XError.
  code:
    http://cgit.freedesktop.org/xorg/xserver/tree/Xi/setmode.c#n86

* the new spec does not mention that value:
  http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n601

9 years agoxinput: struct XIDeviceInfo.name: cleanup of padding
Christian Linhart [Mon, 18 Aug 2014 14:41:20 +0000 (16:41 +0200)]
xinput: struct XIDeviceInfo.name: cleanup of padding

Previuosly, the padding of list "name"
has been done by faking another list-length.

Correct this by using the real list-length,
and by adding a 4-byte align-pad after the list.

This yields the same total length of the struct,
and uses the correct length of the list "name".

spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XI2proto.txt#n768

code:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/src/XIQueryDevice.c#n92
http://cgit.freedesktop.org/xorg/xserver/tree/Xi/xiquerydevice.c#n477

9 years agoxinput: req XIPassiveGrabDevice.time: field is unused
Christian Linhart [Mon, 25 Aug 2014 10:08:57 +0000 (12:08 +0200)]
xinput: req XIPassiveGrabDevice.time: field is unused

The request-field "time" is unused.
Add a comment about this.

V2: patch revised according to the following fix in the spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/commit/?id=81378a1e7139af9d476d90df8737c0c1a58670f3

spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XI2proto.txt?id=81378a1e7139af9d476d90df8737c0c1a58670f3#n1699

code:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XI2proto.h?id=inputproto-2.3.1#n680

9 years agoxinput: ev BarrierHit.flags: add new mask
Christian Linhart [Mon, 18 Aug 2014 13:00:02 +0000 (15:00 +0200)]
xinput: ev BarrierHit.flags: add new mask

add new enum "BarrierFlags" as mask to field "flags"

spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XI2proto.txt#n2575
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XI2.h#n164

9 years agoxinput: ev DeviceStateNotify.classes_reported: mask
Christian Linhart [Sat, 23 Aug 2014 11:05:43 +0000 (13:05 +0200)]
xinput: ev DeviceStateNotify.classes_reported: mask

add new enum "ClassesReportedMask" as mask to field "classes_reported"

V2: patch revised according to suggestion from Peter Harris:
* use names which indicate the way the bits should be flipped

V3: revised the diff-context according to the modification of patch 18/22 V2

spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n2401
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n2220

9 years agoxinput: ev DeviceButtonStateNotify.device_id: mask
Christian Linhart [Fri, 22 Aug 2014 15:26:10 +0000 (17:26 +0200)]
xinput: ev DeviceButtonStateNotify.device_id: mask

add mask "MoreEventsMask" to field "device_id"

V2: patch revised according to suggestion from Peter Harris:
* use "altmask" instead of "mask"
  because all the legal values of device_id are not described
  by the <bit> elements of MoreEventsMask.

V3: revised the diff-context according to the modification of patch 19/22 V2.

spec:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n2252
http://cgit.freedesktop.org/xorg/xserver/tree/dix/enterleave.c#n725

note:
this mask is missing in the following spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n2431

9 years agoxinput: ev DeviceKeyStateNotify.device_id: mask
Christian Linhart [Tue, 19 Aug 2014 11:13:54 +0000 (13:13 +0200)]
xinput: ev DeviceKeyStateNotify.device_id: mask

add mask "MoreEventsMask" to field "device_id"

V2: patch revised according to suggestion from Peter Harris:
* use "altmask" instead of "mask"
  because all the legal values of device_id are not described
  by the <bit> elements of MoreEventsMask.

spec:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n2239
http://cgit.freedesktop.org/xorg/xserver/tree/dix/enterleave.c#n745

note:
this mask is missing in the following spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n2428

9 years agoxinput: ev DeviceStateNotify.device_id: mask
Christian Linhart [Tue, 19 Aug 2014 11:13:43 +0000 (13:13 +0200)]
xinput: ev DeviceStateNotify.device_id: mask

add mask "MoreEventsMask" to field "device_id"

V2: patch revised according to suggestion from Peter Harris:
* use "altmask" instead of "mask"
  because all the legal values of device_id are not described
  by the <bit> elements of MoreEventsMask.

spec and code:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n2214
http://cgit.freedesktop.org/xorg/xserver/tree/dix/enterleave.c#n725

note:
this mask is missing in the following spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n2395

9 years agoxinput: ev DeviceKeyPress.device_id: add mask
Christian Linhart [Tue, 19 Aug 2014 11:13:24 +0000 (13:13 +0200)]
xinput: ev DeviceKeyPress.device_id: add mask

for event DeviceKeyPress and derived ones:
add new mask "MoreEventsMask" to field "device_id"

V2: patch revised according to suggestion from Peter Harris:
* use "altmask" instead of "mask"
  because all the legal values of device_id are not described
  by the <bit> elements of MoreEventsMask.

spec and code:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1999
http://cgit.freedesktop.org/xorg/lib/libXi/tree/src/XExtInt.c#n534
http://cgit.freedesktop.org/xorg/xserver/tree/dix/eventconvert.c#n348
http://cgit.freedesktop.org/xorg/xserver/tree/Xi/exevents.c#n188

note:
this mask is missing in the following spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n2257

9 years agoxinput: new enum for device_id in some events
Christian Linhart [Tue, 19 Aug 2014 11:13:06 +0000 (13:13 +0200)]
xinput: new enum for device_id in some events

add new enum "MoreEventsMask" to be used
by event DeviceKeyPress and derived ones
for field "device_id".

V2: patch revised according to suggestion from Peter Harris:
* remove DeviceBits = 0x7f from the enum in order to avoid
  mixing bit and value in the same enum.
  ( We'd need a way to specify a range of bits for that ... )

spec and code:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1999
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XIproto.h#n67
http://cgit.freedesktop.org/xorg/lib/libXi/tree/src/XExtInt.c#n534
http://cgit.freedesktop.org/xorg/xserver/tree/dix/eventconvert.c#n348
http://cgit.freedesktop.org/xorg/xserver/tree/Xi/exevents.c#n188

note:
this mask is missing in the following spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n2257

9 years agoxinput: ev ChangeDeviceNotify.request: add enum
Christian Linhart [Mon, 18 Aug 2014 12:59:55 +0000 (14:59 +0200)]
xinput: ev ChangeDeviceNotify.request: add enum

add new enum "ChangeDevice" for field "request"

spec:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n2301
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n2459

9 years agoxinput: ev DeviceMappingNotify.request: add enum
Christian Linhart [Mon, 18 Aug 2014 12:59:54 +0000 (14:59 +0200)]
xinput: ev DeviceMappingNotify.request: add enum

add enum "Mapping" for field "request"

spec:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n2281
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n2443

def of enum "Mapping":
http://cgit.freedesktop.org/xcb/proto/tree/src/xproto.xml#n1058

9 years agoxinput: ev DeviceKeyPress.state: add mask
Christian Linhart [Mon, 18 Aug 2014 12:59:53 +0000 (14:59 +0200)]
xinput: ev DeviceKeyPress.state: add mask

add mask KeyButMask to field "state"

spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n2271

9 years agoxinput: struct XIDeviceInfo.type: altenum to enum
Christian Linhart [Mon, 18 Aug 2014 12:59:52 +0000 (14:59 +0200)]
xinput: struct XIDeviceInfo.type: altenum to enum

field "type": replace altenum by enum because
only the values of DeviceType are permitted

spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XI2proto.txt#n669
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XI2proto.txt#n763

notes to the spec:
* the field is called "use" in the spec, instead of "type"
* the enum is called "DEVICEUSE" in the spec, instead of "DeviceType"

9 years agoxinput: struct ScrollClass.flags: has a mask
Christian Linhart [Mon, 18 Aug 2014 12:59:51 +0000 (14:59 +0200)]
xinput: struct ScrollClass.flags: has a mask

the field "flags" of struct ScrollClass uses ScrollFlags as a mask

spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XI2proto.txt#n802
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XI2.h#n151

9 years agoxinput: req ChangeFeedbackControl.mask: add mask
Christian Linhart [Thu, 21 Aug 2014 20:50:52 +0000 (22:50 +0200)]
xinput: req ChangeFeedbackControl.mask: add mask

add new enum ChangeFeedbackControlMask to field "mask" as mask

V2: patch revised according to suggestion from Ran Benita:
* changed item name from "ledMode" to "LedMode" ( initial character uppercase )
  to be consistent with the initial uppercase letter of the other items.

V2: added a note to the commit-message
    about multiple items with the same value.

Note:
This enum contains multiple items with the same value.
This is defined that way in the spec.
The reason is probably as follows:
The semantic of those values probably depends on the
the value of field "class_id" of struct "FeedbackCtrl".

spec and code:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1450
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XI.h#n207
http://cgit.freedesktop.org/xorg/xserver/tree/Xi/chgfctl.c

the following spec just mentions that the field "mask" is a BITMASK,
but does not list its values:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n1725

9 years agoxinput: struct ValuatorState.mode: add mask
Christian Linhart [Tue, 19 Aug 2014 11:12:32 +0000 (13:12 +0200)]
xinput: struct ValuatorState.mode: add mask

add new enum ValuatorStateModeMask as mask to field "mode"

V2: patch revised according to suggestions from Peter Harris:
* use bit instead of value
* use names which indicate the way the bits should be flipped

spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n2095
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1783

9 years agoxinput: req UngrabDeviceButton.modifier_device: altenum
Christian Linhart [Mon, 18 Aug 2014 12:59:48 +0000 (14:59 +0200)]
xinput: req UngrabDeviceButton.modifier_device: altenum

add altenum ModifierDevice to field modifier_device for value UseXKeyboard

spec and code:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1225
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XI.h#n187
http://cgit.freedesktop.org/xorg/xserver/tree/Xi/ungrdevb.c#n111

the following spec uses "NULL" instead of "UseXKeyboard":
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n1386
Questions:
* is this spec wrong?
* or does "NULL" have the unusual value of 0xff in this context?

9 years agoxinput: req GrabDeviceButton.modifier_device: altenum
Christian Linhart [Mon, 18 Aug 2014 12:59:47 +0000 (14:59 +0200)]
xinput: req GrabDeviceButton.modifier_device: altenum

add altenum ModifierDevice to field modifier_device for value UseXKeyboard

spec and code:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1195
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XI.h#n187
http://cgit.freedesktop.org/xorg/xserver/tree/Xi/grabdevb.c#n118

the following spec uses "NULL" instead of "UseXKeyboard":
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n1309
Questions:
* is this spec wrong?
* or does "NULL" have the unusual value of 0xff in this context?

9 years agoxinput: req UngrabDeviceKey.modifier_device: altenum
Christian Linhart [Mon, 18 Aug 2014 12:59:46 +0000 (14:59 +0200)]
xinput: req UngrabDeviceKey.modifier_device: altenum

add altenum ModifierDevice to field modifier_device for value UseXKeyboard

spec and code:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1175
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XI.h#n187
http://cgit.freedesktop.org/xorg/xserver/tree/Xi/ungrdevk.c#n113

the following spec uses "NULL" instead of "UseXKeyboard":
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n1295
Questions:
* is this spec wrong?
* or does "NULL" have the unusual value of 0xff in this context?

9 years agoxinput: req GrabDeviceKey.modifier_device: altenum
Christian Linhart [Fri, 22 Aug 2014 15:15:24 +0000 (17:15 +0200)]
xinput: req GrabDeviceKey.modifier_device: altenum

add altenum ModifierDevice to field modifier_device for value UseXKeyboard

V2: patch revised according to info from Ran Benita about NULL and UseXKeyboard

spec and code:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1147
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XI.h#n187
http://cgit.freedesktop.org/xorg/xserver/tree/Xi/grabdevk.c#n116

the following spec uses "NULL" instead of "UseXKeyboard":
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n1213

The reason for NULL vs UseXKeyboard is: in the libXi function XUngrabDeviceKey,
the modifier_device arg is an XDevice pointer, and NULL means to use the
core X keyboard. But on the wire it is an integer, with 255 as a special
value.

9 years agoxinput: add new enum ModifierDevice
Christian Linhart [Mon, 18 Aug 2014 12:59:44 +0000 (14:59 +0200)]
xinput: add new enum ModifierDevice

needed for field "modifier_device" in the following requests:
* GrabDeviceKey
* UngrabDeviceKey
* GrabDeviceButton
* UngrabDeviceButton

spec:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1147
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XI.h#n187

9 years agoxinput: rep ChangePointerDevice.status: altenum to enum
Christian Linhart [Mon, 18 Aug 2014 12:59:43 +0000 (14:59 +0200)]
xinput: rep ChangePointerDevice.status: altenum to enum

Field "status" can only get values from enum GrabStatus.
Therefore make it an enum instead of altenum.

spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n1055

Add comments:
Add comment about valid values for field "status".

Note:
An old spec lists value 2 for enum value "Frozen"
while enum GrabStatus has value 4 for Frozen.
The old spec is probably wrong.
Here is the URL of the old spec:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1073

9 years agoxinput: rep ChangeKeyboardDevice.status: altenum to enum
Christian Linhart [Mon, 18 Aug 2014 12:59:42 +0000 (14:59 +0200)]
xinput: rep ChangeKeyboardDevice.status: altenum to enum

Field "status" can only get values from enum GrabStatus
therefore make it an enum instead of altenum.

spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n1016

Add comment about valid values for field status.

Note:
An old spec lists value 2 for enum value "Frozen"
while enum GrabStatus has value 4 for Frozen.
The old spec is probably wrong.
Here is the URL of the old spec:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1044

9 years agoxinput: enum InputClass: comment value Attach 7
Christian Linhart [Mon, 18 Aug 2014 12:59:41 +0000 (14:59 +0200)]
xinput: enum InputClass: comment value Attach 7

The value Attach=7 is defined in XI.h but not supported anymore by libXi.
And it never was transmitted over the protocol.
(It was used to tag a fake class created by libXi)

Add this comment so that future reviews will not accidentally add this value.

spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XI.h#n242

drop of support in libXi:
http://cgit.freedesktop.org/xorg/lib/libXi/commit/?id=62858c426e6de1b99df660251737233afd335302

9 years agoxinput: event Enter: fix type of fields same_screen and focus
Christian Linhart [Sat, 16 Aug 2014 10:08:28 +0000 (12:08 +0200)]
xinput: event Enter: fix type of fields same_screen and focus

fix type of fields "same_screen" and  "focus" from CARD8 to BOOL

spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XI2proto.txt#n2432
(file-position in the above URL may become wrong if the spec changes)

9 years agoxinput: request GrabDeviceButton: fix type of field owner_events
Christian Linhart [Sat, 16 Aug 2014 10:08:27 +0000 (12:08 +0200)]
xinput: request GrabDeviceButton: fix type of field owner_events

change type of field "owner_events" from CARD8 to BOOL

spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n1311
(file-position in the above URL may become wrong if the spec changes)

9 years agoxinput: struct AddMaster: fix type of fields
Christian Linhart [Sat, 16 Aug 2014 10:08:26 +0000 (12:08 +0200)]
xinput: struct AddMaster: fix type of fields

fix type of fields "send_core" and "enable" to BOOL

spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XI2proto.txt#n1187

note:
the type of these fields should also be fixed in XI2proto.h:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XI2proto.h#n460

(file-positions in the above URLs may become wrong if the spec changes)

9 years agoxinput: reply XIQueryPointer: fix type of field same_screen
Christian Linhart [Sat, 16 Aug 2014 10:08:25 +0000 (12:08 +0200)]
xinput: reply XIQueryPointer: fix type of field same_screen

fix type of field "same_screen" from CARD8 to BOOL

spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XI2proto.txt#n1054

note:
the type of this field should also be fixed in XI2proto.h:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XI2proto.h#n386

(file-positions in the above URLs may become wrong if the spec or header changes)

9 years agoxinput: struct DeviceTimeCoord: replace CARD32 by INT32
Christian Linhart [Sat, 16 Aug 2014 10:08:24 +0000 (12:08 +0200)]
xinput: struct DeviceTimeCoord: replace CARD32 by INT32

replace CARD32 by INT32 in commented-out list "axisvalues"

spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n927
in this spec, the list is called "data" instead of "axisvalues"

http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1018
in this spec, the list is called "valuators" instead of "axisvalues"

(file-positions in the above URLs may become wrong if the spec changes)

9 years agoxinput: GetDeviceMotionEvents-request: add pad at end
Christian Linhart [Fri, 15 Aug 2014 18:36:20 +0000 (20:36 +0200)]
xinput: GetDeviceMotionEvents-request: add pad at end

see:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n992
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XIproto.h#n474
(file-positions may become wrong if the spec or header change)

9 years agoxinput: XIGetProperty-reply: add align-pad at end
Christian Linhart [Fri, 15 Aug 2014 18:36:19 +0000 (20:36 +0200)]
xinput: XIGetProperty-reply: add align-pad at end

reasons:
* all X11-replies must have a length which is a multiple of 4 bytes
* bitcases "8Bits" and "16bits" may have a length
  which is not a multiple of 4 bytes
  but they start on a 4-byte aligned position.
  Therefore the unpadded end of the request may not be 4-byte aligned
* Therefore this requires a 4-byte align-pad.

notes:
* The align pad had to be added in each relevant bitcase
  because adding it after the switch would cause the generator
  to abort. (which is OK because a <switch> has to be the last item
  of a struct, request or reply, according to the xcb-xml-spec)

9 years agoxinput: struct AddMaster: add align-pad at end
Christian Linhart [Fri, 15 Aug 2014 18:36:18 +0000 (20:36 +0200)]
xinput: struct AddMaster: add align-pad at end

reasons:
* length of the struct is a multiple of 4 according to spec.
* list of char may not end at a 4-byte aligned position.

see:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XI2proto.txt#n1224
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XI2proto.h#n454
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XI2proto.h#n458
(file-positions may become wrong if the spec or header change)

9 years agoxinput: ChangeDeviceProperty-request: add align-pad at end
Christian Linhart [Fri, 15 Aug 2014 18:36:17 +0000 (20:36 +0200)]
xinput: ChangeDeviceProperty-request: add align-pad at end

reasons:
* all X11-requests must have a length which is a multiple of 4 bytes
* bitcases "8Bits" and "16bits" may have a length
  which is not a multiple of 4-bytes
  but they start on a 4-byte aligned position.
  Therefore the unpadded end of the request may not be 4-byte aligned
* Therefore this requires a 4-byte align-pad.

notes:
* The align pad had to be added in each relevant bitcase
  because adding it after the switch would cause the generator
  to abort. (which is OK because a <switch> has to be the last item
  of a struct, request or reply, according to the xcb-xml-spec)

9 years agoxinput: GetDeviceProperty-reply: add align-pad at end
Christian Linhart [Fri, 15 Aug 2014 18:36:16 +0000 (20:36 +0200)]
xinput: GetDeviceProperty-reply: add align-pad at end

reasons:
* all X11-replies must have a length which is a multiple of 4 bytes
* bitcases "8Bits" and "16bits" may have a length
  which is not a multiple of 4-bytes
  but they start on a 4-byte aligned position.
  Therefore the unpadded end of the request may not be 4-byte aligned
* Therefore this requires a 4-byte align-pad.

notes:
* The align pad had to be added in each relevant bitcase
  because adding it after the switch would cause the generator
  to abort. (which is OK because a <switch> has to be the last item
  of a struct, request or reply, according to the xcb-xml-spec)

9 years agoxinput: GetDeviceButtonMapping-reply: add align-pad at end
Christian Linhart [Fri, 15 Aug 2014 18:36:15 +0000 (20:36 +0200)]
xinput: GetDeviceButtonMapping-reply: add align-pad at end

see:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1691
(file-position may become wrong if the spec changes)

9 years agoxinput: GetDeviceKeyMapping-request: add pad at end
Christian Linhart [Fri, 15 Aug 2014 18:36:14 +0000 (20:36 +0200)]
xinput: GetDeviceKeyMapping-request: add pad at end

see:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1583
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XIproto.h#n982
(file-positions may become wrong if the spec or header change)

9 years agoxinput: SetDeviceFocus-request: add pad at end
Christian Linhart [Fri, 15 Aug 2014 18:36:13 +0000 (20:36 +0200)]
xinput: SetDeviceFocus-request: add pad at end

see:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1308
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XIproto.h#n737
(file-positions may become wrong if the spec or header change)

9 years agoxinput: AllowDeviceEvents-request: add pad at end
Christian Linhart [Fri, 15 Aug 2014 18:36:12 +0000 (20:36 +0200)]
xinput: AllowDeviceEvents-request: add pad at end

see:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1251
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XIproto.h#n692
(file-positions may become wrong if the spec or header change)

9 years agoxinput: UngrabDeviceButton-request: add pad at end
Christian Linhart [Fri, 15 Aug 2014 18:36:11 +0000 (20:36 +0200)]
xinput: UngrabDeviceButton-request: add pad at end

see:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1229
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XIproto.h#n676
(file-positions may become wrong if the spec or header change)

9 years agoxinput: UngrabDevice-request: add pad at end
Christian Linhart [Fri, 15 Aug 2014 18:36:10 +0000 (20:36 +0200)]
xinput: UngrabDevice-request: add pad at end

see:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1130
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XIproto.h#n596
(file-positions may become wrong if the spec or header change)

9 years agoxinput: OpenDevice-reply: add align-pad at end
Christian Linhart [Fri, 15 Aug 2014 18:36:09 +0000 (20:36 +0200)]
xinput: OpenDevice-reply: add align-pad at end

see:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n834
(file-position may become wrong if the spec changes)

9 years agoxinput: SetDeviceModifierMapping: fix length of pad
Christian Linhart [Wed, 13 Aug 2014 13:40:07 +0000 (15:40 +0200)]
xinput: SetDeviceModifierMapping: fix length of pad

fix length of pad from 1 to 2 bytes after request-field keycodes_per_modifier

see XIproto.h:1057 in inputproto-2.3.1
see spec in libXi-1.7.4 ( in docbook format in the directory "specs" )

Reviewed-by: Peter Harris <pharris@opentext.com>
Reviewed-by: Ran Benita <ran234@gmail.com>
9 years agoxinput: ChangeFeedbackControl: add missing pad
Christian Linhart [Wed, 13 Aug 2014 13:39:14 +0000 (15:39 +0200)]
xinput: ChangeFeedbackControl: add missing pad

add missing pad after field "feedback_id"

see XIproto.h:875 in inputproto-2.3.1
see spec in libXi-1.7.4 ( in docbook format in the directory "specs" )

Reviewed-by: Peter Harris <pharris@opentext.com>
Reviewed-by: Ran Benita <ran234@gmail.com>
9 years agoRelease xcb-proto 1.11
Uli Schlachter [Fri, 1 Aug 2014 13:43:15 +0000 (15:43 +0200)]
Release xcb-proto 1.11

9 years agoxkb: Add missing modLatches as comment to LatchLockState
Daniel Martin [Tue, 15 Jul 2014 16:53:17 +0000 (18:53 +0200)]
xkb: Add missing modLatches as comment to LatchLockState

The field modLatches was missing in the request LatchLockState:
    http://cgit.freedesktop.org/xorg/proto/kbproto/tree/XKBproto.h#n141

v2: Use a pad instead of a field, as the field would cause an API break.
    Though, keep the field commented out to document it.

Signed-off-by: Daniel Martin <consume.noise@gmail.com>
Reviewed-by: Ran Benita <ran234@gmail.com>
9 years agoxinput: Add missing pad in XIChangeHierarchy
Daniel Martin [Thu, 17 Jul 2014 20:49:12 +0000 (22:49 +0200)]
xinput: Add missing pad in XIChangeHierarchy

A pad of 3 bytes was missing in the request XIChangeHierarchy:
    http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XI2proto.h#n439

Signed-off-by: Daniel Martin <consume.noise@gmail.com>
Reviewed-by: Peter Harris <pharris@opentext.com>
9 years agoxinput: Add missing pad in DeviceResolutionCtl
Daniel Martin [Thu, 17 Jul 2014 20:49:11 +0000 (22:49 +0200)]
xinput: Add missing pad in DeviceResolutionCtl

A pad of 2 bytes was missing in the struct DeviceResolutionCtl:
    http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XIproto.h#n1382

Signed-off-by: Daniel Martin <consume.noise@gmail.com>
Reviewed-by: Peter Harris <pharris@opentext.com>
9 years agoAdd <fd> to xml-xcb.txt
Ran Benita [Wed, 27 Nov 2013 23:52:13 +0000 (01:52 +0200)]
Add <fd> to xml-xcb.txt

Signed-off-by: Ran Benita <ran234@gmail.com>
Reviewed-by: Daniel Martin <consume.noise@gmail.com>
9 years agoschema: Restricted enum item values
Daniel Martin [Fri, 22 Nov 2013 22:26:54 +0000 (23:26 +0100)]
schema: Restricted enum item values

Restrict decimal values by using an xsd:unsignedInt instead of an
xsd:integer. xsd:unsignedInt is an unsigned 32-bit integer.
And restrict bit values by adding a type, which allows values within the
range of [0, 32) only.

Signed-off-by: Daniel Martin <consume.noise@gmail.com>
9 years agoschema: Remove dec-or-hex-integer and hex-integer type
Daniel Martin [Fri, 22 Nov 2013 22:26:53 +0000 (23:26 +0100)]
schema: Remove dec-or-hex-integer and hex-integer type

Reflect in the schema that hexadecimal values aren't supported in enum
items (and expressions) by removing the 'dec-or-hex-integer' and
'hex-integer' type.

Hexadecimal values are not supported "as some languages have a different
notation for hex-values" and therefor such hexadecimal values have been
explicitly replaced with decimal values in other commits, see:

    183ecff Replaced hex-values with decimal ones
    8b3c120 did remaining replacements of hex constants with decimal

Signed-off-by: Daniel Martin <consume.noise@gmail.com>
9 years agoschema: Add attribute 'name' to <fd>
Daniel Martin [Fri, 22 Nov 2013 22:26:52 +0000 (23:26 +0100)]
schema: Add attribute 'name' to <fd>

Do not allow any other attribute and make sure the attribute 'name' is
set in an fd element by adding and declaring it as required in the
schema.

Signed-off-by: Daniel Martin <consume.noise@gmail.com>
9 years agoschema: Set default attribute values
Daniel Martin [Fri, 22 Nov 2013 22:26:51 +0000 (23:26 +0100)]
schema: Set default attribute values

Set the default values for the attributes combine-adjacent,
no-sequence-number and xge to false.

Signed-off-by: Daniel Martin <consume.noise@gmail.com>
9 years agoxproto: Fix EnterNotify documentation
Daniel Martin [Fri, 22 Nov 2013 22:26:50 +0000 (23:26 +0100)]
xproto: Fix EnterNotify documentation

Fix a copy'n'paste mistake (from UnmapNotify) in the documentation of
EnterNotify by changing the description for 'event', renaming
'window' to 'child' and change its description too.

Signed-off-by: Daniel Martin <consume.noise@gmail.com>
9 years agoxv: Add align. pad in struct AdaptorInfo
Daniel Martin [Mon, 9 Jun 2014 15:55:05 +0000 (17:55 +0200)]
xv: Add align. pad in struct AdaptorInfo

The (list) 'name' in the struct AdaptorInfo is not padded. Therefore
we've to add an alignment pad after it.

Reference: http://cgit.freedesktop.org/xorg/lib/libXv/tree/src/Xv.c#n250
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=79808

Signed-off-by: Daniel Martin <consume.noise@gmail.com>
Signed-off-by: Peter Harris <pharris@opentext.com>
9 years agodri2: Add notes on lists that should be linked to their length fields but are not.
Robert Ancell [Fri, 30 May 2014 07:37:14 +0000 (09:37 +0200)]
dri2: Add notes on lists that should be linked to their length fields but are not.

Reviewed-by: Daniel Martin <consume.noise@gmail.com>
10 years agoxkb: Fix use of nKTLevels
Peter Harris [Tue, 29 Apr 2014 15:52:36 +0000 (11:52 -0400)]
xkb: Fix use of nKTLevels

nLevelsPerType is nLevels long. This continues the work started in
76ca2c0b1527541be59c344118c538ba055ad9d8.

nKTLevels could be used instead of <sumof nLevelsPerType>, but that
change causes a change to libxcb's API.

Reviewed-by: Ran Benita <ran234@gmail.com>
Tested-by: Ran Benita <ran234@gmail.com>
Signed-off-by: Peter Harris <pharris@opentext.com>
10 years agoxprint: Fix <field type="STRING8"> in PrintGetAttributes reply
Vincent W. Chen [Thu, 10 Apr 2014 01:48:56 +0000 (18:48 -0700)]
xprint: Fix <field type="STRING8"> in PrintGetAttributes reply

The reply for PrintGetAttributes contains a field of type STRING8, which
makes no sense as the STRING8 type is only used to denote a string. This
has been changed to <list type="STRING8"> with field "stringLen" as its
length.

Reviewed-by: Peter Harris <pharris@opentext.com>
10 years agoRemove extraneous spaces between <value> tags
Vincent W. Chen [Thu, 10 Apr 2014 01:34:31 +0000 (18:34 -0700)]
Remove extraneous spaces between <value> tags

These are the only places where spaces are allowed between <value> tags.
This is not only inconsistent but also complicates the parsing of values
as integers.

Signed-off-by: Uli Schlachter <psychon@znc.in>
10 years agoAlso track directly imported modules in a separate list
Keith Packard [Wed, 12 Feb 2014 21:53:13 +0000 (13:53 -0800)]
Also track directly imported modules in a separate list

This allows the generated header files to only include the
directly referenced header files, with the indirectly referenced header
files included by the directly referenced ones.

Signed-off-by: Keith Packard <keithp@keithp.com>
Signed-off-by: Uli Schlachter <psychon@znc.in>
10 years agoxkb: Use <pad align="4" /> in GetMap
Peter Harris [Tue, 14 Jan 2014 19:48:22 +0000 (14:48 -0500)]
xkb: Use <pad align="4" /> in GetMap

There is a bug where lists of size other than one are automatically
aligned by c_client.py. So alignment_pad3 and 4 were aligning twice
and consuming too many bytes.

Rather than change the type to CARD8 and wrap the <op> in yet another
<op> to multiply by two, use the new <pad align> operation.

Reviewed-By: Ran Benita <ran234@gmail.com>
Tested-By: Ran Benita <ran234@gmail.com>
Signed-off-by: Peter Harris <pharris@opentext.com>
10 years agoSupport <pad align="n" />
Peter Harris [Tue, 14 Jan 2014 19:45:36 +0000 (14:45 -0500)]
Support <pad align="n" />

Reviewed-By: Ran Benita <ran234@gmail.com>
Signed-off-by: Peter Harris <pharris@opentext.com>
10 years agoTrack pad count at the module level
Peter Harris [Tue, 14 Jan 2014 19:45:15 +0000 (14:45 -0500)]
Track pad count at the module level

If the pad count is reset for each bitcase, the names will collide
in the encompasing switch struct.

Reviewed-By: Ran Benita <ran234@gmail.com>
Signed-off-by: Peter Harris <pharris@opentext.com>
10 years agoRelease xcb-proto 1.10
Uli Schlachter [Sun, 22 Dec 2013 14:57:36 +0000 (15:57 +0100)]
Release xcb-proto 1.10

Signed-off-by: Uli Schlachter <psychon@znc.in>
10 years agoAdd news for 1.10
Julien Cristau [Sat, 14 Dec 2013 05:25:12 +0000 (06:25 +0100)]
Add news for 1.10

Signed-off-by: Julien Cristau <jcristau@debian.org>
10 years agoxinput: Explicitly specify NotifyMode and NotifyDetail
Peter Harris [Fri, 6 Dec 2013 21:17:37 +0000 (16:17 -0500)]
xinput: Explicitly specify NotifyMode and NotifyDetail

There is a NotifyMode and a NotifyDetail in both xproto and xinput.  Add
a namespece to the enum references to be clear about which one is to be
used.

Signed-off-by: Peter Harris <pharris@opentext.com>
Signed-off-by: Julien Cristau <jcristau@debian.org>
10 years agoAdd NEWS entries for release 1.9
Uli Schlachter [Fri, 15 Nov 2013 21:24:35 +0000 (22:24 +0100)]
Add NEWS entries for release 1.9

Signed-off-by: Uli Schlachter <psychon@znc.in>
Signed-off-by: Julien Cristau <jcristau@debian.org>
10 years agoRename ge events to GeGeneric events
Uli Schlachter [Mon, 18 Nov 2013 19:38:43 +0000 (20:38 +0100)]
Rename ge events to GeGeneric events

The new xcb_ge_event_t that libxcb generates from this definition has different
fields than the old, hand-written xcb_ge_event_t. To undo an API break, libxcb
will reintroduce the old hand-written version and mark it as deprecated, so that
everyone can switch to this new version.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=71502
Signed-off-by: Uli Schlachter <psychon@znc.in>
Signed-off-by: Julien Cristau <jcristau@debian.org>
10 years agosync: VALUETYPE and TESTTYPE are enum
Peter Harris [Fri, 15 Nov 2013 22:22:02 +0000 (17:22 -0500)]
sync: VALUETYPE and TESTTYPE are enum

Typoed as mask in e6a246e50e62cbcba33d0e1d2371e69e6e089383

Signed-off-by: Peter Harris <pharris@opentext.com>
Reviewed-By: Daniel Martin <consume.noise@gmail.com>
10 years agosync: Add missing namespace for the INT64 struct
Peter Harris [Fri, 15 Nov 2013 16:07:39 +0000 (11:07 -0500)]
sync: Add missing namespace for the INT64 struct

Signed-off-by: Peter Harris <pharris@opentext.com>
Reviewed-By: Daniel Martin <consume.noise@gmail.com>
10 years agoPresent: Remove reference to nonexistent enum
Peter Harris [Wed, 13 Nov 2013 21:21:22 +0000 (16:21 -0500)]
Present: Remove reference to nonexistent enum

Signed-off-by: Peter Harris <pharris@opentext.com>
Reviewed-by: Uli Schlachter <psychon@znc.in>
10 years agoxkb: Add struct Property as per spec (commented out)
Ran Benita [Sun, 13 Oct 2013 11:44:41 +0000 (13:44 +0200)]
xkb: Add struct Property as per spec (commented out)

The specification says that Property is a struct of two CountedString16
(name and value). This form can't be handled atm. correctly too. But,
add it as a comment so we've it at hand when we know what to do with it.

All credits go to Ran Benita, as he found this.

Signed-off-by: Daniel Martin <consume.noise@gmail.com>
10 years agoxkb: Comment out intermixed fixed size fields and lists
Daniel Martin [Sun, 13 Oct 2013 11:44:40 +0000 (13:44 +0200)]
xkb: Comment out intermixed fixed size fields and lists

c_client.py doesn't handle such intermixed fixed size fields and lists
correctly. Therefor comment them out.

With that change the size of the generated request structure for
ListComponents has 8 Bytes which is the same as xkbListComponentsReq
has and the server checks REQUEST_AT_LEAST_SIZE(xkbListComponentsReq).
The same goes for GetKbdByName, which results in a structure of 12
Bytes.

Signed-off-by: Daniel Martin <consume.noise@gmail.com>
Reviewed-By: Ran Benita <ran234@gmail.com>
10 years agoxkb: Comment out the struct Property and {Get, Set}Geometry
Daniel Martin [Sun, 13 Oct 2013 11:44:39 +0000 (13:44 +0200)]
xkb: Comment out the struct Property and {Get, Set}Geometry

This struct has intermixed fixed size fields and lists, which
c_client.py doesn't handle properly. Therefor comment out the struct and
the fields type-referencing it.

As doodads are commented out already and with Property gone the requests
GetGeomtry and SetGeometry become pretty much useless. Therefor comment
them out completly.

Signed-off-by: Daniel Martin <consume.noise@gmail.com>
Reviewed-By: Ran Benita <ran234@gmail.com>
10 years agoxkb: Comment out Doodads
Daniel Martin [Sun, 13 Oct 2013 11:44:38 +0000 (13:44 +0200)]
xkb: Comment out Doodads

Doodads are known to be broken (*). Comment them out until they can be
handled properly.

(*) One problem is that TextDoodad and LogoDoodad have variadic lists at
the end. But, they're within a union with other fixed size Doodads. A
union doesn't have a hint which field is in use and therefor the code
generator (at least c_client.py) just creates a generic iterator for the
Doodad union, which fails for TextDoodad and LogoDoodad.

Signed-off-by: Daniel Martin <consume.noise@gmail.com>
Reviewed-By: Ran Benita <ran234@gmail.com>
10 years agoAdd note on pretty patches and src/.gitattributes
Daniel Martin [Sun, 13 Oct 2013 11:44:37 +0000 (13:44 +0200)]
Add note on pretty patches and src/.gitattributes

Add a file HACKING describing howto to prettify patches (their hunk
headers) and add src/.gitattributes, which is necessary for that.

Signed-off-by: Daniel Martin <consume.noise@gmail.com>
Reviewed-By: Ran Benita <ran234@gmail.com>
10 years agoxv: Remove obsolete comments in EncodingInfo and QueryEncodings
Daniel Martin [Sun, 13 Oct 2013 11:44:36 +0000 (13:44 +0200)]
xv: Remove obsolete comments in EncodingInfo and QueryEncodings

The padding in EncodingInfo (struct) and QueryEncodings (reply) has been
fixed upstream:
    Xvproto: fix xvEncodingInfo to match actual wire protocol
    http://cgit.freedesktop.org/xorg/proto/videoproto/commit/?id=d970512
and
    Xvproto.h: fix xvQueryEncodingsReply to match actual wire protocol
    http://cgit.freedesktop.org/xorg/proto/videoproto/commit/?id=1a96222

So, we can remove the comments.

Signed-off-by: Daniel Martin <consume.noise@gmail.com>
Reviewed-by: Arnaud Fontaine <arnau@debian.org>
10 years agoxinput: Add XI2 event enum. for event selection
Daniel Martin [Sun, 13 Oct 2013 11:44:35 +0000 (13:44 +0200)]
xinput: Add XI2 event enum. for event selection

This adds an enumeration 'XIEventMask', which is necessary to select for
XI2 events via the SelectEvent request.

Signed-off-by: Daniel Martin <consume.noise@gmail.com>
Reviewed-By: Ran Benita <ran234@gmail.com>
10 years agoxcbgen: Remove tab from xtypes.py.
Matt Turner [Tue, 12 Nov 2013 02:32:09 +0000 (18:32 -0800)]
xcbgen: Remove tab from xtypes.py.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=71418

10 years agoUpdate to version 1.9
Keith Packard [Thu, 7 Nov 2013 21:51:09 +0000 (13:51 -0800)]
Update to version 1.9

Signed-off-by: Keith Packard <keithp@keithp.com>
10 years agoAdd 'fd' element to fields group, fix present Generic event to validate
Keith Packard [Thu, 7 Nov 2013 21:29:14 +0000 (13:29 -0800)]
Add 'fd' element to fields group, fix present Generic event to validate

This fixes 'make check'

Signed-off-by: Keith Packard <keithp@keithp.com>
10 years agoAdd Present protocol specification
Keith Packard [Thu, 11 Jul 2013 22:59:08 +0000 (15:59 -0700)]
Add Present protocol specification

Signed-off-by: Keith Packard <keithp@keithp.com>
Reviewed-by: Peter Harris <pharris@opentext.com>
10 years agoAdd DRI3
Keith Packard [Wed, 10 Apr 2013 04:36:40 +0000 (21:36 -0700)]
Add DRI3

Signed-off-by: Keith Packard <keithp@keithp.com>
Reviewed-by: Peter Harris <pharris@opentext.com>