FerroUI/ docs

Search guides, controls, Rust APIs, and XAML.

    GitHub ↗

    CompositionEffectFactory

    struct · ferroui-base · v0.5.0

    struct CompositionEffectFactory
    

    Creates the brushes of one effect graph (WinUI Microsoft.UI.Composition.CompositionEffectFactory), made by Compositor::create_effect_factory.

    The graph is checked when the factory is made: load_status is Success when the brushes can draw it. A factory whose effect cannot be loaded still makes brushes, which draw nothing.

    Deviation (winui-composition.md): WinUI throws from CreateEffectFactory for an effect it cannot load; here the factory is made and reports the failure through its load status and extended error. The factory is not a composition object (no Properties, no animations).

    View source

    Members

    compositor

    fn compositor(self: &Self) -> &Rc<Compositor>
    

    The compositor of the factory.

    Source

    create_brush

    fn create_brush(self: &Self) -> CompositionEffectBrush
    

    CreateBrush: a brush that draws the effect. Its source parameters are bound with set_source_parameter; its animatable properties are entries of its Properties, set to the values of the description.

    Source

    load_status

    fn load_status(self: &Self) -> CompositionEffectFactoryLoadStatus
    

    LoadStatus: whether the effect was loaded.

    Source

    extended_error

    fn extended_error(self: &Self) -> Option<&CompositionEffectFactoryError>
    

    ExtendedError: why the effect was not loaded; None when it was.

    Source

    Trait implementations

    • Send
    • Sync
    • Freeze
    • UnsafeUnpin
    • Unpin
    • UnwindSafe
    • RefUnwindSafe
    • ClassDefaults
    • Borrow<T>
    • BorrowMut<T>
    • Into<U>
    • From<T>
    • TryInto<U>
    • TryFrom<U>
    • Any
    • ErasedDestructor
    • IntoEither

    Availability

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