|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object | +--org.PingOO.DLAI.lib.util.PrinterManager
Class that manages printing operations.
You can directly send text to printing or provide a Printable object that will handle all rendering operations.
Warning! Actually under Linux this seems to provoke a problem when printing plain text or when drawing text in graphics : on some system the printed pages are empty as well as the PostScript files. This may be realated to a missing font or something else.
Had also a problem sometimes when two (or more) different documents are sent to the printer, the second is never printed and the thread is still marked as active.
Warning! Hada problem under windows with Epson Stylus Color 800, if the generic windows driver is in use instead of the Epson's one then only the first page of the document is printed.
Runnable,
Printable,
java.awt.print.PrinterJob| Field Summary | |
private java.awt.print.Printable |
printable
The current Printable object that will be used when printing. |
private PThread |
printerThread
The thread use to print. |
| Constructor Summary | |
private |
PrinterManager(java.awt.print.Printable printable)
Creates a new PrinterManager. |
| Method Summary | |
static void |
print(java.awt.print.Printable printable)
Launches a new printing session using the Printable object.
|
static void |
print(java.lang.String text)
Prints a text. |
void |
run()
Do printing job. |
private void |
start()
Start printing operations. |
void |
stop()
Stops the current PrinterManager. |
| Methods inherited from class java.lang.Object |
|
| Field Detail |
private PThread printerThread
private java.awt.print.Printable printable
Printable object that will be used when printing.| Constructor Detail |
private PrinterManager(java.awt.print.Printable printable)
PrinterManager.printable - The printable object to use.| Method Detail |
public static final void print(java.awt.print.Printable printable)
Printable object.
Printable object will do the job of correctly rendering what's needed to be printed.printable - The Printable object to use.public static final void print(java.lang.String text)
printable - The text to be printed.private void start()
public void run()
public void stop()
PrinterManager.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||