public abstract class IlvHeaderFooter extends IlvPrintableObject implements Cloneable
new IlvHeader("Page " + IlvHeaderFooter.PageKey, null, null);will print 'Page 1' on the left section of the first page.
NO_SUCH_PAGE, PAGE_EXISTS
Constructor and Description |
---|
IlvHeaderFooter(String left,
String center,
String right)
Creates a Header or a Footer.
|
IlvHeaderFooter(String left,
String center,
String right,
com.ibm.icu.util.ULocale locale)
Creates a Header or a Footer.
|
Modifier and Type | Method and Description |
---|---|
Object |
clone()
Clones the object.
|
boolean |
equals(Object obj)
Indicates whether some other object is "equal to" this one.
|
static String |
getAuthorKey()
Returns the key for the author.
|
String |
getCenterSection()
Returns the center section of the header or footer.
|
Font |
getCenterSectionFont()
Returns the font used to print the center section.
|
Color |
getColor()
Returns the color used to print the
header.
|
static String |
getDateKey()
Returns the key for the date.
|
static Font |
getDefaultFont()
Returns the default font used when creating a header
or a footer.
|
static String |
getFileKey()
Returns the key for the file name.
|
double |
getHeight()
Returns the height of the header or footer.
|
String |
getLeftSection()
Returns the left section of the header or footer.
|
Font |
getLeftSectionFont()
Returns the font used to print the left section.
|
static String |
getPageKey()
Returns the key for the page number.
|
static String |
getPagesKey()
Returns the key for the number of pages in the book.
|
String |
getRightSection()
Returns the right section of the header or footer.
|
Font |
getRightSectionFont()
Returns the font used to print the right section.
|
static String |
getTimeKey()
Returns the key for the time.
|
int |
print(Graphics dst,
PageFormat format,
int pageIndex)
Prints the header or footer.
|
void |
setCenterSection(String centerSection)
Changes the center section of the header or footer.
|
void |
setCenterSectionFont(Font font)
Changes the font used to print the center section.
|
void |
setColor(Color color)
Changes the color used to print the header.
|
void |
setLeftSection(String leftSection)
Changes the left section of the header or footer.
|
void |
setLeftSectionFont(Font font)
Changes the font used to print the left section.
|
void |
setRightSection(String rightSection)
Changes the right section of the header or footer.
|
void |
setRightSectionFont(Font font)
Changes the font used to print the right section.
|
String |
toString()
Returns a string representation of this object.
|
getPage
public IlvHeaderFooter(String left, String center, String right)
left
- The text to be printed on the left.center
- The text to be printed in the center.right
- The text to be printed on the right.public IlvHeaderFooter(String left, String center, String right, com.ibm.icu.util.ULocale locale)
left
- The text to be printed on the left.center
- The text to be printed in the center.right
- The text to be printed on the right.locale
- The locale to be used to format numbers and dates.public static final String getPageKey()
public static final String getPagesKey()
public static final String getTimeKey()
public static final String getDateKey()
IlvPrintableDocument.setDate(java.util.Date)
public static final String getAuthorKey()
IlvPrintableDocument.setAuthor(java.lang.String)
public static final String getFileKey()
IlvPrintableDocument.setName(java.lang.String)
public String getLeftSection()
setLeftSection(java.lang.String)
public void setLeftSection(String leftSection)
getLeftSection()
public String getCenterSection()
setCenterSection(java.lang.String)
public void setCenterSection(String centerSection)
getCenterSection()
public String getRightSection()
setRightSection(java.lang.String)
public void setRightSection(String rightSection)
getRightSection()
public void setColor(Color color)
getColor()
public Color getColor()
setColor(java.awt.Color)
public static Font getDefaultFont()
public void setLeftSectionFont(Font font)
getLeftSectionFont()
public Font getLeftSectionFont()
setLeftSectionFont(java.awt.Font)
public void setRightSectionFont(Font font)
getRightSectionFont()
public Font getRightSectionFont()
setRightSectionFont(java.awt.Font)
public void setCenterSectionFont(Font font)
getCenterSectionFont()
public Font getCenterSectionFont()
setCenterSectionFont(java.awt.Font)
public double getHeight()
public int print(Graphics dst, PageFormat format, int pageIndex) throws PrinterException
print
in interface Printable
PrinterException
public boolean equals(Object obj)
public String toString()
© Copyright 2024 Rogue Wave Software, Inc., a Perforce company.. All Rights Reserved.