I was wondering, what is the difference among the 2?
<EditText
android:inputType="numberDecimal" />
<EditText
android:numeric="decimal" />
I realize both gives same behavior. They limit the user input to “0123456789.“
So, is there any differences among the 2? Is there any preferable?
All of these attributes are deprecated:
in favor of one attribute:
(Remember deprecated features will disappear someday in a future release, so it is always best to use the supported version.)
For whatever reason their deprecation is not marked in the TextView (or EditText) documentation… However they are properly annotated on the R.attr page and presumably you will see the warnings inside your IDE’s XML compiler (at least in Android’s Eclipse plug-in.)