Change JToggleButton selected color

From: Chris (unknown_at_devnull.org)
Date: 02/27/04


Date: Fri, 27 Feb 2004 02:01:52 GMT

I would like to change the color of a selected JToggleButton (in a
ButtonGroup) to red from grey. About the only solution I can find online
is to put this in my main program:

UIManager.put("ToggleButton.select", Color.red);

However this doesn't change anything for me. Strangely if I change my
JToggleButton class to JButton this line indeed does work:

UIManager.put("Button.select", Color.red);

By the way, all my buttons are actually from a derived class called
SymbolButton that extends JToggleButton. I'm running 1.4.2 on Linux.

Thanks,
Chris


Quantcast