pub struct XConnection {
pub xlib: Xlib,
pub xf86vmode: Xf86vmode,
pub xcursor: Xcursor,
pub xinput2: XInput2,
pub xlib_xcb: Xlib_xcb,
pub display: *mut _XDisplay,
pub latest_error: Mutex<Option<XError>>,
}
Expand description
A connection to an X server.
Fields§
§xlib: Xlib
§xf86vmode: Xf86vmode
§xcursor: Xcursor
§xinput2: XInput2
§xlib_xcb: Xlib_xcb
§display: *mut _XDisplay
§latest_error: Mutex<Option<XError>>
Implementations§
source§impl XConnection
impl XConnection
pub fn new( error_handler: Option<unsafe extern "C" fn(_: *mut _XDisplay, _: *mut XErrorEvent) -> i32> ) -> Result<XConnection, XNotSupported>
sourcepub fn check_errors(&self) -> Result<(), XError>
pub fn check_errors(&self) -> Result<(), XError>
Checks whether an error has been triggered by the previous function calls.
sourcepub fn ignore_error(&self)
pub fn ignore_error(&self)
Ignores any previous error.
Trait Implementations§
Auto Trait Implementations§
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more