getVisibleColumnStartIndex method

int? getVisibleColumnStartIndex(
  1. RowRegion rowRegion
)

Retrieves the start index of visible column based on the specified row region.

Returns null if there are no rows available in the given region.

Implementation

int? getVisibleColumnStartIndex(RowRegion rowRegion) {
  if (_dataGridStateDetails != null) {
    final DataGridConfiguration dataGridConfiguration =
        _dataGridStateDetails!();
    final ScrollAxisRegion scrollAxisRegion = _getScrollAxisRegion(rowRegion);
    return dataGridConfiguration.container.scrollColumns
        .getVisibleLinesRange(scrollAxisRegion)
        ?.start;
  }
  return null;
}