| Author |
Change color of a LookAndFeel
|
Laurent Sate
Greenhorn
Joined: Dec 18, 2001
Posts: 10
|
|
Hello, I want to change the color of all the text in my frame. For example, i want to have my JLabel in green in place of blue. How can I do that?
|
 |
Gregg Bolinger
Sheriff
Joined: Jul 11, 2001
Posts: 15040
|
|
setForground(Color) will change the text color. setBackgroud(Color) will change the background color. ------------------ Happy Coding, Gregg Bolinger
|
My Blog | DZone Articles
|
 |
Laurent Sate
Greenhorn
Joined: Dec 18, 2001
Posts: 10
|
|
Yes but for the all  i have the response: set foregroundcolor of all of them to what ever color you want! use UIManager.put("Label.foreground",Color.blue); for other components also, do the same thing.
|
 |
Nathan Pruett
Bartender
Joined: Oct 18, 2000
Posts: 4120
|
|
LS, Please re-register with a name that follows the Official JavaRanch Username Conventions. Your username needs to be in the format "first name" + space + "last name". Thanks, -Nate
|
-Nate
Write once, run anywhere, because there's nowhere to hide! - /. A.C.
|
 |
Michael Szul
Ranch Hand
Joined: Sep 18, 2001
Posts: 57
|
|
|
If you use themes with the Metal L&F you can change just about anything you want. Even globally.
|
 |
 |
|
|
subject: Change color of a LookAndFeel
|
|
|