Didn't test this too much, but it looks like the x11 crate bindings work on my end. Some test code:
use std::ptr::{null};
use std::os::raw::c_int;
use x11::xlib::*;
use x11::xcomposite::*;
fn main() {
unsafe {
let mut event_base_return: c_int = 0;
let mut error_base_return: c_int = 0;
let display = XOpenDisplay(null());
if display.is_null() {
panic!("Failed to open default X display.");
}
XCompositeQueryExtension(display, &mut event_base_return, &mut error_base_return);
let xcomposite_version = XCompositeVersion();
println!("{} {}", event_base_return, error_base_return);
println!("{}", xcomposite_version);
}
}
Didn't test this too much, but it looks like the
x11
crate bindings work on my end. Some test code: