updateSelection method
Updates the selection endpoint to (col, row).
Implementation
void updateSelection(int col, int row, {SelectionMode? mode}) {
if (_anchor == null) return;
final modeChanged = mode != null && _mode != mode;
if (modeChanged) {
_mode = mode;
}
final newFocus = _clampPoint(col, row, _region);
if (_focus == newFocus && !modeChanged) return;
_focus = newFocus;
notifyListeners();
}