2012-02-10 23 views

Odpowiedz

3

można używać HTML w JLabels, więc to powinno działać:

JLabel lbl = new JLabel("<html><span style='color: blue;'>My</span> <span style='color: red;'>Text</span></html>"); 
4

Spróbuj z HTML:

String labelText = 
    "<html><FONT COLOR=BLUE>My</FONT>" + 
    "<FONT COLOR=RED>Text</FONT></html>"; 
JLabel lbl = new JLabel(labelText);