kprinter -t option being ignored

Ian Chard ian.chard at sers.ox.ac.uk
Fri Apr 21 15:27:31 CEST 2006


Hi,

I'm using kprinter with CUPS on Solaris 10, and I'm trying to set the
job name.  However, using the -t (or -J) option with kprinter seems to
be ineffective, as I either get the filename or "<STDIN>".

I had a quick glance at the code, and in printwrapper.cpp the job name
does get set in PrintWrapper::slotPrint

        QString title = args->getOption("t");
	[...]
	kprinter.setDocName(title);

However, later on PrintWrapper::slotPrintRequested gets called, and the
first thing this does is

        // re-initialize docName
        kprinter->setDocName(QString::null);
	[...]
        if (filestoprint.count() > 1)
                kprinter->setDocName(i18n("Multiple files
(%1)").arg(filestoprint.count()));
        else if (kprinter->docName().isEmpty())
                kprinter->setDocName(force_stdin ? "<STDIN>" : "KPrinter");

Am I missing something here?  It's Friday afternoon and far too hot in
here, so I won't be surprised!

Thanks for any help or advice
- Ian

-- 
Ian Chard, Unix & Network Administrator   |  E: ian.chard at sers.ox.ac.uk
Systems and Electronic Resources Service  |  T:  80587 / (01865) 280587
Oxford University Library Services        |  F:          (01865) 242287


More information about the kde-print mailing list