It will resize because it recalculates the layout based upon the preferred sizes of all it components. You can play with setting the preferred size of the panel to prevent this.
The keyListener...
Type: Posts; User: copeg
It will resize because it recalculates the layout based upon the preferred sizes of all it components. You can play with setting the preferred size of the panel to prevent this.
The keyListener...
JFrame.show is deprecated and a bit overkill, you can just call pack() and the JFrame will repack all of its container components.