voji.report
Class ReportPageNumber

java.lang.Object
  |
  +--voji.report.ReportComponent
        |
        +--voji.report.ReportText
              |
              +--voji.report.ReportPageNumber

public class ReportPageNumber
extends ReportText

This report component shows the current page number


Field Summary
 java.lang.String after
          The text after the number itself
 java.lang.String before
          The text before the number itself
 
Fields inherited from class voji.report.ReportText
align, CENTER, CHAR, font, hasInsets, left, LEFT, NEWLINE, right, RIGHT, text, type, WORD
 
Constructor Summary
ReportPageNumber(java.lang.String before, java.lang.String after, double left, double right, java.awt.Font font)
          Constructs a new ReportPageNumber instance.
ReportPageNumber(java.lang.String before, java.lang.String after, double left, double right, java.awt.Font font, int align, int type, boolean hasInsets)
          Constructs a new ReportPageNumber instance
 
Method Summary
protected  void updateText(PageGraphics g)
          Updates the text using the current page number
 
Methods inherited from class voji.report.ReportText
draw, drawLine, getInsets, getLines, getOwnHeight
 
Methods inherited from class voji.report.ReportComponent
add, getHeight, remove
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

before

public java.lang.String before
The text before the number itself


after

public java.lang.String after
The text after the number itself

Constructor Detail

ReportPageNumber

public ReportPageNumber(java.lang.String before,
                        java.lang.String after,
                        double left,
                        double right,
                        java.awt.Font font,
                        int align,
                        int type,
                        boolean hasInsets)
Constructs a new ReportPageNumber instance

Parameters:
before - the text to display before the number itself
after - the text to display after the number itself
left - the left extension of the text
right - the right extension of the text
font - the font of the text
align - the alignment of the text
type - the break type of the text
hasInsets - whether the text should have insets

ReportPageNumber

public ReportPageNumber(java.lang.String before,
                        java.lang.String after,
                        double left,
                        double right,
                        java.awt.Font font)
Constructs a new ReportPageNumber instance. It uses a NEWLINE break type, no insets and a RIGHT text alignment.

Parameters:
before - the text to display before the number itself
after - the text to display after the number itself
left - the left extension of the text
right - the right extension of the text
font - the font of the text
Method Detail

updateText

protected void updateText(PageGraphics g)
Updates the text using the current page number

Overrides:
updateText in class ReportText
Parameters:
g - a graphical context to determine font sizes etc.