Code examples for ShapeDrawable

Codota analyzed 7,668,838 open source code samples to find the most common, credible and clear examples.
You can now enable Codota on your own code to easily search and navigate your Java codebase.
59:	ShapeDrawable shape = new ShapeDrawable(new RectShape()); 
60:	shape.setIntrinsicHeight(height); 
61:	shape.setIntrinsicWidth(width); 
62:	shape.getPaint().setColor(color); 
Full Snippet Info
8
CodeRank
107:	ShapeDrawable drawable = new ShapeDrawable(circle); 
108:	ShapeHolder shapeHolder = new ShapeHolder(drawable); 
-
115:	Paint paint = drawable.getPaint(); //new Paint(Paint.ANTI_ALIAS_FLAG); 
Full Snippet Info
8
CodeRank
16:	ShapeDrawable shapeDrawable = new ShapeDrawable(); 
17:	Paint paint = shapeDrawable.getPaint(); 
-
19:	assertThat(shapeDrawable.getPaint()).isSameAs(paint); 
Full Snippet Info
7
CodeRank
328:	ShapeDrawable drawable = new ShapeDrawable(rr); 
329:	drawable.getPaint().setColor(badgeColor); 
Full Snippet Info
7
CodeRank
109:	ShapeDrawable drawable = new ShapeDrawable(circle); 
110:	ShapeHolder shapeHolder = new ShapeHolder(drawable); 
-
117:	Paint paint = drawable.getPaint(); //new Paint(Paint.ANTI_ALIAS_FLAG); 
Full Snippet Info
7
CodeRank
52:	myShapeDrawable = new ShapeDrawable(shape); 
53:	myShapeDrawable.getPaint().set(paint); 
54:	myShapeDrawable.setBounds(125, 225, 275, 375); 
-
61:	ObjectAnimator a = ObjectAnimator.ofInt(myShapeDrawable, "alpha", 0, 100); 
Full Snippet Info
7
CodeRank
41:	ShapeDrawable rectangle = new ShapeDrawable (); 
42:	rectangle.setShape(new RectShape()); 
43:	rectangle.setIntrinsicHeight(100); 
44:	rectangle.setIntrinsicWidth(200); 
45:	rectangle.getPaint().setColor(Color.GREEN); 
Full Snippet Info
7
CodeRank
61:	ShapeDrawable shapeDrawable = new ShapeDrawable(new OvalShape()); 
62:	Paint paint = shapeDrawable.getPaint(); 
-
64:	shapeDrawable.setBounds(0, 0, bitmap.getWidth(), bitmap.getHeight()); 
65:	shapeDrawable.draw(canvas); 
66:	shapeDrawable.setShape(new ArcShape(60, 240)); 
67:	shapeDrawable.setBounds(0, 160, 200, 310); 
68:	shapeDrawable.draw(canvas); 
Full Snippet Info
7
CodeRank
328:	ShapeDrawable drawable = new ShapeDrawable(rr); 
329:	drawable.getPaint().setColor(badgeColor); 
Full Snippet Info
7
CodeRank
112:	mPreviousBoxBackground.getPaint().setShader(getPreviewBackground(mPreviousColor, mPreviousBoxBackground.getBounds())); 
-
114:	mPreviousBoxBackground.invalidateSelf(); 
Full Snippet Info
6
CodeRank
53:	drawable = new ShapeDrawable(shape); 
54:	drawable.getPaint().set(paint); 
55:	drawable.setBounds(125, 225, 275, 375); 
Full Snippet Info
6
CodeRank
252:	mTabDrawable.setBounds(viewLeft - mTabPadding, 
-
256:	mTabDrawable.setAlpha(alpha); 
Full Snippet Info
6
CodeRank
105:	ShapeDrawable drawable = new ShapeDrawable(circle); 
-
113:	Paint paint = drawable.getPaint(); //new Paint(Paint.ANTI_ALIAS_FLAG); 
Full Snippet Info
7
CodeRank
52:	myShapeDrawable = new ShapeDrawable(shape); 
53:	myShapeDrawable.getPaint().set(paint); 
54:	myShapeDrawable.setBounds(125, 225, 275, 375); 
Full Snippet Info
6
CodeRank
31:	ShapeDrawable mDrawable = new ShapeDrawable(new OvalShape()); 
32:	Paint paint = mDrawable.getPaint(); 
-
36:	mDrawable.setBounds((int)(x-xradius), (int)(y-yradius), (int)(x + xradius*2.0d), (int)(y + yradius*2.0d)); 
-
38:	mDrawable.draw(canvas);	//draws mDrawable to canvas 
Full Snippet Info
6
CodeRank
129:	ShapeDrawable drawable = new ShapeDrawable(circle); 
-
137:	Paint paint = drawable.getPaint(); 
Full Snippet Info
7
CodeRank
61:	ShapeDrawable shapeDrawable = new ShapeDrawable(new OvalShape()); 
62:	Paint paint = shapeDrawable.getPaint(); 
-
64:	shapeDrawable.setBounds(0, 0, bitmap.getWidth(), bitmap.getHeight()); 
65:	shapeDrawable.draw(canvas); 
66:	shapeDrawable.setShape(new ArcShape(60, 240)); 
67:	shapeDrawable.setBounds(0, 160, 200, 310); 
68:	shapeDrawable.draw(canvas); 
Full Snippet Info
6
CodeRank
46:	drawable = new ShapeDrawable(shape); 
47:	drawable.getPaint().set(paint); 
48:	drawable.setBounds(125, 225, 275, 375); 
Full Snippet Info
6
CodeRank
144:	ShapeDrawable drawable = new ShapeDrawable(circle); 
-
152:	Paint paint = drawable.getPaint(); //new Paint(Paint.ANTI_ALIAS_FLAG); 
Full Snippet Info
7
CodeRank
173:	ShapeDrawable drawable = new ShapeDrawable(circle); 
-
181:	Paint paint = drawable.getPaint(); //new Paint(Paint.ANTI_ALIAS_FLAG); 
Full Snippet Info
7
CodeRank