List of usage examples for java.awt RadialGradientPaint RadialGradientPaint
@ConstructorProperties({ "centerPoint", "radius", "focusPoint", "fractions", "colors", "cycleMethod", "colorSpace", "transform" }) public RadialGradientPaint(Point2D center, float radius, Point2D focus, float[] fractions, Color[] colors, CycleMethod cycleMethod, ColorSpaceType colorSpace, AffineTransform gradientTransform)
From source file:org.jfree.graphics2d.demo.ImageTest.java
private static void drawRadialGradientPaintTest(Graphics2D g2) { RadialGradientPaint rgp = new RadialGradientPaint(50, 50, 40, 30, 30, new float[] { 0f, 0.75f, 1f }, new Color[] { Color.RED, Color.GREEN, Color.BLUE }, MultipleGradientPaint.CycleMethod.NO_CYCLE); g2.setPaint(rgp);//w ww .j ava2 s .c om Ellipse2D circle = new Ellipse2D.Double(10, 10, 80, 80); g2.fill(circle); }