I have a Panel which is a contentPane of a JDialog. That Panel is divided horizontally into two parts. UpperHalfPanel and LowerHalfPanel by:
Panel.add("UpperHalfPanel", "wrap");
Panel.add("LowerHalfPanel");
The LowerHalfPanel is divided vertically into two parts. LowerHalfLeftPanel and LowerHalfRightPanel.
Now the size of the UpperHalfPanel is determined by number of columns of a JTextField and I am finding a way to make the LowerHalfLeftPanel and LowerHalfRightPanel fill 50% of width of LowerHalfPanel.
Briefly it can be described as a Table with two row and the bottom row has two equal column.
Maybe you are looking for split/span. Without more of a code example, it’s hard to say. A lot of times I find that MigLayout makes nested panels unnecessary. If you come up with a simple short example or even a mock image, it would help.
It sounds like you want this:
This will make upper panel span 2 “cells” and the lower left and right be evenly divided under it depending on the contents of those panels. There are ways to force the size, such as the “!” or “wmin”. Try out the swing demo, go to the span section. Right clicking on the areas will let you experiment with the contraints. Also see the MigLayout cheat sheet.