pub struct WindowHandle { /* private fields */ }Expand description
A window of the application, named by the id of its Window node.
Copy, so it can move into any number of handlers. current_window hands out the
one the caller is in.
Implementations§
Source§impl WindowHandle
impl WindowHandle
Sourcepub const fn id(&self) -> u32
pub const fn id(&self) -> u32
The id of the window’s node, the number its events are reported under.
Sourcepub fn focus(&self)
pub fn focus(&self)
Brings the window forward and makes it the key window. A platform that does not let an application take the focus makes the window flash in the task bar instead.
Sourcepub fn set_theme(&self, theme: Theme)
pub fn set_theme(&self, theme: Theme)
Gives this window a theme of its own over the application’s.
Sourcepub fn size(&self) -> WindowSize
pub fn size(&self) -> WindowSize
What this window last measured. Not recorded as a read; a composable that has to
run again when the class changes reads current_window_size().
Sourcepub fn set_zoom_level(&self, level: i8)
pub fn set_zoom_level(&self, level: i8)
Asks for an application zoom level for this window, kept inside its range.
Trait Implementations§
Source§impl Clone for WindowHandle
impl Clone for WindowHandle
impl Copy for WindowHandle
Source§impl Debug for WindowHandle
impl Debug for WindowHandle
impl Eq for WindowHandle
Source§impl PartialEq for WindowHandle
impl PartialEq for WindowHandle
impl StructuralPartialEq for WindowHandle
Auto Trait Implementations§
impl Forget for WindowHandle
impl Freeze for WindowHandle
impl Move for WindowHandle
impl RefUnwindSafe for WindowHandle
impl Send for WindowHandle
impl Sync for WindowHandle
impl Unpin for WindowHandle
impl UnsafeUnpin for WindowHandle
impl UnwindSafe for WindowHandle
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