C interface to the X Window System protocol, which replaces the traditional Xlib interface.
Go to file
Christian Linhart 265d38882c generator: fix absname for fields with only accessor function
Fix _c_helper_absolute_name for fields which cannot be accessed
as a struct/union member but which can be accessed by an
accessor function.

The fix generates calls to the accessor function in these cases.

Example:
<struct name="AbsnameTest">
<field type="CARD32" name="len" />
<list type="CARD8" name="mylist1">
   <fieldref>len</fieldref>
</list>
<list type="CARD8" name="mylist2">
   <sumof ref="mylist1"/>
</list>
</struct>

The sumof-expression ( <sumof ref="mylist1"/> ) refers to mylist1
which is only acessible by an accessor function.

Previously, sumof was only used inside bitcases,
where such lists are accessible by members of the
deserialized parent struct.
(there is a difference between deserialization of switches
and structs.)

V2 of this patch:
* replaced "!= None" with "is not None" because that's more pythonic.
(according to suggestion from Ran Benita)

V3 of this patch: simplification:
* fixed the recursion in _c_type_setup
  so that _c_helper_absolute_name does not need check
  a gazillion things as a workaround anymore.

* simplified _c_helper_absolute_name
  - remove unneeded check for empty string before
    append of last_sep to prefix_str

  - removed those if-conditions which are not
    needed anymore after fixing the recursion
    in _c_type_setup.

  - extract functionality for checking whether a field
    needs an accessor ( and which type of accessor )
    in functions.
    (also extracted from _c_accessors)

  - rearrange the condition branches and actions for
    more readability.

V3 generates exactly the same *.c and *.h files as V2.

V4 of this patch:
* improve formatting as per suggestions of Ran

Signed-off-by: Christian Linhart <chris@DemoRecorder.com>
Reviewed-by: Ran Benita <ran234@gmail.com>

