/*
 * Plot.java
 *
 * Created on 8 luglio 2005, 17.55
 *
 * To change this template, choose Tools | Options and locate the template under
 * the Source Creation and Management node. Right-click the template and choose
 * Open. You can then make changes to the template in the Source Editor.
 */

package it.businesslogic.ireport.chart;

/**
 *
 * @author Administrator
 */
public class Plot {
    
    private java.awt.Color backcolor = null;
    private String orientation = "Vertical";
    private double backgroundAlpha = 1;
    private double foregroundAlpha = 1;
    
    
    /** Creates a new instance of Plot */
    public Plot() {
    }

    public java.awt.Color getBackcolor() {
        return backcolor;
    }

    public void setBackcolor(java.awt.Color backcolor) {
        this.backcolor = backcolor;
    }

    public String getOrientation() {
        return orientation;
    }

    public void setOrientation(String orientation) {
        this.orientation = orientation;
    }

    public double getBackgroundAlpha() {
        return backgroundAlpha;
    }

    public void setBackgroundAlpha(double backgroundAlpha) {
        this.backgroundAlpha = backgroundAlpha;
    }

    public double getForegroundAlpha() {
        return foregroundAlpha;
    }

    public void setForegroundAlpha(double foregroundAlpha) {
        this.foregroundAlpha = foregroundAlpha;
    }
    
    public Plot cloneMe()
    {
        return new Plot();
    }
    
    public void copyBasePlot(Plot plot)
    {
        if (getBackcolor() != null)  plot.setBackcolor(new java.awt.Color( getBackcolor().getRGB()) );
        plot.setForegroundAlpha( getForegroundAlpha() );
        plot.setBackgroundAlpha( getBackgroundAlpha() );
        plot.setOrientation( new String(getOrientation()) );
    }
    
}
