I'm building an app with Netbeans GUI Builder, and I want the main JFrame to be maximised, so have set:
setExtendedState(JFrame.MAXIMIZED_BOTH);
However, Netbeans calls pack() which results in the JFrame size being reduced. I know I can use the above code again after pack() has been called, but is there anyway I can prevent Netbeans from inserting the pack() line so I can keep my code a bit cleaner?
(Netbeans puts its pack() line in a block that you can't edit, so I can't simply remove it in the usual manner.)