FerroUI/ docs

Search guides, controls, Rust APIs, and XAML.

    GitHub ↗

    ItemSelectionEventTriggers

    struct · ferroui-controls · v0.5.0

    struct ItemSelectionEventTriggers
    

    Defines standard logic for selecting items via user input. Behaviour differs between input devices.

    View source

    Members

    should_trigger_selection

    fn should_trigger_selection(selectable: &Visual, event_args: &PointerEventArgs) -> bool
    

    Analyses an input event received by a selectable element, and determines whether the action should trigger selection on press, on release, or not at all.

    selectable is the selectable element which is processing the event.

    This method expects to analyse pointer pressed and pointer released events.

    Source

    should_trigger_selection_key

    fn should_trigger_selection_key(selectable: &Visual, event_args: &KeyEventArgs) -> bool
    

    Analyses an input event received by a selectable element, and determines whether the action should trigger selection.

    This method expects to analyse key down events.

    Source

    has_range_selection_modifier

    fn has_range_selection_modifier(selectable: &Visual, event_args: &dyn IRoutedEventArgs) -> bool
    

    Whether event_args should trigger range selection.

    Source

    has_toggle_selection_modifier

    fn has_toggle_selection_modifier(selectable: &Visual, event_args: &dyn IRoutedEventArgs) -> bool
    

    Whether event_args should trigger toggle selection.

    Source

    Trait implementations

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

    Availability

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