pub struct ButtonTheme {Show 14 fields
pub background: Option<Rgba>,
pub foreground: Option<Rgba>,
pub border: Option<Rgba>,
pub primary_background: Option<Rgba>,
pub primary_foreground: Option<Rgba>,
pub min_width: Option<f32>,
pub min_height: Option<f32>,
pub padding_horizontal: Option<f32>,
pub padding_vertical: Option<f32>,
pub radius: Option<f32>,
pub icon_spacing: Option<f32>,
pub disabled_opacity: Option<f32>,
pub shadow: Option<bool>,
pub font: Option<FontSpec>,
}Expand description
Push button: colors, sizing, spacing, geometry.
Fields§
§background: Option<Rgba>Default button background fill.
foreground: Option<Rgba>Default button text/icon color.
border: Option<Rgba>Button border color.
primary_background: Option<Rgba>Primary / accent button background fill.
primary_foreground: Option<Rgba>Primary / accent button text/icon color.
min_width: Option<f32>Minimum button width in logical pixels.
min_height: Option<f32>Minimum button height in logical pixels.
padding_horizontal: Option<f32>Horizontal padding inside the button.
padding_vertical: Option<f32>Vertical padding inside the button.
radius: Option<f32>Corner radius in logical pixels.
icon_spacing: Option<f32>Space between icon and label.
disabled_opacity: Option<f32>Opacity multiplier when the button is disabled (0.0–1.0).
shadow: Option<bool>Whether the button has a drop shadow.
font: Option<FontSpec>Button label font specification.
Implementations§
Source§impl ButtonTheme
impl ButtonTheme
Sourcepub const FIELD_NAMES: &[&str]
pub const FIELD_NAMES: &[&str]
All serialized field names for this widget theme, for TOML linting.
Source§impl ButtonTheme
impl ButtonTheme
Trait Implementations§
Source§impl Clone for ButtonTheme
impl Clone for ButtonTheme
Source§fn clone(&self) -> ButtonTheme
fn clone(&self) -> ButtonTheme
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 ButtonTheme
impl Debug for ButtonTheme
Source§impl Default for ButtonTheme
impl Default for ButtonTheme
Source§fn default() -> ButtonTheme
fn default() -> ButtonTheme
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for ButtonThemewhere
ButtonTheme: Default,
impl<'de> Deserialize<'de> for ButtonThemewhere
ButtonTheme: 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 PartialEq for ButtonTheme
impl PartialEq for ButtonTheme
Source§impl Serialize for ButtonTheme
impl Serialize for ButtonTheme
impl StructuralPartialEq for ButtonTheme
Auto Trait Implementations§
impl Freeze for ButtonTheme
impl RefUnwindSafe for ButtonTheme
impl Send for ButtonTheme
impl Sync for ButtonTheme
impl Unpin for ButtonTheme
impl UnsafeUnpin for ButtonTheme
impl UnwindSafe for ButtonTheme
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