EditText 编辑文本控件
<requestFocus/> ?????????? ? ?????獲得焦點(diǎn) ? 顯示光標(biāo)
android:hint ? ??? ?????????????? ?????用戶的輸入提示
android:textColorHint? ??? ? ?????提示字體顏色
android:textCursorDrawable? ? 光標(biāo)圖片
android:inputType????? ?????? ? ?輸入框輸入數(shù)據(jù)類型????????? ? ??textPassword,phone,不同的輸入類型會(huì)彈出不同的鍵盤
android:imeOptions?????????????輸入法右下角顯示的文字? ? ????actionSend,actionSearch等
android:imeActionLabel????? ?橫屏?xí)r,輸入法右邊顯示的按鈕文字?????現(xiàn)實(shí)的字符串,android:imeOptions="flagNoExtractui"?取消顯示右邊的按鈕
setErorr()????????????????????????????? 設(shè)置錯(cuò)誤提示,null時(shí)取消錯(cuò)誤提示
<1>事件
(1)setOnEditorActionListener? ? 輸入法右下角點(diǎn)擊的操作
(2)addTextchangedListener? ??? 輸入內(nèi)容發(fā)生變化時(shí)的操作
??
總結(jié)
以上是生活随笔為你收集整理的EditText 编辑文本控件的全部?jī)?nèi)容,希望文章能夠幫你解決所遇到的問(wèn)題。
- 上一篇: android 之RadioButton
- 下一篇: android 之开关控件的使用