List of usage examples for org.jfree.chart ChartColor createDefaultPaintArray
public static Paint[] createDefaultPaintArray()
Paint objects that represent the pre-defined colors in the Color and ChartColor objects. From source file:org.codehaus.mojo.dashboard.report.plugin.chart.AbstractChartStrategy.java
/** * */ public Paint[] getPaintColor() { return ChartColor.createDefaultPaintArray(); }
From source file:edu.scripps.fl.curves.plot.CurvePlotDrawingSupplier.java
public CurvePlotDrawingSupplier() { List<Paint> paints = new ArrayList(); paints.add(Color.GREEN);/*from www . ja v a2s. com*/ paints.add(Color.BLACK); paints.addAll(Arrays.asList(ChartColor.createDefaultPaintArray())); paintSequence = paints.toArray(new Paint[0]); }
From source file:org.codehaus.mojo.dashboard.report.plugin.chart.time.MarkerTimeChartDecorator.java
public void createChart() { XYPlot xyplot = (XYPlot) report.getPlot(); // if (this.decoratedChart instanceof TimeChartRenderer ) { if (this.results != null && !this.results.isEmpty()) { Iterator iter1 = this.results.iterator(); ValueMarker valuemarker = null;//from w w w . j a v a 2s. co m BlockContainer blockcontainerLabel = new BlockContainer(new ColumnArrangement()); // blockcontainerLabel.setFrame( new LineBorder() ); int i = 0; while (iter1.hasNext()) { Object[] item = (Object[]) iter1.next(); Date date = (Date) item[1]; Calendar cal = Calendar.getInstance(); cal.setTime(date); cal.set(Calendar.HOUR_OF_DAY, 0); cal.set(Calendar.MINUTE, 0); cal.set(Calendar.SECOND, 0); valuemarker = new ValueMarker(cal.getTimeInMillis(), ChartColor.createDefaultPaintArray()[i], new BasicStroke(2.0F)); xyplot.addDomainMarker(valuemarker); LegendItem legendLabel = new LegendItem((String) item[0], null, null, null, new Line2D.Double(-7.0, 0.0, 7.0, 0.0), valuemarker.getPaint(), valuemarker.getStroke(), valuemarker.getPaint()); blockcontainerLabel.add(createLegendItemBlock(legendLabel, i)); i++; } createLegendBlock(blockcontainerLabel); } // } }