/*
 * ChartTitle.java
 *
 * Created on 8 luglio 2005, 17.36
 *
 * Can be used as ChartTitle and as ChartSubtitle
 */

package it.businesslogic.ireport.chart;

import it.businesslogic.ireport.*;

/**
 *
 * @author Administrator
 */
public class ChartLegend {
    
   private IReportFont font = null;
    
   private java.awt.Color textColor = java.awt.Color.BLACK;
   private java.awt.Color backgroundColor = java.awt.Color.WHITE;
   
   
   /** Creates a new instance of ChartTitle */
   public ChartLegend() {       
   }

    public IReportFont getFont() {
        return font;
    }

    public void setFont(IReportFont font) {
        this.font = font;
    }

    
    public ChartLegend cloneMe() {
        
        ChartLegend ct = new ChartLegend();
        if (getFont() != null) ct.setFont( (IReportFont)getFont().clone() );
        if (getBackgroundColor() != null) ct.setBackgroundColor(  new java.awt.Color( getBackgroundColor().getRGB() ));
        if (getTextColor() != null) ct.setTextColor(  new java.awt.Color( getTextColor().getRGB() ));
        
        return ct;
    }

    public java.awt.Color getTextColor() {
        return textColor;
    }

    public void setTextColor(java.awt.Color textColor) {
        this.textColor = textColor;
    }

    public java.awt.Color getBackgroundColor() {
        return backgroundColor;
    }

    public void setBackgroundColor(java.awt.Color backgroundColor) {
        this.backgroundColor = backgroundColor;
    }
}
