pub struct Settings {
pub id: Option<String>,
pub fonts: Vec<Cow<'static, [u8]>>,
pub default_font: Font,
pub default_text_size: Pixels,
pub antialiasing: bool,
}
Expand description
The settings of an iced program.
Fields§
§id: Option<String>
The identifier of the application.
If provided, this identifier may be used to identify the application or communicate with it through the windowing system.
fonts: Vec<Cow<'static, [u8]>>
The fonts to load on boot.
default_font: Font
The default Font
to be used.
By default, it uses Family::SansSerif
.
default_text_size: Pixels
The text size that will be used by default.
The default value is 16.0
.
antialiasing: bool
If set to true, the renderer will try to perform antialiasing for some primitives.
Enabling it can produce a smoother result in some widgets, like the
canvas
widget, at a performance cost.
By default, it is enabled.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Settings
impl RefUnwindSafe for Settings
impl Send for Settings
impl Sync for Settings
impl Unpin for Settings
impl UnwindSafe for Settings
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,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
§impl<T> NoneValue for Twhere
T: Default,
impl<T> NoneValue for Twhere
T: Default,
type NoneType = T
§fn null_value() -> T
fn null_value() -> T
The none-equivalent value.