Expand description
WidgetBuilder trait — blanket-implemented for all Widget types.
Provides attached event handler methods and framework-level properties.
Each method wraps the widget in a WidgetWithHandlers<W> that stores
the handlers and metadata alongside the widget. When the widget is
inserted into the arena, the handler set is extracted and applied to
the WidgetNode.
The four click-style handlers (on_tap / on_double_tap /
on_triple_tap / on_long_press) all receive a borrowed
crate::gesture::TapEvent (position + button + modifiers) and
default to crate::event::ButtonMask::PRIMARY acceptance. Widen
that filter via the matching accept_*_buttons(...) knob — see the
“Event System” section in docs/events-and-gestures.md for the
full contract and examples.
Structs§
- Accessibility
Overrides - Builder-level accessibility overrides.
- Handler
Set - Temporary storage for handlers and metadata accumulated via builder
methods. Transferred to the
WidgetNodeduring arena insertion. - Widget
With Handlers - A widget wrapped with attached event handlers and framework metadata.
Created by calling builder methods from
WidgetBuilderon any widget.
Enums§
- Access
Subtree Mode - Subtree visibility / merge mode applied by the accessibility tree walker.
Traits§
- Widget
Builder - Blanket trait providing attached handler methods for all Widget types.
The first builder method call wraps the widget in
WidgetWithHandlers.
Type Aliases§
- Context
Menu Factory - Type alias for a context-menu content factory.