FerroUI/ docs

Search guides, controls, Rust APIs, and XAML.

    GitHub ↗

    IEffect

    trait · ferroui-base · v0.5.0

    trait IEffect: 'static
    

    A bitmap effect.

    Implemented by the immutable effect types and, through an adapter, by every class deriving from Effect: a handle of such a class converts to Rc<dyn IEffect> with into(). The as_* members replace interface casts (effect as IBlurEffect).

    View source

    Members

    as_any

    fn as_any(self: &Self) -> &dyn Any
    

    The implementing value, for downcasts to immutable effect types. For mutable effects use as_object.

    Source

    as_object

    fn as_object(self: &Self) -> Option<&FerroObject>
    

    The object behind the effect when it is a mutable Effect.

    Source

    as_blur_effect

    fn as_blur_effect(self: &Self) -> Option<&dyn IBlurEffect>
    

    The effect viewed as IBlurEffect, when it is one.

    Source

    as_drop_shadow_effect

    fn as_drop_shadow_effect(self: &Self) -> Option<&dyn IDropShadowEffect>
    

    The effect viewed as IDropShadowEffect, when it is one.

    Source

    as_direction_drop_shadow_effect

    fn as_direction_drop_shadow_effect(self: &Self) -> Option<&dyn IDirectionDropShadowEffect>
    

    The effect viewed as IDirectionDropShadowEffect, when it is one.

    Source

    as_mutable_effect

    fn as_mutable_effect(self: &Self) -> Option<&dyn IMutableEffect>
    

    The effect viewed as IMutableEffect, when it is one.

    Source

    as_custom_effect

    fn as_custom_effect(self: &Self) -> Option<&ImmutableCustomEffect>
    

    The effect as the snapshot of a custom effect, when it is one (#455, not from upstream). A mutable custom effect class is not one; its snapshot is EffectExtensions::to_custom_effect.

    Source

    as_immutable_effect

    fn as_immutable_effect(self: &Self) -> Option<&dyn IImmutableEffect>
    

    The effect viewed as IImmutableEffect, when it is one.

    Source

    into_immutable_effect

    fn into_immutable_effect(self: Rc<Self>) -> Option<std::sync::Arc<dyn IImmutableEffect>>
    

    The effect as an IImmutableEffect handle, when it is immutable: a copy in a handle that can be shared with the render thread (immutable effects are values and compare structurally).

    Source

    Trait implementations

    Availability

    Extracted for aarch64-apple-darwin. Cargo features are listed in the crate index.