pub struct WindowSettings { /* private fields */ }
Expand description
Can be used to store native window settings (position and size).
Implementations§
Source§impl WindowSettings
impl WindowSettings
pub fn from_window(egui_zoom_factor: f32, window: &Window) -> Self
pub fn inner_size_points(&self) -> Option<Vec2>
pub fn initialize_viewport_builder( &self, egui_zoom_factor: f32, event_loop: &ActiveEventLoop, viewport_builder: ViewportBuilder, ) -> ViewportBuilder
pub fn initialize_window(&self, window: &Window)
pub fn clamp_size_to_sane_values(&mut self, largest_monitor_size_points: Vec2)
pub fn clamp_position_to_monitors( &mut self, egui_zoom_factor: f32, event_loop: &ActiveEventLoop, )
Trait Implementations§
Source§impl Clone for WindowSettings
impl Clone for WindowSettings
Source§fn clone(&self) -> WindowSettings
fn clone(&self) -> WindowSettings
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for WindowSettings
impl Debug for WindowSettings
Source§impl Default for WindowSettings
impl Default for WindowSettings
Source§fn default() -> WindowSettings
fn default() -> WindowSettings
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for WindowSettingswhere
WindowSettings: Default,
impl<'de> Deserialize<'de> for WindowSettingswhere
WindowSettings: Default,
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Serialize for WindowSettings
impl Serialize for WindowSettings
impl Copy for WindowSettings
Auto Trait Implementations§
impl Freeze for WindowSettings
impl RefUnwindSafe for WindowSettings
impl Send for WindowSettings
impl Sync for WindowSettings
impl Unpin for WindowSettings
impl UnwindSafe for WindowSettings
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