java.lang.Object | |
↳ | android.support.v4.widget.TextViewCompat |
Helper for accessing features in TextView
introduced after API level
4 in a backwards compatible fashion.
XML Attributes | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
android:drawableBottom | setCompoundDrawablesRelativeWithIntrinsicBounds(TextView,int,int,int,int) | The drawable to be drawn below the text. | |||||||||
android:drawableEnd | setCompoundDrawablesRelativeWithIntrinsicBounds(TextView,int,int,int,int) | The drawable to be drawn to the end of the text. | |||||||||
android:drawableStart | setCompoundDrawablesRelativeWithIntrinsicBounds(TextView,int,int,int,int) | The drawable to be drawn to the start of the text. | |||||||||
android:drawableTop | setCompoundDrawablesRelativeWithIntrinsicBounds(TextView,int,int,int,int) | The drawable to be drawn above the text. |
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Sets the Drawables (if any) to appear to the start of, above, to the end
of, and below the text.
| |||||||||||
Sets the Drawables (if any) to appear to the start of, above, to the end
of, and below the text.
| |||||||||||
Sets the Drawables (if any) to appear to the start of, above, to the end
of, and below the text.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
|
The drawable to be drawn below the text.
May be a reference to another resource, in the form "@[+][package:]type:name
"
or to a theme attribute in the form "?[package:][type:]name
".
May be a color value, in the form of "#rgb
", "#argb
",
"#rrggbb
", or "#aarrggbb
".
This corresponds to the global attribute
resource symbol drawableBottom
.
The drawable to be drawn to the end of the text.
May be a reference to another resource, in the form "@[+][package:]type:name
"
or to a theme attribute in the form "?[package:][type:]name
".
May be a color value, in the form of "#rgb
", "#argb
",
"#rrggbb
", or "#aarrggbb
".
This corresponds to the global attribute
resource symbol drawableEnd
.
The drawable to be drawn to the start of the text.
May be a reference to another resource, in the form "@[+][package:]type:name
"
or to a theme attribute in the form "?[package:][type:]name
".
May be a color value, in the form of "#rgb
", "#argb
",
"#rrggbb
", or "#aarrggbb
".
This corresponds to the global attribute
resource symbol drawableStart
.
The drawable to be drawn above the text.
May be a reference to another resource, in the form "@[+][package:]type:name
"
or to a theme attribute in the form "?[package:][type:]name
".
May be a color value, in the form of "#rgb
", "#argb
",
"#rrggbb
", or "#aarrggbb
".
This corresponds to the global attribute
resource symbol drawableTop
.
Sets the Drawables (if any) to appear to the start of, above, to the end
of, and below the text. Use null
if you do not want a Drawable
there. The Drawables must already have had setBounds(Rect)
called.
setCompoundDrawables(Drawable, Drawable, Drawable, Drawable)
or related methods.textView | The TextView against which to invoke the method. |
---|
Sets the Drawables (if any) to appear to the start of, above, to the end
of, and below the text. Use null
if you do not want a Drawable
there. The Drawables' bounds will be set to their intrinsic bounds.
setCompoundDrawables(Drawable, Drawable, Drawable, Drawable)
or related methods.textView | The TextView against which to invoke the method. |
---|
Sets the Drawables (if any) to appear to the start of, above, to the end of, and below the text. Use 0 if you do not want a Drawable there. The Drawables' bounds will be set to their intrinsic bounds.
Calling this method will overwrite any Drawables previously set usingsetCompoundDrawables(Drawable, Drawable, Drawable, Drawable)
or related methods.textView | The TextView against which to invoke the method. |
---|---|
start | Resource identifier of the start Drawable. |
top | Resource identifier of the top Drawable. |
end | Resource identifier of the end Drawable. |
bottom | Resource identifier of the bottom Drawable. |