Updated EditableText scroll into view behavior
Summary
#The Editable.onCaretChanged
callback is removed. With this change, EditableText
behavior for scrolling the selection into view changes.
Context
#Previously, upon scrolling into view to show user updates, EditableText
used multiple mechanisms to determine the extent of the selection or the caret location.
Description of change
#By removing the Editable.onCaretChanged
callback, EditableText
will always use the most up-to-date selection extent location when scrolling to show it. Specifically, this improves scroll into view behavior after changing selection from collapsed to non-collapsed using userUpdateTextEditingValue()
.
Timeline
#Landed in version: 3.12.0-4.0.pre
In stable release: 3.13.0
References
#API documentation:
Relevant PRs:
除非另有说明,否则本网站上的文档反映的是 Flutter 的最新稳定版本。页面最后更新于 2025-01-30。 查看源代码 或 报告问题。