public class BadgeDrawable
extends android.graphics.drawable.Drawable
Constructor and Description |
---|
BadgeDrawable(android.content.Context context) |
Modifier and Type | Method and Description |
---|---|
void |
draw(android.graphics.Canvas canvas) |
int |
getOpacity() |
void |
setAlpha(int alpha) |
void |
setColor(java.lang.Integer presenceColor)
Sets the count on a Badge given a count and a presence color.
|
void |
setColorFilter(android.graphics.ColorFilter cf) |
void |
setCount(int count) |
applyTheme, canApplyTheme, clearColorFilter, copyBounds, copyBounds, createFromPath, createFromResourceStream, createFromResourceStream, createFromStream, createFromXml, createFromXml, createFromXmlInner, createFromXmlInner, getAlpha, getBounds, getCallback, getChangingConfigurations, getColorFilter, getConstantState, getCurrent, getDirtyBounds, getHotspotBounds, getIntrinsicHeight, getIntrinsicWidth, getLayoutDirection, getLevel, getMinimumHeight, getMinimumWidth, getOpticalInsets, getOutline, getPadding, getState, getTransparentRegion, inflate, inflate, invalidateSelf, isAutoMirrored, isFilterBitmap, isProjected, isStateful, isVisible, jumpToCurrentState, mutate, onBoundsChange, onLayoutDirectionChanged, onLevelChange, onStateChange, resolveOpacity, scheduleSelf, setAutoMirrored, setBounds, setBounds, setCallback, setChangingConfigurations, setColorFilter, setDither, setFilterBitmap, setHotspot, setHotspotBounds, setLayoutDirection, setLevel, setState, setTint, setTintBlendMode, setTintList, setTintMode, setVisible, unscheduleSelf
public void draw(android.graphics.Canvas canvas)
draw
in class android.graphics.drawable.Drawable
public void setCount(int count)
public void setColor(java.lang.Integer presenceColor)
presenceColor
- the presence color as an integer representation of Color.public void setAlpha(int alpha)
setAlpha
in class android.graphics.drawable.Drawable
public void setColorFilter(android.graphics.ColorFilter cf)
setColorFilter
in class android.graphics.drawable.Drawable
public int getOpacity()
getOpacity
in class android.graphics.drawable.Drawable