pub struct HitRegion {
pub node_id: usize,
pub capture_path: Vec<usize>,
pub rect: Rect,
pub quad: [[f32; 2]; 4],
pub local_bounds: Rect,
pub world_to_local: ProjectiveTransform,
pub shape: Option<RoundedCornerShape>,
pub handlers: Rc<ModifierNodeSlices>,
pub z_index: usize,
pub hit_clip_bounds: Option<Rect>,
pub hit_clips: Vec<HitClip>,
/* private fields */
}Expand description
A hit target in window space: the node’s geometry, clips and pointer handlers.
Fields§
§node_id: usizeThe layout node that owns the target.
capture_path: Vec<usize>Nodes that keep receiving the move, up and cancel events of a gesture that starts here: this node first, then its pointer-input ancestors from the nearest outward.
rect: RectAxis-aligned bounds of quad in window coordinates.
quad: [[f32; 2]; 4]The node’s rectangle after the layer transforms, as four corners in window space.
local_bounds: RectThe node’s own rectangle in its local space.
world_to_local: ProjectiveTransformMaps window coordinates into the node’s local space.
shape: Option<RoundedCornerShape>Rounded shape that narrows the target’s rectangle, or None for a plain rectangle.
handlers: Rc<ModifierNodeSlices>The node’s modifier slices, shared with the render graph: its pointer handlers and pointer icon.
z_index: usizeDraw order of the target. A larger value is drawn later and is hit first.
hit_clip_bounds: Option<Rect>Axis-aligned bounds of the ancestors’ clips in window space, or None when none clips.
hit_clips: Vec<HitClip>Clips of the ancestors that cut this target, as transformed quads in window space.