Using Panels: BestBasicElements
// create controls as before
Panel buttonGroup = new Panel();
buttonGroup.setLayout(new BorderLayout(2,2));
buttonGroup.add("North", red);
buttonGroup.add("South", green);
Panel textGroup = new Panel();
textGroup.setLayout(new BorderLayout(0,0));
textGroup.add("North", textlabel);
textGroup.add("South", shapeSpec);
// set everyone's background color