Struct native_windows_gui::WindowT
[−]
[src]
pub struct WindowT<S: Clone + Into<String>> { pub title: S, pub position: (i32, i32), pub size: (u32, u32), pub resizable: bool, pub visible: bool, pub disabled: bool, pub exit_on_close: bool, }
A template that will create a window.
Events:
Event::Destroyed, Event::KeyDown, Event::KeyUp, Event::Char, Event::Closed, Event::MouseDown, Event::MouseUp, Event::Moved, Event::Resized, Event::Raw
Members:
• title
: The title of the window (in the title bar)
• position
: Starting posiion of the window after it is created
• size
: Starting size of the window after it is created
• resizable
: If the user can resize the window or not
• visible
: If the user can see the window or not
• disabled
: If the window is enabled or not. A disabled window do not process events
• exit_on_close
: If NWG should break the event processing loop when this window is closed
Fields
title: S
position: (i32, i32)
size: (u32, u32)
resizable: bool
visible: bool
disabled: bool
exit_on_close: bool
Trait Implementations
impl<S: Clone + Clone + Into<String>> Clone for WindowT<S>
[src]
fn clone(&self) -> WindowT<S>
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more
impl<S: Clone + Into<String>, ID: Hash + Clone> ControlT<ID> for WindowT<S>
[src]
fn type_id(&self) -> TypeId
Should return the TypeId of the generated control. For example a WindowT
struct returns the TypeId of a Window
struct.
fn events(&self) -> Vec<Event>
Should return the events supported by the control.
fn build(&self, ui: &Ui<ID>) -> Result<Box<Control>, Error>
Should instance the control and return it as a Box. If an error is raised, it will be returned by ui.commit
.