is it possible using swing, to build a GUI whose elements, when the GUI is resized, keep te proportion between themself? Or i should fire a “resize every GUI component” function when the resize event occurs?
I’m using Netbeans 6.9
is it possible using swing, to build a GUI whose elements, when the GUI
Share
Long ago, there was a very interesting article series on JavaWorld about “transmogrifying widgets” by Allen Hollub. This serie explain how, using different widgets to sho the same information, a calcoulator can have different styles when viewed with different dimensions.
However, for a far simpler (but far less powerful) approach, you should take an in-depth look to
GridBagLayoutand the (now famous)GBCclass. This will give you a fast, and quite elegant, method to resize your whole UI with interesting resizing behaviours (oh and don’t forget the associated tutorial).