Automatically increase font size in Swing

I would like to know if there are ways to automatically increase the font size depending on the size of the component. I have this GUI here: However, if I increase the size of the frame, it will become like this: font size does not increase. and I have no idea how to make this work.

+3
source share
1 answer

Some L & Fs support sizeVariant , illustrated here with com.apple.laf.AquaLookAndFeel . In addition, you can scale the font to fill the space allocated by your selected layout, as shown here .

image

+4
source

Source: https://habr.com/ru/post/1391557/


All Articles