This week's giveaway is in the Java/Jakarta EE forum.
We're giving away four copies of Java EE 8 High Performance and have Romain Manni-Bucau on-line!
See welcome thread
Win a copy of Java EE 8 High Performance this week in the Java/Jakarta EE forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

getting print settings  RSS feed

Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,

I've been working on an application work require, which prints a JPanel (and the contents of it) to a 4x4 inch label.

Ideally, the system needs to print silently, so I am trying to get all the print settings set correctly, however, I am having some trouble.

When the default printer on the computer is set to the label printer, my labels all appear to have a large margin, which pushes the information off the page. But if the default printer is the normal laser printer, and the label printer is selected by the user via the print dialog box, then the label prints perfectly on the label printer.

Similarly, regardless of the computers default printer, if I do a print service lookup and then set it to print on the label printer, I once again get the large margin, thus ruining my label.

I don't know what I should be doing here - is there a way of getting all the information (the properties of the printjob) after the print dialog has been closed by the user? Or can anyone suggest what might be wrong here?


How do they get the deer to cross at the signs? Or to read this tiny ad?
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!