how to place a JLabel in a Jframe that stays in the center even if you resize the jframe

28 Views Asked by At

when I open my program the buttons, fields and labels are statically positioned. when I expand the JFrame the buttons, fields etc. are positioned badly.

of course I tried to place them manually. but by doing so, when the page is enlarged or reduced, the buttons, labels, etc. have an aesthetically very ugly position

I remember that in css when you had to describe a location. we had the possibility to set something so that if the page was reduced or enlarged, the "objects" changed their position in relation to the page size

0

There are 0 best solutions below