ThemeShadowVisual
struct · ferroui-base · v0.5.0
struct ThemeShadowVisual
The shadow visual of a caster: created by the caster's
Visual, shown by its parent before the caster's own
visual.
Members
new
fn new(caster: &Rc<CompositionVisual>, recipe: &DropShadowRecipe) -> ThemeShadowVisual
Creates the shadow visual of caster (the composition visual of the
caster): its transform is taken in the space of the caster
(ParentForTransform), its opacity follows the caster's through an
expression (as UpdateDropShadowVisualOpacity does for an animated
opacity), and it is not hit-testable.
The handler starts with the shape of recipe, so that the first frame that shows the
visual draws the shadow (a message reaches the handler a frame later).
visual
fn visual(self: &Self) -> &Rc<CompositionVisual>
The composition visual.
update
fn update(self: &Self, recipe: &DropShadowRecipe, size: Vector, visible: bool)
Shows recipe around a caster of size, or nothing when visible is
false or the recipe draws nothing.
box_shadows
fn box_shadows(self: &Self) -> Vec<BoxShadow>
The box shadows the visual draws (for tests).
dispose
fn dispose(self: &Self)
Releases the visual.
Trait implementations
SendSyncFreezeUnsafeUnpinUnpinUnwindSafeRefUnwindSafeClassDefaultsBorrow<T>BorrowMut<T>Into<U>From<T>TryInto<U>TryFrom<U>AnyErasedDestructorIntoEither
Availability
Extracted for aarch64-apple-darwin. Cargo features are listed in the crate index.