android:allowUndo
16lz
2021-12-04
Android 在Android 23增加了UndoManager撤销相关的处理,EditText可以使用android:allowUndo来配置是否支持撤销的功能。
当我们的设备连接了实体键盘,可以通过crl+z来撤销输入。(TextView with the default Control-Z undo behavior.)
可以参考[url]http://androidxref.com/8.0.0_r4/xref/development/samples/ApiDemos/src/com/example/android/apis/content/TextUndoActivity.java[/url]
[url]http://androidxref.com/8.0.0_r4/xref/development/samples/ApiDemos/res/layout/text_undo.xml[/url]
EditText的android:allowUndo默认值是true
当我们的设备连接了实体键盘,可以通过crl+z来撤销输入。(TextView with the default Control-Z undo behavior.)
可以参考[url]http://androidxref.com/8.0.0_r4/xref/development/samples/ApiDemos/src/com/example/android/apis/content/TextUndoActivity.java[/url]
[url]http://androidxref.com/8.0.0_r4/xref/development/samples/ApiDemos/res/layout/text_undo.xml[/url]
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
android:textAppearance="?android:attr/textAppearanceMedium"
android:freezesText="true"
android:allowUndo="false">
EditText的android:allowUndo默认值是true
更多相关文章
- Android设置Edittext只能输入字母数字弹出英文键盘
- Android软键盘弹出不影响布局的方法
- android软键盘隐藏总结
- Android隐藏输入法软键盘的注意事项
- Android(安卓)greenDAO 3.2.2简单使用
- 今天学习到了那些东西
- android强制隐藏输入法键盘(亲测可用,欢迎留言)
- android:configChanges名词解析(文档翻译)
- 知识点笔记