Use bounding rect to determine shape offscreen

Use the bounding rect around a shape to determing if it falls offscreen,
in order to not have to change offscreen calculations for different
shapes.