SyntaxFix
Write A Post
Hire A Developer
Questions
myLabel.setHorizontalAlignment(SwingConstants.CENTER); myLabel.setVerticalAlignment(SwingConstants.CENTER);
If you cannot reconstruct the label for some reason, this is how you edit these properties of a pre-existent JLabel.