public class SharpDrawable
extends android.graphics.drawable.PictureDrawable
| Constructor and Description |
|---|
SharpDrawable(android.graphics.Picture picture)
Construct a new drawable referencing the specified picture.
|
SharpDrawable(android.view.View view,
android.graphics.Picture picture)
Construct a new drawable referencing the specified picture.
|
| Modifier and Type | Method and Description |
|---|---|
void |
draw(android.graphics.Canvas parentCanvas) |
static void |
prepareView(android.view.View view)
Prepare a view for rendering this SharpDrawable by setting its LayerType to
LAYER_TYPE_SOFTWARE.
|
void |
resetCache() |
void |
setBounds(int left,
int top,
int right,
int bottom) |
void |
setCacheScale(float scale) |
void |
setCaching(boolean caching)
Experimental feature to cache the drawable into a bitmap.
|
getIntrinsicHeight, getIntrinsicWidth, getOpacity, getPicture, setAlpha, setColorFilter, setPictureapplyTheme, canApplyTheme, clearColorFilter, copyBounds, copyBounds, createFromPath, createFromResourceStream, createFromResourceStream, createFromStream, createFromXml, createFromXml, createFromXmlInner, createFromXmlInner, getAlpha, getBounds, getCallback, getChangingConfigurations, getColorFilter, getConstantState, getCurrent, getDirtyBounds, getHotspotBounds, getLayoutDirection, getLevel, getMinimumHeight, getMinimumWidth, getOutline, getPadding, getState, getTransparentRegion, inflate, inflate, invalidateSelf, isAutoMirrored, isFilterBitmap, isStateful, isVisible, jumpToCurrentState, mutate, onBoundsChange, onLayoutDirectionChanged, onLevelChange, onStateChange, resolveOpacity, scheduleSelf, setAutoMirrored, setBounds, setCallback, setChangingConfigurations, setColorFilter, setDither, setFilterBitmap, setHotspot, setHotspotBounds, setLayoutDirection, setLevel, setState, setTint, setTintList, setTintMode, setVisible, unscheduleSelfpublic SharpDrawable(android.graphics.Picture picture)
picture - The picture to associate with the drawable. May be null.public SharpDrawable(android.view.View view,
android.graphics.Picture picture)
view - View that will hold this drawablepicture - The picture to associate with the drawable. May be null.public static void prepareView(android.view.View view)
view - public void draw(android.graphics.Canvas parentCanvas)
draw in class android.graphics.drawable.PictureDrawablepublic void setBounds(int left,
int top,
int right,
int bottom)
setBounds in class android.graphics.drawable.Drawablepublic void setCaching(boolean caching)
resetCache().caching - booleanpublic void setCacheScale(float scale)
public void resetCache()