void setEditingState(TextEditingState state)

Requests that the text input control change its internal state to match the given state.

Source

void setEditingState(TextEditingState state) {
  assert(attached);
  PlatformMessages.invokeMethod(
    _kChannelName,
    'TextInput.setEditingState',
    <dynamic>[ state.toJSON() ],
  );
}