Win a copy of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

font size with PrintJob  RSS feed

 
Francois Tardif
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I have the following problem :
I'm using ICE Browser, the web page I'm on is like a form.
In ICE I see it perfectly, but when I print it the size of the font almost double and the input box get also bigger. Since I must use jdk 1.1 here my code for the printing :
private void imprimer(){
StormPrinter p = pilot.createPrinter(); //stormprinter come from ice
PrintJob pj = Toolkit.getDefaultToolkit().getPrintJob(oMainFrame,"Impression",printProps);
p.setPageSize(629,735);
while(p.layoutNextPage()){
Graphics g = pj.getGraphics();
g.translate(5,5);
p.printPage(g);
g.dispose();
}
pj.end();
p.dispose();
}
Is there anything I'm doing wrong, or is it a bug in Java 1.1 or maybe in ICE?
Thanks in advance
Frank
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!