JFrame Resize Event
Posted on 2006-06-26
Hi, I am designing a GUI with my own custom JTable which has a method to resize the columns in the table, such that the 2nd column fills all of the space that the JTable has available. I have added a listener to the main JFrame to detect when it is resized so I can call my resize method.
I'm aware that you can set the .setDynamicLayout() to true for the default toolkit to enable components to be resized and moved according to the layout manager as the frame is being resized (instead of just when the user releases the mouse button after a resize)
My problem is that the listener I have registered only picks up resize events fired after the user releases the mouse button after a resize. Is there a way to call my .resize() method dynamically as the JFrame is being resized?