Hi,
after you created the user interface of your new JFrame, you have to call the pack() method of your new JFrame instance. This will size your JFrame accordingly to the interface widgets it contains.
You may as well positioned the min, max and preferred size by the setMinimumSize(), setMaximumSize() and setPreferredSize() methods if you want to force those.
Cheers.
Vince.