Add reduce() to utility functions
Collect each shape and compute its bounding box

The bounding box (top, left, width, height) refers to the parent cell
of the shape at this step, before the vertical and horizontal alignments
have been applied.