Skip navigation links


com.essbase.eas.utils.print
Class ComponentPainter

java.lang.Object
  extended by com.essbase.eas.utils.print.ComponentPainter

All Implemented Interfaces:
PrintableObject

public class ComponentPainter
extends java.lang.Object
implements PrintableObject

A Tree painter object

Since:
6.5.1
Version:
7.1.0
Author:
Sree Menon

Field Summary
protected  java.awt.Component comp
           
protected  java.awt.Dimension compSize
           
protected  int srcHeight
           
protected  int srcY
           
protected  int tgtHeight
           
protected  int tgtWidth
           

 

Constructor Summary
ComponentPainter(java.awt.Component comp)
           

 

Method Summary
 void dispose()
           
 int drawObject(java.awt.Graphics graphics, java.awt.print.PageFormat pageFormat, int posX, int posY, int height)
          Draws the object at the x and y.
 int getHeight(java.awt.print.PageFormat pageFormat, java.awt.Font font)
          Returns the height of the object with the font
 int getWidth(java.awt.print.PageFormat pageFormat, java.awt.Font font)
          Returns the width of the object using the font
 void setComponentSize(java.awt.Dimension dm)
           
 void setComponentY(int y)
           
 void setSourceHeight(int height)
           
 void setTargetHeight(int height)
           
 void setTargetWidth(int width)
           

 

Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

 

Field Detail

comp

protected java.awt.Component comp

srcHeight

protected int srcHeight

srcY

protected int srcY

tgtHeight

protected int tgtHeight

tgtWidth

protected int tgtWidth

compSize

protected java.awt.Dimension compSize

Constructor Detail

ComponentPainter

public ComponentPainter(java.awt.Component comp)

Method Detail

setComponentY

public void setComponentY(int y)

setSourceHeight

public void setSourceHeight(int height)

setTargetHeight

public void setTargetHeight(int height)

setTargetWidth

public void setTargetWidth(int width)

setComponentSize

public void setComponentSize(java.awt.Dimension dm)

getWidth

public int getWidth(java.awt.print.PageFormat pageFormat,
                    java.awt.Font font)
Description copied from interface: PrintableObject
Returns the width of the object using the font
Specified by:
getWidth in interface PrintableObject
font - font
Returns:
the width

getHeight

public int getHeight(java.awt.print.PageFormat pageFormat,
                     java.awt.Font font)
Description copied from interface: PrintableObject
Returns the height of the object with the font
Specified by:
getHeight in interface PrintableObject
font - font
Returns:
the height

drawObject

public int drawObject(java.awt.Graphics graphics,
                      java.awt.print.PageFormat pageFormat,
                      int posX,
                      int posY,
                      int height)
Description copied from interface: PrintableObject
Draws the object at the x and y.
Specified by:
drawObject in interface PrintableObject
Parameters:
graphics - graphics to draw
pageFormat - the current page format
posX - the x position
posY - the Y position
height - the height
Returns:
the width of the object

dispose

public void dispose()

Skip navigation links


Copyright © 2001, 2012, Oracle. All rights reserved.