added getRect to return the shape of the canvas