aspose file tools*
The moose likes Swing / AWT / SWT and the fly likes PageFormat and Paper A4 Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "PageFormat and Paper A4" Watch "PageFormat and Paper A4" New topic
Author

PageFormat and Paper A4

Ko Wey
Ranch Hand

Joined: Sep 08, 2003
Posts: 67
I am trying to print images (on A4 -paper, which is 21cm X 29.5cm.)
I do this:

and then in print

When I do the printing in "landscape", I get a 4.5 cm border between the
left sides of the paper and the image. Too much!


When I System.out.print the value pageFormat.getImageableX(), I get:

LANDSCAPE
26.18181818181813
PORTRAIT
39.27272727272727

Any customer or staff of this excellent saloon that knows the correct values?
Ko Wey
Ranch Hand

Joined: Sep 08, 2003
Posts: 67
Sorry, I forgot to mention:

(the values are 1/72 of an inch
and 1 inch = 2.54cm)
which should clarify my earlier code!
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: PageFormat and Paper A4