ChartSpatialIndex class

A spatial index specifically designed for chart hit testing.

Constructors

ChartSpatialIndex({required Rect bounds})

Properties

hashCode int
The hash code for this object.
no setterinherited
length int
Number of registered items.
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

clear() → void
Clears the index.
findNearest(Offset point, {double maxDistance = 50.0}) HitTestInfo?
Finds the nearest data point.
hitTest(Offset point) HitTestInfo?
Finds the hit info at a point.
hitTestRadius(Offset point, double radius) List<HitTestInfo>
Finds all hits within a distance.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
registerDataPoint<T>({required T item, required Rect bounds, required int dataIndex, int? seriesIndex}) → void
Registers a hit region for a data point.
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited