java.lang.Object | ||
↳ | android.graphics.drawable.Drawable | |
↳ | com.facebook.drawee.drawable.RoundedDrawable |
![]() |
Fields | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
protected int | mBorderColor | ||||||||||
protected final Path | mBorderPath | ||||||||||
protected float | mBorderWidth | ||||||||||
protected boolean | mIsCircle | ||||||||||
protected boolean | mIsShaderTransformDirty | ||||||||||
protected final Path | mPath | ||||||||||
protected boolean | mRadiiNonZero |
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
void | clearColorFilter() | ||||||||||
void | draw(Canvas canvas) | ||||||||||
int | getAlpha() | ||||||||||
int |
getBorderColor()
Gets the border color.
| ||||||||||
float |
getBorderWidth()
Gets the border width.
| ||||||||||
ColorFilter | getColorFilter() | ||||||||||
int | getIntrinsicHeight() | ||||||||||
int | getIntrinsicWidth() | ||||||||||
int | getOpacity() | ||||||||||
float |
getPadding()
Gets the padding.
| ||||||||||
float[] |
getRadii()
Gets the radii.
| ||||||||||
boolean |
getScaleDownInsideBorders()
Gets whether image should be scaled down inside borders.
| ||||||||||
boolean |
isCircle()
Returns whether or not this drawable rounds as circle.
| ||||||||||
void | setAlpha(int alpha) | ||||||||||
void |
setBorder(int color, float width)
Sets the border
| ||||||||||
void |
setCircle(boolean isCircle)
Sets whether to round as circle.
| ||||||||||
void | setColorFilter(ColorFilter colorFilter) | ||||||||||
void | setColorFilter(int color, PorterDuff.Mode mode) | ||||||||||
void |
setPadding(float padding)
Sets the padding for the bitmap.
| ||||||||||
void |
setRadii(float[] radii)
Specify radii for each of the 4 corners.
| ||||||||||
void |
setRadius(float radius)
Specify radius for the corners of the rectangle.
| ||||||||||
void |
setScaleDownInsideBorders(boolean scaleDownInsideBorders)
Sets whether image should be scaled down inside borders.
| ||||||||||
void |
setTransformCallback(TransformCallback transformCallback)
TransformAwareDrawable method
|
Protected Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
void | onBoundsChange(Rect bounds) | ||||||||||
void | updatePath() | ||||||||||
void | updateTransform() |
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
![]() | |||||||||||
![]() | |||||||||||
![]() | |||||||||||
![]() |
Gets the border color.
Gets the border width.
Gets the padding.
Gets the radii.
Gets whether image should be scaled down inside borders.
Returns whether or not this drawable rounds as circle.
Sets the border
color | of the border |
---|---|
width | of the border |
Sets whether to round as circle.
isCircle | whether or not to round as circle |
---|
Sets the padding for the bitmap.
Specify radii for each of the 4 corners. For each corner, the array contains 2 values, [X_radius, Y_radius]. The corners are ordered top-left, top-right, bottom-right, bottom-left
radii | the x and y radii of the corners |
---|
Specify radius for the corners of the rectangle. If this is > 0, then the drawable is drawn in a round-rectangle, rather than a rectangle.
radius | the radius for the corners of the rectangle |
---|
Sets whether image should be scaled down inside borders.
TransformAwareDrawable method
transformCallback | the transform callback to be set |
---|