Showing a button that when clicked displays a dropdown menu.'start/left' compound drawable of the EditText will be overridden. Setting a start/left compound drawable on the EditText. Note: Use the setStartIconDrawable(Drawable) API in place of You should specify a content description for the icon. Showing a start icon via setStartIconDrawable(Drawable) API and related attribute.(start/end), as opposed to absolutely (left/right). To ensure that any existingĭrawables are restored correctly, you should set those compound drawables relatively Note: When using an end icon, the 'end' compound drawable of theĮditText will be overridden while the end icon view is visible. Optionally, you canĪlso 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.Set, a button is displayed when text is present and clicking it clears the EditText field. Clearing text functionality via setEndIconMode(int) API and related attribute.Set, a button is displayed to toggle between the password being displayed as plain-text orĭisguised, 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),Īlong with showing an error icon via setErrorIconDrawable(Drawable).Show a floating label when the hint is hidden while the user inputs text. Layout which wraps a TextInputEditText, EditText, or descendant to
0 Comments
Leave a Reply. |