I just started messing around with the BoxLayout manager.
I've made two buttons next to each other, and the third one should go to the next line (underneath the first two), and the two first buttons should be at the top of the frame.
How can I accomplish this?
This is my current code
Box box = Box.createHorizontalBox();
box.add(Box.createHorizontalGlue());
box.add(new JButton("Button"));
box.add(new JButton("Hello"));
box.add(Box.createVerticalBox());
box.add(Box.createVerticalStrut(100));
box.add(new JButton("Button2"));
add(box);