Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- @Override
- protected void paintComponent(Graphics g) {
- Graphics2D g2d = (Graphics2D) g;
- g2d.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON);
- g2d.setPaint(new LinearGradientPaint(0.0f, 0.0f, 0.0f, 50.0f,
- new float[] { 0.0f, 0.499f, 0.5f, 1.0f },
- new Color[] { new Color(0x63a5f7),
- new Color(0x3799f4),
- new Color(0x2d7eeb),
- new Color(0x30a5f9) }));
- g2d.fillRect(0, 0, getWidth(), getHeight());
- super.paintComponent(g);
- }
Add Comment
Please, Sign In to add comment