afreechart/src/main/java/org/afree/chart/StandardChartTheme.java
/**
     * Applies the attributes of this theme to a plot.
     *
     * @param plot  the plot (<code>null</code>).
     */
Applies the attributes of this theme to a plot.
@param plot  the plot (null).
Applies the attributes of this theme to a plot . @param plot the plot ( null ) .
protected void applyToPlot(Plot plot) {
        if (plot == null) {
            throw new IllegalArgumentException("Null 'plot' argument.");
        }
        if (plot.getDrawingSupplier() != null) {
            plot.setDrawingSupplier(getDrawingSupplier());
        }
        if (plot.getBackgroundPaintType() != null) {
            plot.setBackgroundPaintType(this.plotBackgroundPaintType);
        }
        plot.setOutlinePaintType(this.plotOutlinePaintType);
        if (plot instanceof PiePlot) {
            applyToPiePlot((PiePlot) plot);
        }
        else if (plot instanceof CategoryPlot) {
            applyToCategoryPlot((CategoryPlot) plot);
        }
        else if (plot instanceof XYPlot) {
            applyToXYPlot((XYPlot) plot);
        }
    }
protected void applyToPlot ( Plot plot ) { if ( plot == null ) { throw new IllegalArgumentException ( "Null 'plot' argument." ) ; } if ( plot . getDrawingSupplier ( ) != null ) { plot . setDrawingSupplier ( getDrawingSupplier ( ) ) ; } if ( plot . getBackgroundPaintType ( ) != null ) { plot . setBackgroundPaintType ( this . plotBackgroundPaintType ) ; } plot . setOutlinePaintType ( this . plotOutlinePaintType ) ; if ( plot instanceof PiePlot ) { applyToPiePlot ( ( PiePlot ) plot ) ; } else if ( plot instanceof CategoryPlot ) { applyToCategoryPlot ( ( CategoryPlot ) plot ) ; } else if ( plot instanceof XYPlot ) { applyToXYPlot ( ( XYPlot ) plot ) ; } }
Applies the attributes of this theme to a plot.
Applies the attributes of this theme to a plot .
// now handle specific plot types (and yes, I know this is some // really ugly code that has to be manually updated any time a new // plot type is added - I should have written something much cooler, // but I didn't and neither did anyone else). //        else if (plot instanceof MultiplePiePlot) { //            applyToMultiplePiePlot((MultiplePiePlot) plot); //        } //        else if (plot instanceof FastScatterPlot) { //            applyToFastScatterPlot((FastScatterPlot) plot); //        } //        else if (plot instanceof MeterPlot) { //            applyToMeterPlot((MeterPlot) plot); //        } //        else if (plot instanceof ThermometerPlot) { //            applyToThermometerPlot((ThermometerPlot) plot); //        } //        else if (plot instanceof SpiderWebPlot) { //            applyToSpiderWebPlot((SpiderWebPlot) plot); //        } //        else if (plot instanceof PolarPlot) { //            applyToPolarPlot((PolarPlot) plot); //        }