The list of methods to do JLabel Create are organized into topic(s).
JLabel
createJLabel(Container c, String caption, int x, int y) This method makes it easy (and also neat) creating a
JLabel and adding it to its container class.
FontMetrics fm = c.getFontMetrics(c.getFont());
JLabel lbl = new JLabel(caption);
lbl.setBounds(x, y, fm.stringWidth(caption) + 20, 20);
c.add(lbl);
return lbl;
JLabel
createJLabel(String mlabel) Create a JLabel but make the font plain instead of super ugly BOLD
JLabel l = new JLabel(mlabel, SwingConstants.LEFT);
setFontType(l, Font.PLAIN);
return l;
JLabel
createLabel(String text, Font f) create Label
JLabel newLab = new JLabel(text);
newLab.setBackground(BG_COLOR);
newLab.setFont(f);
newLab.setForeground(DARK_GREEN_COLOR);
return newLab;