Configure android EditText to allow decimals and negatives

后端 未结 3 1887
夕颜
夕颜 2021-02-11 14:52

I have an Android EditText that I want to have the number keyboard come up.

If I set the android:inputType to numberSigned, I get the number keyboard and t

3条回答
  •  爱一瞬间的悲伤
    2021-02-11 15:40

    See this link may be it's help you http://developer.android.com/resources/articles/creating-input-method.html

    and The possible values for the android:inputtype are:

    •none
    •text
    •textCapCharacters
    •textCapWords
    •textCapSentences
    •textAutoCorrect
    •textAutoComplete
    •textMultiLine
    •textImeMultiLine
    •textNoSuggestions
    •textUri
    •textEmailAddress
    •textEmailSubject
    •textShortMessage
    •textLongMessage
    •textPersonName
    •textPostalAddress
    •textPassword
    •textVisiblePassword
    •textWebEditText
    •textFilter
    •textPhonetic
    •textWebEmailAddress
    •textWebPassword
    •number
    •numberSigned
    •numberDecimal
    •numberPassword
    •phone
    •datetime
    •date
    •time
    

提交回复
热议问题