pub trait WindowExt {
// Required methods
fn get_xlib_window(&self) -> Option<u64>;
fn get_xlib_display(&self) -> Option<*mut c_void>;
fn get_xlib_screen_id(&self) -> Option<i32>;
fn set_urgent(&self, is_urgent: bool);
fn get_xcb_connection(&self) -> Option<*mut c_void>;
fn get_wayland_surface(&self) -> Option<*mut c_void>;
fn get_wayland_display(&self) -> Option<*mut c_void>;
fn is_ready(&self) -> bool;
}
Expand description
Additional methods on Window
that are specific to Unix.
Required Methods§
sourcefn get_xlib_window(&self) -> Option<u64>
fn get_xlib_window(&self) -> Option<u64>
Returns the ID of the Window
xlib object that is used by this window.
Returns None
if the window doesn’t use xlib (if it uses wayland for example).
sourcefn get_xlib_display(&self) -> Option<*mut c_void>
fn get_xlib_display(&self) -> Option<*mut c_void>
Returns a pointer to the Display
object of xlib that is used by this window.
Returns None
if the window doesn’t use xlib (if it uses wayland for example).
The pointer will become invalid when the glutin Window
is destroyed.
fn get_xlib_screen_id(&self) -> Option<i32>
sourcefn set_urgent(&self, is_urgent: bool)
fn set_urgent(&self, is_urgent: bool)
Set window urgency hint (XUrgencyHint
). Only relevant on X.
sourcefn get_xcb_connection(&self) -> Option<*mut c_void>
fn get_xcb_connection(&self) -> Option<*mut c_void>
This function returns the underlying xcb_connection_t
of an xlib Display
.
Returns None
if the window doesn’t use xlib (if it uses wayland for example).
The pointer will become invalid when the glutin Window
is destroyed.
sourcefn get_wayland_surface(&self) -> Option<*mut c_void>
fn get_wayland_surface(&self) -> Option<*mut c_void>
Returns a pointer to the wl_surface
object of wayland that is used by this window.
Returns None
if the window doesn’t use wayland (if it uses xlib for example).
The pointer will become invalid when the glutin Window
is destroyed.
sourcefn get_wayland_display(&self) -> Option<*mut c_void>
fn get_wayland_display(&self) -> Option<*mut c_void>
Returns a pointer to the wl_display
object of wayland that is used by this window.
Returns None
if the window doesn’t use wayland (if it uses xlib for example).
The pointer will become invalid when the glutin Window
is destroyed.