Change the fontsize of a jLabel.
Here's a very short example on how to change the size in a jLabel.
Of course, to do this, you'll have to include the Font class.
Code:
import java.awt.Font;
Here's the short code to change only the size!
Code:
Font curFont = myLabel.getFont();
myLabel.setFont(new Font(curFont.getFontName, curFont.getStyle, 18));
@Qkyrie
I think you meant "import" when you wrote "include" ;)
BeantwoordenVerwijderenToo much C/C++ for you!
Haha, so true, thanks for the comment ;)
BeantwoordenVerwijderen