Struct glutin_window::GlutinWindow [−][src]
pub struct GlutinWindow {
pub window: GlWindow,
// some fields omitted
}Contains stuff for game window.
Fields
window: GlWindow
The window.
Methods
impl GlutinWindow[src]
impl GlutinWindowpub fn new(settings: &WindowSettings) -> Result<Self, String>[src]
pub fn new(settings: &WindowSettings) -> Result<Self, String>Creates a new game window for Glutin.
Trait Implementations
impl Window for GlutinWindow[src]
impl Window for GlutinWindowfn size(&self) -> Size[src]
fn size(&self) -> SizeGets the size of the window.
fn draw_size(&self) -> Size[src]
fn draw_size(&self) -> SizeGets the draw size of the window. Read more
fn should_close(&self) -> bool[src]
fn should_close(&self) -> boolReturns true if the window should close.
fn set_should_close(&mut self, value: bool)[src]
fn set_should_close(&mut self, value: bool)Tells the window to close or stay open.
fn swap_buffers(&mut self)[src]
fn swap_buffers(&mut self)Swaps render buffers. Read more
fn wait_event(&mut self) -> Input[src]
fn wait_event(&mut self) -> InputWait indefinitely for an input event to be available from the window.
fn wait_event_timeout(&mut self, timeout: Duration) -> Option<Input>[src]
fn wait_event_timeout(&mut self, timeout: Duration) -> Option<Input>Wait for an input event to be available from the window or for the specified timeout to be reached. Read more
fn poll_event(&mut self) -> Option<Input>[src]
fn poll_event(&mut self) -> Option<Input>Polls an input event from the window. Read more
impl BuildFromWindowSettings for GlutinWindow[src]
impl BuildFromWindowSettings for GlutinWindowfn build_from_window_settings(settings: &WindowSettings) -> Result<Self, String>[src]
fn build_from_window_settings(settings: &WindowSettings) -> Result<Self, String>Builds the window from a WindowSettings object. Read more
impl AdvancedWindow for GlutinWindow[src]
impl AdvancedWindow for GlutinWindowfn get_title(&self) -> String[src]
fn get_title(&self) -> StringGets a copy of the title of the window.
fn set_title(&mut self, value: String)[src]
fn set_title(&mut self, value: String)Sets the title of the window.
fn get_exit_on_esc(&self) -> bool[src]
fn get_exit_on_esc(&self) -> boolGets whether to exit when pressing esc. Read more
fn set_exit_on_esc(&mut self, value: bool)[src]
fn set_exit_on_esc(&mut self, value: bool)Sets whether to exit when pressing esc. Read more
fn set_capture_cursor(&mut self, value: bool)[src]
fn set_capture_cursor(&mut self, value: bool)Sets whether to capture/grab the cursor. Read more
fn show(&mut self)[src]
fn show(&mut self)Shows the window. Read more
fn hide(&mut self)[src]
fn hide(&mut self)Hides the window. Read more
fn get_position(&self) -> Option<Position>[src]
fn get_position(&self) -> Option<Position>Gets the position of window.
fn set_position<P: Into<Position>>(&mut self, pos: P)[src]
fn set_position<P: Into<Position>>(&mut self, pos: P)Sets the position of window. Read more
fn set_size<S: Into<Size>>(&mut self, size: S)[src]
fn set_size<S: Into<Size>>(&mut self, size: S)Sets the window size. Read more
fn title(self, value: String) -> Self[src]
fn title(self, value: String) -> SelfSets title on window. Read more
fn exit_on_esc(self, value: bool) -> Self[src]
fn exit_on_esc(self, value: bool) -> SelfSets whether to exit when pressing the Esc button. Read more
fn capture_cursor(self, value: bool) -> Self[src]
fn capture_cursor(self, value: bool) -> SelfSets whether to capture/grab the cursor. Read more
fn position<P>(self, val: P) -> Self where
P: Into<Position>, [src]
fn position<P>(self, val: P) -> Self where
P: Into<Position>, Sets the position of window. Read more
impl OpenGLWindow for GlutinWindow[src]
impl OpenGLWindow for GlutinWindowfn get_proc_address(&mut self, proc_name: &str) -> ProcAddress[src]
fn get_proc_address(&mut self, proc_name: &str) -> ProcAddressReturns the address of the specified OpenGL function if it exists. Read more
fn is_current(&self) -> bool[src]
fn is_current(&self) -> boolReturns true if this window's gl context is the current gl context.
fn make_current(&mut self)[src]
fn make_current(&mut self)Make the window's gl context the current gl context.
Auto Trait Implementations
impl !Send for GlutinWindow
impl !Send for GlutinWindowimpl !Sync for GlutinWindow
impl !Sync for GlutinWindow