[−][src]Struct ggez::conf::WindowMode
A builder structure containing window settings
that can be set at runtime and changed with graphics::set_mode()
.
Defaults:
WindowMode { width: 800.0, height: 600.0, maximized: false, fullscreen_type: FullscreenType::Windowed, borderless: false, min_width: 0.0, max_width: 0.0, min_height: 0.0, max_height: 0.0, resizable: false, }
Fields
width: f32
Window width
height: f32
Window height
maximized: bool
Whether or not to maximize the window
fullscreen_type: FullscreenType
Fullscreen type
borderless: bool
Whether or not to show window decorations
min_width: f32
Minimum width for resizable windows; 0 means no limit
min_height: f32
Minimum height for resizable windows; 0 means no limit
max_width: f32
Maximum width for resizable windows; 0 means no limit
max_height: f32
Maximum height for resizable windows; 0 means no limit
resizable: bool
Whether or not the window is resizable
Methods
impl WindowMode
[src]
pub fn dimensions(self, width: f32, height: f32) -> Self
[src]
Set default window size, or screen resolution in true fullscreen mode.
pub fn maximized(self, maximized: bool) -> Self
[src]
Set whether the window should be maximized.
pub fn fullscreen_type(self, fullscreen_type: FullscreenType) -> Self
[src]
Set the fullscreen type.
pub fn borderless(self, borderless: bool) -> Self
[src]
Set whether a window should be borderless in windowed mode.
pub fn min_dimensions(self, width: f32, height: f32) -> Self
[src]
Set minimum window dimensions for windowed mode.
pub fn max_dimensions(self, width: f32, height: f32) -> Self
[src]
Set maximum window dimensions for windowed mode.
pub fn resizable(self, resizable: bool) -> Self
[src]
Set resizable.
Trait Implementations
impl PartialEq<WindowMode> for WindowMode
[src]
fn eq(&self, other: &WindowMode) -> bool
[src]
fn ne(&self, other: &WindowMode) -> bool
[src]
impl Clone for WindowMode
[src]
fn clone(&self) -> WindowMode
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl Default for WindowMode
[src]
fn default() -> Self
[src]
Return WindowMode { width: 800.0, height: 600.0, maximized: false, fullscreen_type: FullscreenType :: Windowed, borderless: false, min_width: 0.0, min_height: 0.0, max_width: 0.0, max_height: 0.0, resizable: false }
impl Copy for WindowMode
[src]
impl Debug for WindowMode
[src]
impl Serialize for WindowMode
[src]
fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error> where
__S: Serializer,
[src]
__S: Serializer,
impl<'de> Deserialize<'de> for WindowMode
[src]
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
[src]
__D: Deserializer<'de>,
Auto Trait Implementations
impl Unpin for WindowMode
impl Sync for WindowMode
impl Send for WindowMode
impl RefUnwindSafe for WindowMode
impl UnwindSafe for WindowMode
Blanket Implementations
impl<T> From<T> for T
[src]
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Scalar for T where
T: Copy + PartialEq<T> + Any + Debug,
[src]
T: Copy + PartialEq<T> + Any + Debug,
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<SS, SP> SupersetOf<SS> for SP where
SS: SubsetOf<SP>,
SS: SubsetOf<SP>,
fn to_subset(&self) -> Option<SS>
fn is_in_subset(&self) -> bool
unsafe fn to_subset_unchecked(&self) -> SS
fn from_subset(element: &SS) -> SP
impl<T> DeserializeOwned for T where
T: Deserialize<'de>,
[src]
T: Deserialize<'de>,
impl<T> Erased for T
impl<T> SetParameter for T
fn set<T>(&mut self, value: T) -> <T as Parameter<Self>>::Result where
T: Parameter<Self>,
T: Parameter<Self>,
Sets value
as a parameter of self
.