#[repr(C)]pub struct WindowCreateOptions {
pub state: WindowState,
pub size_to_content: bool,
pub renderer: OptionRendererOptions,
pub theme: OptionWindowTheme,
pub create_callback: OptionCallback,
pub hot_reload: bool,
}Fields§
§state: WindowState§size_to_content: boolIf set, the first UI redraw will be called with a size of (0, 0) and the window size depends on the size of the overflowing UI. This is good for windows that do not want to take up unnecessary extra space
renderer: OptionRendererOptionsRenderer type: Hardware-with-software-fallback, pure software or pure hardware renderer?
theme: OptionWindowThemeOverride the default window theme (set to None to use the OS-provided theme)
create_callback: OptionCallbackOptional callback to run when the window has been created (runs only once on startup)
hot_reload: boolIf set to true, will hot-reload the UI every 200ms, useful in combination with
StyledDom::from_file() to hot-reload the UI from a file while developing.
Implementations§
Source§impl WindowCreateOptions
impl WindowCreateOptions
pub fn new(callback: LayoutCallbackType) -> Self
pub fn renderer_types(&self) -> Vec<RendererType>
Trait Implementations§
Source§impl Clone for WindowCreateOptions
impl Clone for WindowCreateOptions
Source§fn clone(&self) -> WindowCreateOptions
fn clone(&self) -> WindowCreateOptions
Returns a duplicate 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 WindowCreateOptions
impl Debug for WindowCreateOptions
Auto Trait Implementations§
impl Freeze for WindowCreateOptions
impl RefUnwindSafe for WindowCreateOptions
impl Send for WindowCreateOptions
impl Sync for WindowCreateOptions
impl Unpin for WindowCreateOptions
impl UnwindSafe for WindowCreateOptions
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more