What is XCB (X C binding)?

What is XCB (X C binding)?

XCB (“X C Binding”) is an low-level API for the X window server. XCB is an alternative to Xlib, which has been the standard C binding for the X Window System protocol for many years now. Xlib is an excellent piece of work, but there are applications for which it is not ideal, for example:

What is the XCB protocol?

XCB is built atop an XML description of the X core protocol and common extension protocols called XML/XCB. This protocol can be used in other interesting ways. Documentation of the X Window System protocol is also available at X.org’s website, and can be used in combination with XCB documentation as XCB functions largely reflect the protocol.

What is the difference between Xlib and XCB?

Xlib/XCB allows an application to open a single connection to the X display server and use both XCB and Xlib, possibly through a mixture of libraries designed for one or the other. XCB has a comparable, but slightly lower-level API than Xlib, as can be seen with this example.

How do I get the latest XCB?

You can obtain released versions of XCB from http://xcb.freedesktop.org/dist. Follow the instructions from the developer’s guide to build, except that you can use released versions of the dependencies, and you don’t need git, automake, autoconf, or libtool.

author

Back to Top