Skip navigation links
com.essbase.eas.utils.print
Class TablePainter
java.lang.Object
com.essbase.eas.utils.print.TablePainter
- All Implemented Interfaces:
- PrintableObject
-
public class TablePainter
- extends java.lang.Object
- implements PrintableObject
A Table painter object
- Since:
- 6.5.1
- Version:
- 7.1.0
- Author:
- Sree Menon
Constructor Summary |
TablePainter(javax.swing.table.TableModel model, int row, int[] colLen)
|
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. |
protected int |
drawText(java.awt.Graphics g, java.awt.FontMetrics fm, java.lang.String text, int posX, int posY, int height, int width, int dispWidth, boolean center)
|
static int[] |
getColLength(javax.swing.table.TableModel model)
|
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 |
recalcColWidth(java.awt.Font font)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
TablePainter
public TablePainter(javax.swing.table.TableModel model,
int row,
int[] colLen)
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
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
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
drawText
protected int drawText(java.awt.Graphics g,
java.awt.FontMetrics fm,
java.lang.String text,
int posX,
int posY,
int height,
int width,
int dispWidth,
boolean center)
getColLength
public static int[] getColLength(javax.swing.table.TableModel model)
recalcColWidth
public void recalcColWidth(java.awt.Font font)
dispose
public void dispose()
Skip navigation links
Copyright © 2001, 2007, Oracle. All rights reserved.