Package com.iizix
Class ComponentPrinter
java.lang.Object
com.iizix.ComponentPrinter
- All Implemented Interfaces:
- Printable
The component printer class will print a "frame" window or a component inside a "frame". This "frame" is really a container and not the frame itself.
- Author:
- Christopher Mindus
- Field Summary- Fields inherited from interface java.awt.print.Printable- NO_SUCH_PAGE, PAGE_EXISTS
- Constructor SummaryConstructors
- Method SummaryModifier and TypeMethodDescription- int- print- (Graphics g, PageFormat pf, int pageIndex) Prints the requested component using Java2D.- static booleanRenders a "frame" window.
- Constructor Details- ComponentPrinterpublic ComponentPrinter()
 
- Method Details- renderRenders a "frame" window.- Parameters:
- componentToPrint- Component to print.
- useDefault- Flag to use the default printer assigned, false to ask user.
- Returns:
- true for success, false for failure.
 
- printPrints the requested component using Java2D. For some reason it gets called twice with pageIndex=0 in some implementations and some JDK's.