Candidate tree structures, each of which includes a current tree structure
and a respective node defining a respective relative location on the
selected page for another graphic object selected from a set, are
generated. Initial size dimensions are determined for the graphic objects
in each of the candidate tree structures. Respective scores are computed
for the candidate tree structures based at least in part on the
corresponding initial size dimensions. One of the candidate tree
structures is selected as the current tree structure based on the
computed scores. The process is repeated until relative locations on the
page are defined for all of the graphic objects in the set. Next, final
size dimensions are calculated for the graphic objects in accordance with
the current tree structure. Respective positions of the graphic objects
on the selected page are specified in accordance with the current tree
structure.