pub struct Window { /* private fields */ }Implementations§
Source§impl Window
impl Window
Sourcepub fn create<T: Proc + 'static>(
rect: Recti,
title: &str,
parent: Option<WindowId>,
item: T,
) -> Result<Self, SystemError>
pub fn create<T: Proc + 'static>( rect: Recti, title: &str, parent: Option<WindowId>, item: T, ) -> Result<Self, SystemError>
Examples found in repository?
examples/window.rs (lines 29-34)
28fn main() {
29 let window = Window::create(
30 Rect::from((Point::new(100, 100), Size::new(800, 600))),
31 "Hello World",
32 None,
33 MyWindow {},
34 )
35 .unwrap();
36
37 window.show();
38
39 while App::handle_event(true).unwrap() {}
40}Methods from Deref<Target = Window>§
pub fn handle(&self) -> WindowHandle
pub const USER_DEF_BASE: u32 = WM_USER
pub const APP_DEF_BASE: u32 = WM_APP
Trait Implementations§
Source§impl AsMut<The<WindowData>> for Window
impl AsMut<The<WindowData>> for Window
Source§fn as_mut(&mut self) -> &mut The<WindowData>
fn as_mut(&mut self) -> &mut The<WindowData>
Converts this type into a mutable reference of the (usually inferred) input type.
Source§impl AsRef<The<WindowData>> for Window
impl AsRef<The<WindowData>> for Window
Source§fn as_ref(&self) -> &The<WindowData>
fn as_ref(&self) -> &The<WindowData>
Converts this type into a shared reference of the (usually inferred) input type.
Auto Trait Implementations§
impl Freeze for Window
impl !RefUnwindSafe for Window
impl !Send for Window
impl !Sync for Window
impl Unpin for Window
impl UnsafeUnpin for Window
impl !UnwindSafe for Window
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