是否有Android标准徽章或方法来显示带有Google示例的计数的操作栏通知图标?

如果没有,那么最好的方法是什么呢?
我是android的新手,请帮忙.
notifications icons android actionbarsherlock android-actionbar
我想要这样的东西:

第3个图标用于通知,现在只是一个png图像.是否可以做某事,以便我可以改编文本/数字,即...,03以编程方式显示实际的通知号码.
谢谢
我试图在Android中掌握2D图形.作为一个例子,我想实现一个自定义drawable并在我的Activity中显示它
我通过扩展Android drawable来定义一个自定义的drawable,如下所述
class myDrawable extends Drawable {
private static final String TAG = myDrawable.class.getSimpleName();
private ColorFilter cf;
@Override
public void draw(Canvas canvas) {
//First you define a colour for the outline of your rectangle
Paint rectanglePaint = new Paint();
rectanglePaint.setARGB(255, 255, 0, 0);
rectanglePaint.setStrokeWidth(2);
rectanglePaint.setStyle(Style.FILL);
//Then create yourself a Rectangle
RectF rectangle = new RectF(15.0f, 50.0f, 55.0f, 75.0f); //in pixels
Log.d(TAG,"On Draw method");
// TODO Auto-generated method stub
Paint paintHandl = new Paint();
// paintHandl.setColor(0xaabbcc);
paintHandl.setARGB(125, 234, 213, 34 …Run Code Online (Sandbox Code Playgroud) 在这些代码上生成错误: setBadgeCount(this,icon ,"0");
这是我的代码:
MenuItem itemCart = menu.findItem(R.id.action_cart);
LayerDrawable icon = (LayerDrawable) itemCart.getIcon();
// Update LayerDrawable's BadgeDrawable
setBadgeCount(this,icon ,"0");
Run Code Online (Sandbox Code Playgroud)