FerroUI/ docs

Search guides, controls, Rust APIs, and XAML.

    GitHub ↗

    IContentPresenterHost

    trait · ferroui-controls · v0.5.0

    trait IContentPresenterHost
    

    Represents a control which hosts a content presenter.

    This interface is implemented by ContentControl and is used as follows:

    • register_content_presenter is called by a content presenter when its templated parent changes; the host decides whether the presenter is the one that displays its content.
    • The presenter of a host adds the control it creates to the logical children of the host rather than to its own.

    A class implementing the trait is made known with register_content_presenter_host, normally from its class initialization.

    View source

    Members

    logical_children

    fn logical_children(self: &Self) -> &FerroList<Ref<StyledElement>>
    

    The logical children of the host control.

    Source

    register_content_presenter

    fn register_content_presenter(self: &Self, presenter: &ContentPresenter) -> bool
    

    Registers a content presenter with the host. Returns true if the presenter was registered as the host's presenter.

    Source

    Trait implementations

    Availability

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