FerroUI/ docs

Search guides, controls, Rust APIs, and XAML.

    GitHub ↗

    FerroObjectBehaviorsExtensions

    trait · ferroui-xaml-interactivity · v0.5.0

    trait FerroObjectBehaviorsExtensions
    

    Surfaces Interaction::behaviors_property directly on FerroObject: the static members FerroObject::behaviors_property(), FerroObject::get_behaviors(..) and FerroObject::set_behaviors(..) when this trait is in scope.

    The first use of the members adds the root object class as an owner of the attached property (the static constructor of the reference), so that markup can name it with the inherited syntax of a property element (<Border.Behaviors>).

    Deviation (DEVIATIONS.md, Behaviors): the reference declares the members as extension members of the object class (extension(FerroObject)); a Rust trait implemented for the root class gives the same calls.

    View source

    Members

    behaviors_property

    fn behaviors_property() -> &'static AttachedProperty<Option<BehaviorCollection>>
    

    Exposes the behaviors attached property for consumers targeting FerroObject.

    Source

    get_behaviors

    fn get_behaviors(obj: &FerroObject) -> BehaviorCollection
    

    Delegates to Interaction::get_behaviors.

    Source

    set_behaviors

    fn set_behaviors(obj: &FerroObject, value: Option<BehaviorCollection>)
    

    Delegates to Interaction::set_behaviors.

    Source

    Trait implementations

    Availability

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