public class PrintPages extends PrintableObject implements RandomPrintable
Modifier and Type | Field and Description |
---|---|
protected Vector |
pages |
documentName, drawDPI, fontManager, myFontManager, myPrinter, preferredFormat, printerControl
dontFreeAfterPrint, page
UNKNOWN_NUMBER_OF_PAGES
BOTTOM, CELLFLAG, CELLMASK, CENTER, CONTROLMASK, DONTCHANGE, DONTFILL, DONTSTRETCH, EAST, FILL, GROW, HCENTER, HCONTRACT, HEXPAND, HFILL, HGROW, HSHRINK, HSTRETCH, INITIALLY_CLOSED, INITIALLY_MINIMIZED, INITIALLY_PREFERRED_SIZE, LEFT, NORTH, NORTHEAST, NORTHWEST, RIGHT, SHRINK, SOUTH, SOUTHEAST, SOUTHWEST, STRETCH, TAG_BACKGROUND_IMAGE, TAG_BORDER, TAG_FIXEDSIZE, TAG_INSETS, TAG_MAXIMUMSIZE, TAG_MINIMUMSIZE, TAG_PREFERREDSIZE, TAG_RECT, TAG_SPAN, TAG_TEXTSIZE, TOP, VCENTER, VCONTRACT, VEXPAND, VFILL, VGROW, VSHRINK, VSTRETCH, WEST
Constructor and Description |
---|
PrintPages() |
Modifier and Type | Method and Description |
---|---|
void |
addFullPage(PrintablePage page) |
int |
countPages(PageFormat pf)
By default this returns UNKNOWN_NUMBER_OF_PAGES.
|
void |
doPrint(PointGraphics pg,
PointRect area) |
PointDrawable |
getPage(PageFormat pf,
int pageIndex)
Get a PointDrawable for a particular page.
|
void |
releasePage(PointDrawable pd) |
protected boolean |
setupForPage(PointGraphics pg,
PageFormat format,
int pageIndex) |
int |
size()
Return the number of pages added to this PrintPages.
|
boolean |
validatePage(PageFormat page,
int pageIndex)
This should return true if the page with the specified index should be printed.
|
adjustPrinterProperties, getDocumentName, getPreferredFormat, getXdpiFor, getYdpiFor, print, printingComplete, printingStarting, setupForPage
addCell, addFullImageablePanel, addMarginedPanel, addMarginedPanel, addMarginedPanel, checkSetup, completeSetup, doPrint, draw, free, getCurrentCell, getCurrentPage, isSetupFor, print, reset, setPageFormat, setup
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
adjustPrinterProperties, getDocumentName, getPreferredFormat, print, printingComplete, printingStarting
protected Vector pages
public void addFullPage(PrintablePage page)
protected boolean setupForPage(PointGraphics pg, PageFormat format, int pageIndex)
setupForPage
in class PrintableObject
public void doPrint(PointGraphics pg, PointRect area)
doPrint
in class CellPrinter
public boolean validatePage(PageFormat page, int pageIndex)
Printable
validatePage
in interface Printable
validatePage
in class PrintableObject
public int countPages(PageFormat pf)
PrintableObject
countPages
in interface Printable
countPages
in class PrintableObject
public final PointDrawable getPage(PageFormat pf, int pageIndex)
RandomPrintable
getPage
in interface RandomPrintable
getPage
in class PrintableObject
pf
- the PageFormat to be used.pageIndex
- the index of the page - starting from zero.public void releasePage(PointDrawable pd)
releasePage
in interface RandomPrintable
public int size()