Message-ID: <54562758.5090107@DemoRecorder.com>
Patch-Thread-Subject: [Xcb] [PATCHSET] ListInputDevices revision 2
Patch-Set: ListInputDevices
Patch-Number: libxcb 1/9
Patch-Version: V4
2014-11-03 11:23:16 +01:00
doc Fix typos & awkward wording in tutorial 2014-07-11 20:41:15 -07:00
m4 config: issue an error if DRI3 is requested, but sendfds is not available 2014-08-06 13:26:08 +02:00
man man: build static man pages using xorg patterns 2014-01-30 12:10:00 +09:00
src generator: fix absname for fields with only accessor function 2014-11-03 11:23:16 +01:00
tests tests: Add files to .gitignore 2013-08-15 00:35:08 +02:00
tools Match only XCB-namespaced XID generators when converting to xcb_generate_id. 2006-10-15 12:34:30 -07:00
.autom4te.cfg Use build-aux as autom4te cache directory 2013-08-15 00:35:07 +02:00
.gitignore Add ChangeLog and INSTALL using xorg macros 2014-08-06 13:29:16 +02:00
COPYING Fix the year in COPYING. 2006-04-27 17:32:20 -07:00
Makefile.am Add ChangeLog and INSTALL using xorg macros 2014-08-06 13:29:16 +02:00
NEWS Release libxcb 1.11 2014-08-01 16:04:34 +02:00
README Release libxcb 1.1 2007-11-04 17:29:13 -08:00
autogen.sh autogen.sh: Implement GNOME Build API 2013-01-16 13:20:49 -05:00
check-pc-requires Validate .pc file Requires lines 2014-03-22 14:44:52 +01:00
configure.ac Disable Xevie and Xprint by default 2014-08-06 13:32:50 +02:00
xcb-composite.pc.in Lowercase library names to correspond with the new API. 2006-09-25 01:42:12 -07:00
xcb-damage.pc.in Lowercase library names to correspond with the new API. 2006-09-25 01:42:12 -07:00
xcb-dpms.pc.in Lowercase library names to correspond with the new API. 2006-09-25 01:42:12 -07:00
xcb-dri2.pc.in Add DRI2 support. (v2) 2009-10-19 09:47:06 -07:00
xcb-dri3.pc.in Add DRI3 library 2013-11-07 14:02:37 -08:00
xcb-glx.pc.in Lowercase library names to correspond with the new API. 2006-09-25 01:42:12 -07:00
xcb-present.pc.in Update .pc file Requires lines to express full dependencies 2014-03-22 14:44:52 +01:00
xcb-randr.pc.in Update .pc file Requires lines to express full dependencies 2014-03-22 14:44:52 +01:00
xcb-record.pc.in Lowercase library names to correspond with the new API. 2006-09-25 01:42:12 -07:00
xcb-render.pc.in Lowercase library names to correspond with the new API. 2006-09-25 01:42:12 -07:00
xcb-res.pc.in Lowercase library names to correspond with the new API. 2006-09-25 01:42:12 -07:00
xcb-screensaver.pc.in Lowercase library names to correspond with the new API. 2006-09-25 01:42:12 -07:00
xcb-shape.pc.in Lowercase library names to correspond with the new API. 2006-09-25 01:42:12 -07:00
xcb-shm.pc.in Lowercase library names to correspond with the new API. 2006-09-25 01:42:12 -07:00
xcb-sync.pc.in Lowercase library names to correspond with the new API. 2006-09-25 01:42:12 -07:00
xcb-xevie.pc.in Lowercase library names to correspond with the new API. 2006-09-25 01:42:12 -07:00
xcb-xf86dri.pc.in Lowercase library names to correspond with the new API. 2006-09-25 01:42:12 -07:00
xcb-xfixes.pc.in Lowercase library names to correspond with the new API. 2006-09-25 01:42:12 -07:00
xcb-xinerama.pc.in Use substitition variables in xcb-xinerama.pc.in, not instances of their values 2006-11-25 22:27:33 -08:00
xcb-xinput.pc.in Update .pc file Requires lines to express full dependencies 2014-03-22 14:44:52 +01:00
xcb-xkb.pc.in small fix in the xkb pkg file 2010-08-16 18:22:42 +02:00
xcb-xprint.pc.in Lowercase library names to correspond with the new API. 2006-09-25 01:42:12 -07:00
xcb-xselinux.pc.in Add SELinux extension support, disabled by default. 2008-01-24 16:02:34 -05:00
xcb-xtest.pc.in Lowercase library names to correspond with the new API. 2006-09-25 01:42:12 -07:00
xcb-xv.pc.in Lowercase library names to correspond with the new API. 2006-09-25 01:42:12 -07:00
xcb-xvmc.pc.in Lowercase library names to correspond with the new API. 2006-09-25 01:42:12 -07:00
xcb.pc.in Store xcbproto version libxcb was compiled with 2009-05-25 12:20:23 +02:00

About libxcb
============

libxcb provides an interface to the X Window System protocol, which
replaces the current Xlib interface. It has several advantages over
Xlib, including:
- size: small, simple library, and lower memory footprint
- latency hiding: batch several requests and wait for the replies later
- direct protocol access: interface and protocol correspond exactly
- proven thread support: transparently access XCB from multiple threads
- easy extension implementation: interfaces auto-generated from XML-XCB

Xlib can also use XCB as a transport layer, allowing software to make
requests and receive responses with both, which eases porting to XCB.
However, client programs, libraries, and toolkits will gain the most
benefit from a native XCB port.


Please report any issues you find to the freedesktop.org bug tracker,
at:

	<https://bugs.freedesktop.org/enter_bug.cgi?product=XCB>

Discussion about XCB occurs on the XCB mailing list:

        <mailto:xcb at lists.freedesktop.org>
        <http://lists.freedesktop.org/mailman/listinfo/xcb>

You can obtain the latest development versions of XCB using GIT.
For anonymous checkouts, use:

        git clone git://anongit.freedesktop.org/git/xcb/libxcb

For developers, use:

        git clone git+ssh://git.freedesktop.org/git/xcb/libxcb