Colour pinstripe/Display: Difference between revisions
Content deleted Content added
→{{header|Java}}: added Java |
→{{header|Java}}: change classname: didn't realize there's another pinstripe display task |
||
Line 394:
import javax.swing.*;
public class
final static Color[] palette = {Color.black, Color.red, Color.green,
Color.blue, Color.magenta, Color.cyan, Color.yellow, Color.white};
Line 400:
final int bands = 4;
public
setPreferredSize(new Dimension(900, 600));
}
Line 422:
JFrame f = new JFrame();
f.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
f.setTitle("
f.add(new
f.pack();
f.setLocationRelativeTo(null);
|