![]() ![]() Optionally, you can also specify an View.OnClickListener, an TextInputLayout.OnEditTextAttachedListener and an TextInputLayout.OnEndIconChangedListener. You should specify a drawable and content description for the icon. Showing a custom icon specified via setEndIconMode(int) API and related attribute. If set, a button is displayed when text is present and clicking it clears the EditText field. Ĭlearing text functionality via setEndIconMode(int) API and related attribute.If set, a button is displayed to toggle between the password being displayed as plain-text or disguised, when your EditText is set to display a password. Password visibility toggling via setEndIconMode(int) API and related attribute. Showing a character counter via setCounterEnabled(boolean) and setCounterMaxLength(int) Showing suffix text via setSuffixText(CharSequence) Showing prefix text via setPrefixText(CharSequence) Showing placeholder text via setPlaceholderText(CharSequence) Showing helper text via setHelperTextEnabled(boolean) and setHelperText(CharSequence) Showing an error via setErrorEnabled(boolean) and [setError(CharSequence), along with showing an error icon via setErrorIconDrawable(Drawable) TextInputLayout is a layout that wraps a TextInputEditText, EditText, or descendant to show a floating label when the hint is hidden while the user inputs text. Using it allows us to display a hint in the IME when in ‘extract’ mode and provides accessibility support for TextInputLayout. TextInputEditText is a special sub-class of EditText designed for use as a child of TextInputLayout. This is an android TextInputEditText tutorial and example. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |