B
Bastard
Im having a quite simple problem (?) Got this frame that I'd like to
print on a printer. But it's too big to fit the paper? I assume that
setting a higher resolution (dpi) for the printer should make the
output smaller - but no?! Im able to switch to landscape which helps a
bit, but not enough.
Please enlighten me.. Here is my example. parent is a Frame that
implements Printable.
PrinterJob printJob = PrinterJob.getPrinterJob();
printJob.setPrintable((Printable)parent);
PrintRequestAttributeSet set = new HashPrintRequestAttributeSet();
PrinterResolution res = new PrinterResolution(600, 600,
PrinterResolution.DPI);
set.add(res);
set.add(OrientationRequested.LANDSCAPE);
if(printJob.printDialog(set)){
try {
printJob.print(set);
}
catch (Exception PrinterExeption) { }
}
Thanks in advance,
Bastian
print on a printer. But it's too big to fit the paper? I assume that
setting a higher resolution (dpi) for the printer should make the
output smaller - but no?! Im able to switch to landscape which helps a
bit, but not enough.
Please enlighten me.. Here is my example. parent is a Frame that
implements Printable.
PrinterJob printJob = PrinterJob.getPrinterJob();
printJob.setPrintable((Printable)parent);
PrintRequestAttributeSet set = new HashPrintRequestAttributeSet();
PrinterResolution res = new PrinterResolution(600, 600,
PrinterResolution.DPI);
set.add(res);
set.add(OrientationRequested.LANDSCAPE);
if(printJob.printDialog(set)){
try {
printJob.print(set);
}
catch (Exception PrinterExeption) { }
}
Thanks in advance,
Bastian