views:

32

answers:

1

Hi

If i design a JFrame/JPanel with labels, tables, textfields etc, is it possible to print it as it looks on screen?

If so, what size parameters should i keep in mind? Considering it's an A4 page, how should i go about sizing my JFrame/JPanel?

Thank you. : )

+1  A: 

Have a look at the printing example at Exampledepot: The Quintessential Printing Program Using a Printing Service.

Use this in conjunction with SwingUtilities.paintComponent to draw the image you want to print.

aioobe