Code example for Canvas

Methods: drawBitmap, drawCircle, drawPath

0
	} 
 
	@Override 
	protected void onDraw(Canvas canvas) {
		if (bitmap != null) {
			canvas.drawBitmap(bitmap, new Matrix(), null);
		} 
		canvas.drawPath(path, paint);
		canvas.drawCircle((float) point.x, (float) point.y, 100, paint);
	} 
 
	@Override 
	public boolean onTouchEvent(MotionEvent event) {
		float x = event.getX();
		float y = event.getY();
		switch (event.getAction()) {
		case MotionEvent.ACTION_DOWN:
			path.moveTo(x, y);
			point.set((int) x, (int) y);
			return true; 
		case MotionEvent.ACTION_MOVE: