setText method
void
setText(
- dynamic text
设置文字
跟直接调用.text来设置文字的区别是会自动把光标移动到最后
Implementation
void setText(dynamic text) {
this.text = text.toString();
selection = TextSelection.collapsed(offset: this.text.length);
}