I'm a beginner and I want to design the gui of the windows calculator in java. I have set some jpanels(Gridlayout) with some jbuttons in each. I set the size of the buttons this way:
jButton[i].setPreferredSize(new Dimension(42, 42));
but buttons in differen jpanels don't have the same size. what should I do?