FerroUI/ docs

Search guides, controls, Rust APIs, and XAML.

    GitHub ↗

    IRootProvider

    trait · ferroui-controls · v0.5.0

    trait IRootProvider
    

    Exposes methods and properties to support UI Automation client access to the root of an automation tree.

    This contract is implemented by automation peers, and should only be implemented on true root elements, such as windows. To embed an automation tree, use IEmbeddedRootProvider instead.

    Private API: for use by the platform backends.

    View source

    Members

    peer

    fn peer(self: &Self) -> Ref<AutomationPeer>
    

    The automation peer that provides this contract.

    Source

    get_focus

    fn get_focus(self: &Self) -> Option<Ref<AutomationPeer>>
    

    Gets the currently focused element.

    Windows: IRawElementProviderFragmentRoot.GetFocus. macOS: UIAccessibility.accessibilityFocusedUIElement.

    Source

    get_peer_from_point

    fn get_peer_from_point(self: &Self, p: Point) -> Option<Ref<AutomationPeer>>
    

    Gets the element at the specified point, expressed in top-level coordinates.

    Windows: IRawElementProviderFragmentRoot.ElementProviderFromPoint. macOS: NSAccessibilityProtocol.accessibilityHitTest.

    Source

    focus_changed

    fn focus_changed(self: &Self, handler: Rc<dyn Fn() -> ()>) -> Rc<dyn IDisposable>
    

    Raised by the automation peer when the focus changes.

    Windows: IRawElementProviderAdviseEvents (focus changed). macOS: NSAccessibilityFocusedUIElementChangedNotification.

    Source

    Trait implementations

    Availability

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