setbackground java code example
Example 1: jframe color
private JFrame frame;
frame.getContentPane().setBackground(Color.BLACK);
Example 2: setbackground java
setBackground(Color.cyan); // sets predefined color cyan to background of frame
private JFrame frame;
frame.getContentPane().setBackground(Color.BLACK);
setBackground(Color.cyan); // sets predefined color cyan to background of frame