// Get rid of the default layout manager.
// We'll arrange the components ourselves.
this.setLayout(null);
// Create some buttons and set their sizes and positions explicitly
for(int i = 1; i <= 9; i++) {
JButton b = new JButton("Button #" + i);
b.setBounds(i*30, i*20, 125, 30); // use reshape() in Java 1.0
this.add(b);
}