Struct dotrix_core::window::Window [−][src]
pub struct Window { /* fields omitted */ }
Expand description
Window service - a wrapper for winit::window::Window
instance.
Implementations
Gets the window handle from the wrapper
Check if the window will always be on top of other windows.
Returns the monitor on which the window currently resides.
Check if the cursor is grabbed (prevented from leaving the window).
Get the cursor icon.
Check the cursor’s visibility.
Check if the window have decorations.
Check if the window is in fullscreen mode.
Returns the position of the top-left hand corner of the window’s client area relative to the top-left hand corner of the desktop.
Returns the size of the window’s client area in pixels.
The client area is the content of the window, excluding the title bar and borders.
Returns current window aspect ratio
Returns the minimum size of the window in pixels.
Returns the position of the top-left hand corner of the window relative to the top-left hand corner of the desktop.
Note that the top-left hand corner of the desktop is not necessarily the same as the screen. If the user uses a desktop with multiple monitors, the top-left hand corner of the desktop is the top-left hand corner of the monitor at the top-left of the desktop.
The coordinates can be negative if the top-left hand corner of the window is outside of the visible screen region.
Returns the size of the entire window in pixels.
These dimensions include the title bar and borders. If you don’t want that,
use inner_size
instead.
Requests user attention to the window, this has no effect if the application
is already focused. How requesting for user attention manifests is platform
dependent, see UserAttentionType
for details.
Providing None
will unset the request for user attention. Unsetting the
request for user attention might not be done automatically by the WM when
the window receives input.
Returns the scale factor that can be used to map logical pixels to physical pixels, and vice versa.
Returns the resolution of monitor on which the window currently resides.
Change whether or not the window will always be on top of other windows.
Grabs the cursor, preventing it from leaving the window.
Modifies the cursor icon of the window.
Change the position of the cursor in window in pixel coordinates.
Modifies the cursor’s visibility.
Turn window decorations on or off.
Sets the window to exclusive full screen mode with the given video mode.
Use set_fullscreen(None)
to exit fullscreen.
Sets the window to fullscreen or back. You need to specify fullscreen mode.
Pass None
to end fullscreen.
Sets the window icon. On Windows, this is typically the small icon in the top-left corner of the titlebar.
Modifies the inner size of the window.
See inner_size
for more information about the values. This automatically
un-maximizes the window if it’s maximized.
Sets the window to maximized or back.
Sets the window to minimized or back.
Sets a minimum size for the window. This automatically resize the window if it’s smaller than minimum size.
Modifies the position of the window.
See outer_position
for more information about the coordinates. This automatically
un-maximizes the window if it’s maximized.
Sets whether the window is resizable or not.
Trait Implementations
Auto Trait Implementations
impl !RefUnwindSafe for Window
impl !UnwindSafe for Window
Blanket Implementations
Mutably borrows from an owned value. Read more
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more