setSelection method

void setSelection(
  1. TextSelection value
)

Implementation

void setSelection(TextSelection value) {
  _selection = SelectionState(
    baseOffset: BigInt.from(value.baseOffset.clamp(0, length)),
    extentOffset: BigInt.from(value.extentOffset.clamp(0, length)),
  );
}