/** * Sets the insets for the plot and sends a {@link PlotChangeEvent} to * all registered listeners. * * @param insets the new insets ({@code null} not permitted). * * @see #getInsets() * @see #setInsets(RectangleInsets, boolean) */ public void setInsets(RectangleInsets insets) { setInsets(insets, true); }
/** * Sets the insets for the plot and sends a {@link PlotChangeEvent} to * all registered listeners. * * @param insets the new insets (<code>null</code> not permitted). * * @see #getInsets() * @see #setInsets(RectangleInsets, boolean) */ public void setInsets(RectangleInsets insets) { setInsets(insets, true); }
/** * Sets properties common to all plots of this plug-in. * * @param plot * the plot to set the properties for */ // CHECKSTYLE:OFF protected void setPlotProperties(final Plot plot) { plot.setBackgroundPaint(Color.WHITE); plot.setOutlinePaint(null); plot.setForegroundAlpha(0.8f); plot.setInsets(new RectangleInsets(0, 0, 0, 5.0)); } // CHECKSTYLE:ON
/** * Sets properties common to all plots of this plug-in. * * @param plot * the plot to set the properties for */ // CHECKSTYLE:OFF protected void setPlotProperties(final Plot plot) { plot.setBackgroundPaint(Color.WHITE); plot.setOutlinePaint(null); plot.setForegroundAlpha(0.8f); plot.setInsets(new RectangleInsets(0, 0, 0, 5.0)); } // CHECKSTYLE:ON
public static void customizePlot(Plot plot, ChartParams params) { if (params.get(ChartParams.PLOT_BACKGROUND_COLOR) != null) { plot.setBackgroundPaint(params.getColor(ChartParams.PLOT_BACKGROUND_COLOR)); } if (params.get(ChartParams.PLOT_BACKGROUND_ALPHA) != null) { plot.setBackgroundAlpha(params.getFloat(ChartParams.PLOT_BACKGROUND_ALPHA).floatValue()); } if (params.get(ChartParams.PLOT_FOREGROUND_ALPHA) != null) { plot.setForegroundAlpha(params.getFloat(ChartParams.PLOT_FOREGROUND_ALPHA).floatValue()); } if (params.get(ChartParams.PLOT_INSERTS) != null) { plot.setInsets(params.getRectangleInsets(ChartParams.PLOT_INSERTS)); } if (params.get(ChartParams.PLOT_OUTLINE_COLOR) != null) { plot.setOutlinePaint(params.getColor(ChartParams.PLOT_OUTLINE_COLOR)); } if (params.get(ChartParams.PLOT_OUTLINE_STROKE) != null) { plot.setOutlineStroke(params.getStroke(ChartParams.PLOT_OUTLINE_STROKE)); } }
plot.setOutlineStroke(getOutlineStroke()); plot.setBackgroundPaint(getBackgroundPaint()); plot.setInsets(getPlotInsets());
plot.setOutlineStroke(getOutlineStroke()); plot.setBackgroundPaint(getBackgroundPaint()); plot.setInsets(getPlotInsets());
plot.setInsets(new RectangleInsets(UnitType.ABSOLUTE, 0d, 0d, 0d, 0d)); plot.setBackgroundPaint(WidgetUtils.BG_COLOR_BRIGHTEST); plot.setOutlinePaint(WidgetUtils.BG_COLOR_BRIGHTEST);