EditText Label?

后端 未结 4 1142
礼貌的吻别
礼貌的吻别 2020-12-13 19:23

I want to have some layout a bit like this

[text tabel][edittext]

i cant find an attribute like html esque label. It seems to be the case t

4条回答
  •  没有蜡笔的小新
    2020-12-13 19:54

    TextInputLayout is the answer. Just use the correct version from the android material library: https://developer.android.com/reference/com/google/android/material/textfield/TextInputLayout

    The android:hint param will display the label in the text area, and when you click on it label will be moved above the text field.

    
    
            
    
    
    

提交回复
热议问题