org.jfree.chart.plot.PlotState Java Examples
The following examples show how to use
org.jfree.chart.plot.PlotState.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: VenndiPlot.java From chipster with MIT License | 5 votes |
/** * Draws the plot on a Java2D graphics device (such as the screen or * a printer). * * @param g2 the graphics device. * @param area the area within which the plot should be drawn. * @param anchor the anchor point (<code>null</code> permitted). * @param parentState the state from the parent plot, if there is one * (<code>null</code> permitted.) * @param info collects info about the drawing (<code>null</code> permitted). * @throws NullPointerException if g2 or area is null. */ @Override public void draw(java.awt.Graphics2D g2, java.awt.geom.Rectangle2D area, java.awt.geom.Point2D anchor, PlotState parentState, PlotRenderingInfo info) { // adjust for insets... this.getInsets().trim(area); if (info != null) { info.setPlotArea(area); info.setDataArea(area); } //this.setBackgroundPaint(Color.black); drawBackground(g2, area); drawOutline(g2, area); Shape savedClip = g2.getClip(); g2.clip(area); /* Composite originalComposite = g2.getComposite(); public Collection<String> getIdentifiers(AREAS areas) { return Arrays.asList(datas[areas.ordinal()]); } g2.setComposite(AlphaComposite.getInstance(AlphaComposite.SRC_OVER, getForegroundAlpha())); */ drawVenn(g2, area, info); g2.setClip(savedClip); // g2.setComposite(originalComposite); drawOutline(g2, area); }