pub struct BorderSpec {
pub color: Option<Rgba>,
pub corner_radius: Option<f32>,
pub corner_radius_lg: Option<f32>,
pub line_width: Option<f32>,
pub opacity: Option<f32>,
pub shadow_enabled: Option<bool>,
pub padding_horizontal: Option<f32>,
pub padding_vertical: Option<f32>,
}Expand description
Border specification: color, geometry, and padding.
All fields are optional to support partial overlays – a BorderSpec with
only color set will only override the color when merged.
Fields§
§color: Option<Rgba>Border color.
corner_radius: Option<f32>Corner radius in logical pixels.
corner_radius_lg: Option<f32>Large corner radius in logical pixels (defaults only).
line_width: Option<f32>Border stroke width in logical pixels.
opacity: Option<f32>Border alpha multiplier 0.0–1.0 (defaults only).
shadow_enabled: Option<bool>Whether the bordered element has a drop shadow.
padding_horizontal: Option<f32>Horizontal padding inside the border in logical pixels.
padding_vertical: Option<f32>Vertical padding inside the border in logical pixels.
Implementations§
Source§impl BorderSpec
impl BorderSpec
Sourcepub const FIELD_NAMES: &[&str]
pub const FIELD_NAMES: &[&str]
All serialized field names for BorderSpec, for TOML linting.
Source§impl BorderSpec
impl BorderSpec
Trait Implementations§
Source§impl Clone for BorderSpec
impl Clone for BorderSpec
Source§fn clone(&self) -> BorderSpec
fn clone(&self) -> BorderSpec
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 BorderSpec
impl Debug for BorderSpec
Source§impl Default for BorderSpec
impl Default for BorderSpec
Source§fn default() -> BorderSpec
fn default() -> BorderSpec
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for BorderSpecwhere
BorderSpec: Default,
impl<'de> Deserialize<'de> for BorderSpecwhere
BorderSpec: 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 BorderSpec
impl PartialEq for BorderSpec
Source§impl Serialize for BorderSpec
impl Serialize for BorderSpec
impl StructuralPartialEq for BorderSpec
Auto Trait Implementations§
impl Freeze for BorderSpec
impl RefUnwindSafe for BorderSpec
impl Send for BorderSpec
impl Sync for BorderSpec
impl Unpin for BorderSpec
impl UnsafeUnpin for BorderSpec
impl UnwindSafe for BorderSpec
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