I want to create a layout for an Android app that has a numeric keypad and takes four digits to determine if it matches a preset passcode value.
I have seen a few applications use this, so I would have thought that it was a high level widget of some description.
The only thing I can find that’s remotely close to what I want is this:
<EditText
android:id="@+id/editText1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1"
android:ems="10"
android:inputType="numberPassword" >
<requestFocus />
</EditText>
But this isn’t really what I’m looking for.
Any input would be awesome and thanks in advance.
EDIT: Here’s an image of the iOS dropbox app start screen that I’d like:

In the end I created multiple custom widgets.
There is a Keypad widget. It inherits from
TableLayoutand has four rows of three buttons. Each button modifies a String – either adding digits or removing them.Another widget I added was called PINEntry. It takes a single int to specify how many digits have been entered and displays that information accordingly.
I use these two widgets together in another View to recreate the passcode screen.