[kepler-dev] Kepler snapshot capability
Lisong Sun
lisong.sun at pnl.gov
Tue May 29 16:43:33 PDT 2007
Dear Kepler developers,
Our project needs to generate a thumbnail kind of snapshot of current
workflow so that people can have a preview of the workflow in our
workflow organizer application before open it with Kepler. I found that
the Print menu option can be used for export a ps file of current
workflow window but it won't work for our case. I wonder if the snapshot
generation/export capability or function is available anywhere? If not,
is there any possible solution you can suggest?
Thanks.
Lisong Sun
Pacific Northwest National Lab.
======================================
Print function from Top.java
/** Print the contents. If this frame implements either the
* Printable or Pageable then those interfaces are used to print
* it.
*/
protected void _print() {
PrinterJob job = PrinterJob.getPrinterJob();
if (this instanceof Pageable) {
job.setPageable((Pageable) this);
} else if (this instanceof Printable) {
PageFormat format = job.pageDialog(job.defaultPage());
job.setPrintable((Printable) this, format);
} else {
// Can't print it.
return;
}
if (job.printDialog()) {
try {
job.print();
} catch (Exception ex) {
MessageHandler.error("Printing Failed", ex);
}
}
}
More information about the Kepler-dev
mailing list