Mega Code Archive

 
Categories / Java Tutorial / Swing
 

The text is left-justified and bottom-aligned

import javax.swing.JLabel; public class Main {   public static void main(String[] argv) throws Exception {     JLabel label = new JLabel("Text Label", JLabel.LEFT);     label.setVerticalAlignment(JLabel.BOTTOM);   } }