0

If I click on the main JFrame, the Java print dialog is hidden and input is blocked. I tried switching from PrinterJob printDialog() to ServiceUI.printDialog(). I also tried ServiceUIFactory factory = printService.getServiceUIFactory() but that returns null; How can I keep the dialog on top or make it non-modal?

The JDK is frozen at 1.7 due to inaccessible kiosks. The window manager is FVWM.

Thanks

PrintService[] services = PrintServiceLookup.lookupPrintServices(null, null);
PrintService printService = PrintServiceLookup.lookupDefaultPrintService();
PrintRequestAttributeSet attrs = new HashPrintRequestAttributeSet();
//attrs.add...
PrintService service = ServiceUI.printDialog(null, 100, 100, services, printService, null, attrs);
Syscall
  • 19,327
  • 10
  • 37
  • 52
  • I tried this with Java 1.7.0_79, Debian, and Gnome 3.30.2, and the print dialog was in front of all windows. What window manager/desktop environment are you using? – VGR Jun 24 '20 at 19:56
  • The window manager is FVWM. I meant to mention that but forgot. I'll add that. – William Dickerson Jun 24 '20 at 21:21
  • I changed the runlevel so now the window manager is GNOME. Now the print dialog stays on top. If I click on the print dialog in the taskbar, it minimizes and the only available actions are right click/close or slow double click which restored the dialog. – William Dickerson Jun 24 '20 at 22:08
  • I commented the transient window config I had set for the login dialog. Now the print dialog stays on top like in GNOME. Now I can concentrate on the FVWM config instead of the print dialog. Thanks VGR! How do I upvote your help? – William Dickerson Jun 24 '20 at 23:06
  • You can upvote comments, by clicking the ⏶ that appears right before the respective comment. It is common to say “that helped, make it answer and I’ll accept it,” but in this case, my comment isn’t really an answer. However, it is permissible (and encouraged) for you to answer your own question once you have a solution. – VGR Jun 25 '20 at 00:40

1 Answers1

0

The problem was transient window settings in the window manager FVWM. When VGR tried Gnome, that pointed me to the window manager.

Commented DontRaiseTransient in globalfeel.

#Style * DontRaiseTransient