What's the Android “Extracted Text UI”?

一世执手 提交于 2019-12-05 07:58:27

In landscape mode, by default, the Input Method Editor (IME) gets control of the full screen when editing text. The idea is that there isn't enough room "vertically" on the landscape screen to show anything other than the EditText and the soft keyboard when editing something longer (e.g. an e-mail message).

The UI in question is here: http://developer.android.com/reference/android/inputmethodservice/ExtractEditText.html

When you use that flag in a TextView in your app , it suppresses the creation of an ExtractedTextView at the top of the IME when it is in "full screen" mode. When in "full screen" mode, the keyboard (the IME) is allowed to fill the screen and cover the app's TextView which the user is trying to edit. If it asks for the full screen, it'll be given to it. This ExtractedTextView box shows the same hints appearing in the targeted TextView, and let's the user see their editing progress. That flag tells the IME not to generate the ExtractedTextView which might leave some room at the top of the keyboard to see your original TextView in the app.

The default implementation of an IME (keyboard) goes to full screen mode when in "landscape mode". It's regular size (about 1/3 of the screen height?) in "portrait mode". The ExtractedTextView is generated, by default, for "full screen" mode, unless you suppress it. I suspect that when you see your EditText "balloning", your actually looking at the ExtractedTextView of a "full screen" mode keyboard.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!