public class PaintDrawable extends ShapeDrawable
ShapeDrawable.ShaderFactory
Drawable.Callback, Drawable.ConstantState
Constructor and Description |
---|
PaintDrawable() |
PaintDrawable(int color) |
Modifier and Type | Method and Description |
---|---|
protected boolean |
inflateTag(String name,
Resources r,
XmlPullParser parser,
AttributeSet attrs)
Subclasses override this to parse custom subelements.
|
void |
setCornerRadii(float[] radii)
Specify radii for each of the 4 corners.
|
void |
setCornerRadius(float radius)
Specify radius for the corners of the rectangle.
|
applyTheme, clearMutated, draw, getAlpha, getChangingConfigurations, getConstantState, getIntrinsicHeight, getIntrinsicWidth, getOpacity, getOutline, getPadding, getPaint, getShaderFactory, getShape, inflate, isStateful, mutate, onBoundsChange, onDraw, onStateChange, setAlpha, setColorFilter, setDither, setIntrinsicHeight, setIntrinsicWidth, setPadding, setPadding, setShaderFactory, setShape, setTintList, setTintMode
canApplyTheme, clearColorFilter, copyBounds, copyBounds, createFromPath, createFromResourceStream, createFromResourceStream, createFromStream, createFromXml, createFromXml, createFromXmlInner, createFromXmlInner, getBounds, getCallback, getColorFilter, getCurrent, getDirtyBounds, getHotspotBounds, getLayoutDirection, getLevel, getMinimumHeight, getMinimumWidth, getOpticalInsets, getState, getTransparentRegion, inflate, invalidateSelf, isAutoMirrored, isFilterBitmap, isProjected, isVisible, jumpToCurrentState, obtainAttributes, onLayoutDirectionChanged, onLevelChange, parseTintMode, resolveOpacity, scheduleSelf, setAutoMirrored, setBounds, setBounds, setCallback, setChangingConfigurations, setColorFilter, setFilterBitmap, setHotspot, setHotspotBounds, setLayoutDirection, setLevel, setState, setTint, setVisible, setXfermode, unscheduleSelf
public PaintDrawable()
public PaintDrawable(int color)
public void setCornerRadius(float radius)
radius
- the radius for the corners of the rectanglepublic void setCornerRadii(float[] radii)
radii
- the x and y radii of the cornersprotected boolean inflateTag(String name, Resources r, XmlPullParser parser, AttributeSet attrs)
ShapeDrawable
inflateTag
in class ShapeDrawable