PDA

View Full Version : QPrintDialog lists no printers



TMan
27th July 2007, 15:29
Hi all,

I'm trying to print something from my application, but the QPrintDialog shows no printers, whereas for instance kwrite does show a list of printers.

Running lpstat -a shows a (correct) list of available printers, and CUPS is installed correctly.

This is on a Debian 4.0 system with 2.6.20.1 kernel and Qt 4.3.0. I believe Qt was configured with cups support, but running
find /usr/local/Trolltech/ | grep cups shows nothing. On the other hand, I don't know if it should.

Any help/directions?

Thanks on this friday-afternoon-on-which-I-greatly-dislike-stupid-problems (don't we all).

jpn
27th July 2007, 20:56
I believe Qt was configured with cups support
Could you check configure output to assure that cups support was enabled?

TMan
28th July 2007, 13:40
Could you check configure output to assure that cups support was enabled?

I'll do that next monday when I'm back at work. However, cups is by default enabled and I'm 100% sure I didn't disable it. Will check anyway.

TMan
30th July 2007, 09:38
Hmm, it seems cups support is disabled after all.

Looks to me like Qt disables cups because I configure with -static. Is there a way to build Qt static and still enable cups support?

TMan
30th July 2007, 10:06
Ah, problem solved.

I missed the cups development files, so the config test failed. Problem probably solved :)

alexi_nedo
9th June 2009, 15:13
I have the same problem. In linux, in the QPrintDialog only Print to File option is visible.
(Print to PDF and Print to PS). No printer is listed.

How did you solve the problem?

TMan
9th June 2009, 16:33
You need to install the cups development packages on your system, then reconfigure Qt with cups support and recompile/install.

At least, that's what I did IIRC.