I have notice that when not given a backgroung color to a button, it has a nice silver like color which it seems very nice.
I want to make a button change color on click, like : buttonColor = new java.awt.Color(red, green, blue); and then, i want to change it's color back to this nice default color. What are the parameters for this color?
Also, it would be nice if we could put background images to buttons. Is this possible? I don't mean in drawing panel but for buttons or two state buttons.
To get the original color, use the following sentence: originalColorButton = _view.button.getBackground();
and then set the color directly to the button using: _view.setBackground (originalColorButton);
See example attached.
And although setting an image for the background of the button would imply modifying borders and other things, it is very easy to use a Label for this. Run the example attached and click on the green folder icon. This is a Label with an image and an action.