BoxShadows
struct · ferroui-base · v0.5.0
struct BoxShadows
Represents a collection of BoxShadows.
Members
new
fn new(shadow: BoxShadow) -> Self
Creates a collection containing a single shadow. A default shadow produces an empty collection.
with_rest
fn with_rest(first: BoxShadow, rest: &[BoxShadow]) -> Self
Creates a collection containing first followed by rest.
count
fn count(self: &Self) -> usize
The number of shadows in the collection.
get
fn get(self: &Self, index: usize) -> BoxShadow
The shadow at index. Panics if the index is out of range.
iter
fn iter(self: &Self) -> impl Iterator<Item = BoxShadow> + '_
Iterates over the shadows.
parse
fn parse(s: &str) -> Result<BoxShadows, FormatError>
Parses a comma separated list of box shadows.
transform_bounds
fn transform_bounds(self: &Self, rect: Rect) -> Rect
Transforms the specified bounding rectangle to account for every shadow in the collection.
has_inset_shadows
fn has_inset_shadows(self: &Self) -> bool
Whether the collection contains an inset shadow.
Trait implementations
SendSyncFreezeUnsafeUnpinUnpinUnwindSafeRefUnwindSafePropertyValueAnyValueClassDefaultsBorrow<T>BorrowMut<T>CloneToUninitInto<U>From<T>TryInto<U>TryFrom<U>AnyToOwnedToStringErasedDestructorIntoEitherTransition<BoxShadows>CloneDebugDefaultPartialEqFromStrDisplayMarkupTypedValueTypeRegistration
Availability
Extracted for aarch64-apple-darwin. Cargo features are listed in the crate index.