Fixed a bug in the drawRect() method causing incorrect rendering of
rectangles.