container.setLayout(new BoxLayout(container,
BoxLayout.Y_AXIS));
CoordinateArea coordinateArea = new CoordinateArea(this);
container.add(coordinateArea);
label = new JLabel("Click within the framed area.");
container.add(label);
//Align the left edges of the components.
coordinateArea.setAlignmentX(LEFT_ALIGNMENT);
label.setAlignmentX(LEFT_ALIGNMENT); //redundant