How to remove the underline from the EditText field in Android?

后端 未结 10 1159
心在旅途
心在旅途 2020-12-14 14:47

Whenever a word is typed in the EditText box, I always see an underline under the word being typed. But when I press a space after that word I no longer see the underline.

10条回答
  •  长情又很酷
    2020-12-14 15:01

    There is a function that removes any composing state. I think if you call it after every time a user types, you will not see the underline. I use it after the user finishes typing, to get the drawing cache of the entire textView (which I need without underline). It's

    someTextView.clearComposingText();
    

提交回复
热议问题