I can't get my 3 panels to align properly. I basically have 1 big panel and 2 smaller (not necesarily identical) ones. The big one is on the left and the 2 smaller ones on the right, with one above the other. The components should remain dynamically resizeable.
What I want is this( 9's is the big one, 1 is one of the small one, 2 is the other small one):
999999 111
999999 111
999999 111
999999 222
999999 222
What I get is this:
999999 111
999999 111
999999 111
999999
999999
222
222
My code is as follows with graphsimscrollpane big one and workpanel and informationpanel the smaller ones:
private void createLayout(GroupLayout groupLayout) {
groupLayout.setHorizontalGroup(
groupLayout.createSequentialGroup()
.addContainerGap()
.addComponent(graphSimScrollPane, 0, GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
.addContainerGap(20, Short.MAX_VALUE)
.addGroup(groupLayout.createParallelGroup(Alignment.CENTER)
.addComponent(workPanel, 0, GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
.addComponent(informationPanel, 0, GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
);
groupLayout.setVerticalGroup(
groupLayout.createSequentialGroup()
.addGroup(groupLayout.createParallelGroup(Alignment.CENTER)
.addComponent(graphSimScrollPane, 0, GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
.addComponent(workPanel, 0, GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
.addComponent(informationPanel, 0, GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
);
guiFrame.getContentPane().setLayout(groupLayout);
}