import javax.swing.JFrame; import javax.swing.JLabel; public class LabelMitHTMLText extends JFrame { public LabelMitHTMLText() { String txt = "

Überschrift

" + "

" + "Falsches Üben von Xylophonmusik quält jeden " + "größeren " + "Zwerg.

"; JLabel label = new JLabel(txt); this.add(label); this.setLocationRelativeTo(null); this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); this.pack(); this.setVisible(true); } public static void main(String[] args) { new LabelMitHTMLText(); } }