Problem: My emulator date input type has a forward slash and numbers (/), my device does not?
I'm not sure what to try on this, except I had to create a workaround which involved using a text field with an `android:digits="0123456789/" constraint. Any thoughts on the reason why?
The physical device is a Samsung A32 5G it has numbers only and no '/' and the emulator does.
... was this ...
android:inputType="date"
... now this ...
android:inputType="text"
android:digits="@string/allowDateCharacters"
CodePudding user response:
Problem: My emulator date input type has a forward slash and numbers (/), my device does not?
This is not a problem.
There are ~3 billion Android devices in use, across tens of thousands of device models. There are dozens of soft keyboards ("input method editors") that ship pre-installed on those device models, and there are dozens more that those billions of users can install from the Play Store and elsewhere.
What keys a soft keyboard offers for a given android:inputType
is up to the developers of the soft keyboard — it is not up to you or I. Consider
android:inputType
to be a suggestion, not a command.