I have situation that I use CardLayout with several JPanels, because I want to see only on at the moment. BUT, I need to make JPanel's (each of them) components auto resizable. I googled and found that GridLayout or GridBagLayout (as I figured out) can do that components change shapes when resizing JFrame.
Can anyone help me how to combine these two Layouts and make things work together.
P.S. All JPanels are in separate classes and main class is what contains JFrame with CardLayout. Also contains menubar. All JPanels has absolute Layout (I suppose it is also a problem), but I am not very friendly with Layouts.