dataPointIndex method

int dataPointIndex(
  1. Offset position,
  2. ChartSegment segment
)

Implementation

int dataPointIndex(Offset position, ChartSegment segment) {
  int pointIndex = segment.currentSegmentIndex;
  if (_xNullPointIndexes.isNotEmpty) {
    for (final int xNullPointIndex in _xNullPointIndexes) {
      if (pointIndex >= xNullPointIndex) {
        pointIndex++;
      }
    }
  }
  return pointIndex;
}