expand and shrink method for Rects