pub struct ThemedPointer { /* private fields */ }Available on crate feature
cursor only.Expand description
A wrapper around WlPointer with convenient set_cursor and
hide_cursor methods.
Implementations§
Source§impl ThemedPointer
impl ThemedPointer
Sourcepub fn set_cursor<D>(
&self,
conn: &mut Connection<D>,
shm: &mut ShmAlloc,
image: &CursorImage,
scale: u32,
serial: u32,
)
pub fn set_cursor<D>( &self, conn: &mut Connection<D>, shm: &mut ShmAlloc, image: &CursorImage, scale: u32, serial: u32, )
Set cursor image.
Refer to WlPointer::set_cursor for more info.
shm and scale are ignored if server-side implementation is used.
§Panics
This function may panic if the CursorShape was created form different CursorTheme
than this ThemedPointer.
Sourcepub fn hide_cursor<D>(&self, conn: &mut Connection<D>, serial: u32)
pub fn hide_cursor<D>(&self, conn: &mut Connection<D>, serial: u32)
Hide cursor.
Sets surface to NULL.
Sourcepub fn destroy<D>(self, conn: &mut Connection<D>)
pub fn destroy<D>(self, conn: &mut Connection<D>)
Destroy cursor’s surface / cursor shape device.
This function does not destroy the pointer.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for ThemedPointer
impl RefUnwindSafe for ThemedPointer
impl Send for ThemedPointer
impl Sync for ThemedPointer
impl Unpin for ThemedPointer
impl UnwindSafe for ThemedPointer
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