PackageTrack
Sign in Get early access

x11rb-protocol

Rust bindings to X11

0.14.0 55M downloads/mo #1166 most downloaded on crates.io psychon/x11rb

What this package is like to depend on

Last release 1 months ago

16 Jul 2026

Ships fairly regularly

a new release about every 5 months

Nearly every release is documented

notes for 8 of 8 stable releases

Nothing withdrawn

no release was ever pulled

4 years old

8 releases · first in 2022

2 releases in the last 12 months

see the full history below

Release timeline

8 releases · Jun 2022 to Jul 2026
2023 2024 2025 2026
Release Pre-release

Releases

latest 8
  1. 0.14.0 16 Jul 2026
    Release notes

    New features:

    • Allow building with libloading 0.9.

    Fixes:

    • Fix CUT_BUFFER0 to CUT_BUFFER7 atom names. The generated code previously used CUT_BUFFE_R0.

    Breaking changes:

    • Drop abstract unix socket support, following a change in libxcb.
    • MSRV increased to Rust 1.68.
    • Update to raw-window-handle 0.6.

    Minor changes:

    • Pin various dependencies in CI to keep the MSRV check working.
    • Fix various new clippy and Rust warnings.
    Open source →
  2. 0.13.2 29 Aug 2025
    Release notes

    New features:

    • Update cursor icon file search path to follow a change in libxcb-cursor which in turn was changed to follow libXcursor.
    • Get cursor theme name from $XCURSOR_THEME if set.
    • Added XCBConnection::from_existing_connection to allow wrapping anything that implements AsRawXcbConection. Without this function, unsafe code was required from the user.
    • Added raw-window-handle feature which makes XCBConnection implement HasRawDisplayHandle and WindowWrapper implement HasRawWindowHandle.
    • Use new hints.mostly-unused Cargo feature. This might improve compilation speed with nightly compilers.

    Fixes:

    • Fix missing indentation in doc comments in generated code.
    • Fix a minor X11 resource leak in cursor code.
    • Gate tests behind the features they need so that cargo test --no-default-features works. This is now also tested in CI.
    • The present feature depends on dri3 to actually work, but this was not specified in Cargo.toml.

    Breaking changes:

    • MSRV increased to Rust 1.64.

    Minor changes:

    • Various minor changes to fix new compiler and clippy warnings and improve readability.
    • Use existing xcursor-rs crate for cursor and cursor theme file parsing instead of own code.
    • Updated dependencies to rustix 1.0, gethostname 1.0. This required a MSRV increase to Rust 1.64.
    • Pin various dependencies in CI to keep our MSRV check working.
    Open source →
  3. 0.13.1 01 May 2024
    Release notes

    New features:

    • Add an xkbcommon-example to showcase use of x11rb together with the xkbcommon crate.
    • Update from xcb-proto 1.15.2 to 1.17.0. This brings support for PRESENT 1.4 and DRI3 1.4 and fixes some typos in the documentation.

    Fixes:

    • Macro hygiene: atom_manager! macro now uses::std when referring to std items.

    Breaking changes:

    • Optimise atom_manager! implementation. This changes the contents of the generated Cookie struct, but there should be no reasons to access these directly.
    • Remove some unreachable public API from x11rb-async's StreamAdaptor.

    Minor changes:

    • Fix new compiler warnings and enable more lints.
    • Update dependencies.
    Open source →
  4. 0.13.0 09 Dec 2023
    Release notes

    New features:

    • A bitmask enum in the generates code has new methods bits() for conversion to integer and remove() for removing certain bits.
    • Update our bundled xcb-proto version. This update brings new documentation and support for newer versions of the DPMS and Present extensions.
    • Update $DISPLAY parsing to match new behaviour in libxcb 1.16.
    • Some variant of x11rb_protocol::parse_display is now also available in no_std mode.
    • Better error message if $DISPLAY parsing fails.
    • Add Image::into_owned() to get an Image instance with 'static.
    • Change Image::put() to convert the image to the X11 server's native representation before uploading.
    • Implement x11rb's RequestConnection for &C, &mut C, Box<C>, Arc<C>, Rc<C> and Cow<'_, C> where C: RequestConnection.

    Fixes:

    • Fix broken link to x11rb in documentation of x11rb-async.
    • Strip leading whitespace from documentation comments in code generator.
    • Fix the dl-libxcb feature on OpenBSD. There is no libxcb.so.2 on this system and we can simply ask for libxcb.so to be loaded.
    • x11rb-async always needed at least tracing 0.1.33, but incorrectly declared compatibility with all 0.1 versions.

    Breaking changes:

    • Indicate not present properties in x11rb's WmClass, WmSizeHints, and WmHints helpers by introducing an Option in their return value. Previously, missing properties were reported as a parsing error.
    • Avoid a Vec in some places in x11rb-protocol by using arrays instead. This affects the return value of a request's serialize() function, but also some internal code.
    • Remove unused read_exact() method in x11rb's Stream trait.
    • Replace use of nix with rustix and implement io-safety. This e.g. means that some types no longer implement PartialEq due to rustix's behaviour. FD passing now uses std::os::unix::io::OwnedFd.
    • MSRV was bumped from Rust 1.56 to 1.63 for rustix 0.38.
    • Change some functions in x11rb::rust_connection::stream::DefaultStream to also return the address that a connection was established to.
    • Change wrapper types like WindowWrapper not to require a reference to a connection, but to accept any connection type directly. Due to the new feature mentioned above, this allows to use these wrappers e.g. with Arc<C>.
    • Types in x11rb-protocol now implement less commonly used traits like PartialEq, Eq, PartialOrd, Ord, and Hash only if the new extra-traits feature is enabled. The Debug impl only produces the name of the type and not its contents in this case. This change improves compile times of the crate.
    • Parsing of requests with the R::try_parse_request function is now gated behind the new request-parsing feature. This change improves compile times.

    Minor changes:

    • Update dependencies.
    • Enable all features when building for docs.rs.
    • Fix some lints in examples.
    • Change some log calls from info to debug.
    • Drop gethostname dependencies on unix by using rustix instead.
    • Various changes to please clippy.
    • Improve docs front pages.
    Open source →
  5. 0.12.0 27 May 2023
    Release notes

    New features:

    • There is a new crate x11rb-async that brings x11rb to the async ecosystem.
    • Bitmask enumerations now also implement BitAnd, BitAndAssign and BitOrAssign and offers contains() and intersects() methods.
    • Add (optional) support for the as-raw-xcb-connection crate.
    • Implement Default for x11rb_protocol::connection::Connection.
    • Optional support for the tracing crate.
    • New API to convert major + minor opcode of a request to human readable names.

    Fixes:

    • Improve error message when not all FDs could be sent.
    • Use correct byte order on Image::get() for big-endian servers.
    • Fix build for XCBConnection on architectures without AtomicU64.

    Breaking changes:

    • Various methods on x11rb_protocol::protocol::xinput::EventForSend now return ParseError instead of unwrapping errors internally.
    • The generated names for some structs in x11rb_protocol::protocol::xkb are now better. For example, SelectEventsAuxBitcase1 is now called SelectEventsAuxNewKeyboardNotify, which at least hints towards its meaning.
    • Image::get() now also returns the visual ID from the GetImageReply.

    Minor changes:

    • Update dependencies.
    • Get rid of some (infallible) unwrap()s in generated code by moving this to a hand-written helper function.
    • The usual round of fixing new clippy warnings.
    • Remove some unnecessary unwrap()s in examples.
    • Use the polling crate in the xclock_utc example.
    Open source →
  6. 0.11.1 06 Jan 2023
    Release notes

    Fixes:

    • Fix connection breakage after sending 2^16 requests without a reply.
    • Enable features on docs.rs to have better docs.
    • Fix dl-libxcb feature on NetBSD not finding libxcb.so.
    Open source →
  7. 0.11.0 18 Nov 2022
    Release notes

    New features:

    • All extensions are available in no-std mode.
    • Replies and events now implement Serialize.
    • Support length expressions in structs in the protocol XML representation.
    • Updated to xcb-proto 1.15.2 which brings support for the double buffering extension, dri3 1.3, xfixes 6.0, xinput 2.4, among other things.
    • x11rb::image::Image now implements Clone.

    Fixes:

    • Fixed a broken link in the documentation.
    • The cairo-example now also works under KDE.

    Breaking changes:

    • Consider use of enums as masks when determining enum sizes and then use our enum wrappers for mask fields. For example, all values of xproto::ConfigWindow fit into u8, so previously this was the type used for representing this enumeration. However, it is used as a mask for the value_mask field of ConfigureRequestEvent, which has 16 bits. Thus, ConfigWindow is now represented as u16 and the value_mask field of ConfigureRequestEvent now has type ConfigWindow.
    • Bump MSRV to 1.56 since once_cell switched to the 2021 edition.

    Minor changes:

    • Disable default features of nix crate.
    • Deal with warnings from newest clippy.
    • Improved unit test code coverage.
    • Updated versions of dependencies.
    • Switch to 2021 rust edition.
    • Speed up discard_reply() implementation in Rust for cases with many pending replies via a binary search.
    Open source →
  8. 0.10.0 12 Jun 2022
    Release notes

    New features:

    • x11rb was split into two crates: x11rb-protocol contains code for working with the X11 protocol, but does not do any X11 I/O. The x11rb crate uses x11rb-protocol to implement an X11 client. This change allows to use x11rb-protocol in other crates without depending on a whole X11 client.
    • Lots of new utilities to implement a X11 client in preparation of a possible future x11rb-async. Most of these previously already existed, but were not public. Now, x11rb-protocol makes them available.
    • Add traits around requests that allow to send a request in a generic way.
    • Implement more traits in the generated code, where possible: Default, PartialOrd, Ord, and Hash.
    • x11rb-protocol can be used in no_std mode.
    • Optional serde support via deriving serde::Serialize and serde::Deserialize.
    • Added support for X11 connections over abstract unix sockets.
    • Increased the bus factor of the project by about 50%. Welcome @notgull!

    Breaking changes:

    • Bump MSRV to 1.46 due to the bitflags crate requiring this version. We depend on bitflags through the nix crate.
    • Some minor API breakage due to the split into x11rb/x11rb-protocol. For example, CreateWindowRequest::send() was previously an associated function and was removed, because a similar feature is available via the new request traits. Also, the API for constructing a resource manager database was changed to remove the need for network I/O from its constructor. A convenience function for the old default behaviour is provided in x11rb.

    Minor changes:

    • Deal with warnings from newest clippy.
    • Remove incorrect documentation for non-present fields from the generated code. This documentation was present because the field value is actually deduced from another field's value, for example the length of a vector.
    • Add #[must_use] to setter methods on *Aux structs.
    • Updated to latest versions of dependencies.
    • Received FDs now automatically get the CLOEXEC flag applied.
    Open source →

Every package, every release, already written down.

The archive is open and free. Watching your own project is what we are building next.

Browse the archive