android.graphics.drawable
Class BitmapDrawable
java.lang.Object
android.graphics.drawable.Drawable
android.graphics.drawable.BitmapDrawable
public class BitmapDrawable
- extends Drawable
Methods inherited from class android.graphics.drawable.Drawable |
clearColorFilter, copyBounds, copyBounds, createFromPath, createFromResourceStream, createFromResourceStream, createFromStream, createFromXml, createFromXmlInner, getBounds, getCallback, getCurrent, getLevel, getMinimumHeight, getMinimumWidth, getPadding, getState, getTransparentRegion, invalidateSelf, isStateful, isVisible, jumpToCurrentState, onLevelChange, onStateChange, resolveOpacity, scheduleSelf, setBounds, setBounds, setCallback, setChangingConfigurations, setColorFilter, setLevel, setState, setVisible, unscheduleSelf |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
BitmapDrawable
public BitmapDrawable()
BitmapDrawable
public BitmapDrawable(Resources res)
BitmapDrawable
public BitmapDrawable(Bitmap bitmap)
BitmapDrawable
public BitmapDrawable(Resources res,
Bitmap bitmap)
BitmapDrawable
public BitmapDrawable(String filepath)
BitmapDrawable
public BitmapDrawable(Resources res,
String filepath)
BitmapDrawable
public BitmapDrawable(InputStream is)
BitmapDrawable
public BitmapDrawable(Resources res,
InputStream is)
getPaint
public final Paint getPaint()
getBitmap
public final Bitmap getBitmap()
setTargetDensity
public void setTargetDensity(Canvas canvas)
setTargetDensity
public void setTargetDensity(DisplayMetrics metrics)
setTargetDensity
public void setTargetDensity(int density)
getGravity
public int getGravity()
setGravity
public void setGravity(int gravity)
setAntiAlias
public void setAntiAlias(boolean aa)
setFilterBitmap
public void setFilterBitmap(boolean filter)
- Overrides:
setFilterBitmap
in class Drawable
setDither
public void setDither(boolean dither)
- Overrides:
setDither
in class Drawable
getTileModeX
public Shader.TileMode getTileModeX()
getTileModeY
public Shader.TileMode getTileModeY()
setTileModeX
public void setTileModeX(Shader.TileMode mode)
setTileModeY
public final void setTileModeY(Shader.TileMode mode)
setTileModeXY
public void setTileModeXY(Shader.TileMode xmode,
Shader.TileMode ymode)
getChangingConfigurations
public int getChangingConfigurations()
- Overrides:
getChangingConfigurations
in class Drawable
onBoundsChange
protected void onBoundsChange(Rect bounds)
- Overrides:
onBoundsChange
in class Drawable
draw
public void draw(Canvas canvas)
- Specified by:
draw
in class Drawable
setAlpha
public void setAlpha(int alpha)
- Specified by:
setAlpha
in class Drawable
setColorFilter
public void setColorFilter(ColorFilter cf)
- Specified by:
setColorFilter
in class Drawable
mutate
public Drawable mutate()
- Overrides:
mutate
in class Drawable
inflate
public void inflate(Resources r,
org.xmlpull.v1.XmlPullParser parser,
AttributeSet attrs)
throws org.xmlpull.v1.XmlPullParserException,
IOException
- Overrides:
inflate
in class Drawable
- Throws:
org.xmlpull.v1.XmlPullParserException
IOException
getIntrinsicWidth
public int getIntrinsicWidth()
- Overrides:
getIntrinsicWidth
in class Drawable
getIntrinsicHeight
public int getIntrinsicHeight()
- Overrides:
getIntrinsicHeight
in class Drawable
getOpacity
public int getOpacity()
- Specified by:
getOpacity
in class Drawable
getConstantState
public final Drawable.ConstantState getConstantState()
- Overrides:
getConstantState
in class Drawable
Copyright © 2008-2012. All Rights Reserved.