pub trait ShadowView: View {
// Required method
fn shadow_node(&mut self) -> &mut BoxShadow;
// Provided methods
fn shadow(self, shadows: Vec<ShadowStyle>) -> Self { ... }
fn add_shadow(self, shadow: ShadowStyle) -> Self { ... }
}Expand description
A trait for setting and modifying UI container shadow styles.
Required Methods§
Sourcefn shadow_node(&mut self) -> &mut BoxShadow
fn shadow_node(&mut self) -> &mut BoxShadow
Returns a mutable reference to the internal shadow style list.
Provided Methods§
Sourcefn shadow(self, shadows: Vec<ShadowStyle>) -> Self
fn shadow(self, shadows: Vec<ShadowStyle>) -> Self
Replaces all existing shadows with the provided list.
Sourcefn add_shadow(self, shadow: ShadowStyle) -> Self
fn add_shadow(self, shadow: ShadowStyle) -> Self
Appends a new shadow to the current list.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.