Bug 53078 - printing x copies makes 1 document, not x individual documents
Summary: printing x copies makes 1 document, not x individual documents
Status: CLOSED NOT A BUG
Alias: None
Product: kdeprint
Classification: Applications
Component: kdeprintfax (show other bugs)
Version: unspecified
Platform: Compiled Sources Linux
: NOR normal
Target Milestone: ---
Assignee: Michael Goffioul
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-01-16 21:44 UTC by Andrew Kohlsmith
Modified: 2008-12-31 12:41 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
ir330400.ppd.gz (9.71 KB, application/x-gzip)
2003-01-17 18:19 UTC, Andrew Kohlsmith
Details
driverselection.png (9.54 KB, image/png)
2003-01-17 18:55 UTC, Andrew Kohlsmith
Details
driversettings.png (20.57 KB, image/png)
2003-01-17 18:55 UTC, Andrew Kohlsmith
Details
printerproperties.png (14.24 KB, image/png)
2003-01-17 18:55 UTC, Andrew Kohlsmith
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Andrew Kohlsmith 2003-01-16 21:44:19 UTC
Version:           20030115 CVS pull (using KDE Devel)
Installed from:    Compiled sources
Compiler:          gcc 3.1 
OS:          Linux

I'm printing from staroffice, but printing from anywhere does the same thing (kedit, kword, adobe acroread, etc.)

If I select more than one copy and leave "collate" clicked, I get one logical document which contains x copies of the document I'm printing.  I am using Cups 1.1.15 with the "Postscript" printer driver.  (The printers in question are all high end photocopier/printer/document systems, Canon ImageRunners)

The Canon shows that I have one 96 page document in the queue instead of 12 copies of one 4 page document.  Cups sees a singular 96 page document as well.

This screws up the collation, especially since one of the documents I printed was 7 pages, not 8, and the duplexing feature ended up putting page 1 of the next copy on the back of page 7.  Not fun.  :-(
Comment 1 Michael Goffioul 2003-01-17 14:51:05 UTC
This is how CUPS works, and has nothing to do with KDEPrint. When you
send a print job with a given number of copies requested, CUPS will
create only a single job containing all the copies, whether they are
collated or not. KDEPrint does not control that part, it just send
a PS file to the print system, requesting a number of copies, along
with a set of print options. You should probably contact the CUPS
author about that problem.

Michael.
Comment 2 Andrew Kohlsmith 2003-01-17 16:23:29 UTC
Subject: Re:  printing x copies makes 1 document, not x individual documents

> This is how CUPS works, and has nothing to do with KDEPrint. When you
> send a print job with a given number of copies requested, CUPS will
> create only a single job containing all the copies, whether they are
> collated or not. KDEPrint does not control that part, it just send
> a PS file to the print system, requesting a number of copies, along
> with a set of print options. You should probably contact the CUPS
> author about that problem.

You are at least partically correct.  I have posted the question to the 
CUPS-general mailing list and received this answer:

Andrew Kohlsmith:
>> I am guessing it is a CUPS issue because if I print 5 copies of a
>> document in KDE, but specify "print to postscript" instead of the CUPS
>> printer and then look at the resultant .ps file, I see
>> 
>> %%BeginSetup
>> /#copies 5 def
>> /NumCopies 5 SPD
>> /Collate false SPD
>> 
>> So as far as I can tell KDE is giving the correct information (x
>> copies of this document).

Michael Sweet:
> No, it's not.  Embedding the number of copies this way hides them
> from CUPS (at least the current release) because it uses the
> copies attribute submitted with the job and not the copies option
> that is embedded in the PS file.
> 
> The correct way for KDE to specify the number of copies is to use
> the corresponding printing system option (lpr -#, lp -n, etc.)
> and not to embed it into the PostScript it produces.

As it's a simple case of "KDE is probably doing what is technically correct, 
but CUPS is not there yet" I wonder if it would be best if I wrote a filter 
to find the number of copies in the postscript data that kprinter produces 
and specify that information directly to CUPS via lpr.  I believe that this 
also explains why I can't turn off double sided printing from KDE (it is 
enabled in CUPS).  

CUPS is a great printing system, just not too bright yet it seems.  :-)

Regards,
Andrew

Comment 3 Michael Goffioul 2003-01-17 17:37:44 UTC
See my answer on cups.general newsgroup.

Michael.
Comment 4 Andrew Kohlsmith 2003-01-17 18:19:35 UTC
Subject: Re:  printing x copies makes 1 document, not x individual documents

> See my answer on cups.general newsgroup.

Ok.  Here is my PPD file for the Canon ImageRunner 330-400pspcl which was 
obtained from the win2k driver.

Regards,
Andrew


Created an attachment (id=774)
ir330400.ppd.gz
Comment 5 Michael Goffioul 2003-01-17 18:29:26 UTC
I think that about the duplexing problem, you met the following situation:
Duplex is set to "short Edge" in CUPS, and when you open the printer
properties dialog, the duplex options is grayed out. If this correct,
then this is due to the fact that the PPD file describe the duplex option
using a "non-standard" keyword. The duplex option (in the first page of
the printer properties dialog) is bound to a standard option, according
to the Adobe specification, named "Duplex". Your PPD file uses "EFDuplexing".
So KDEPrint doesn't find the option it wants to, and just grey out the
duplex selection box. HOWEVER, all options from the PPD file are still
accessible in the "Driver Settings" page, where you can change the
duplex option.

So to be short, you can still change duplex in the driver options, but
KDEPrint doesn't find the standard option to bind it to its GUI. Note that
they may be as many different keyword for duplex as you have printers
on the market, so it's impossible to implement it in a safe way that'll
work in all cases.

Michael.
Comment 6 Andrew Kohlsmith 2003-01-17 18:55:59 UTC
Subject: Re:  printing x copies makes 1 document, not x individual documents

> I think that about the duplexing problem, you met the following situation:
> Duplex is set to "short Edge" in CUPS, and when you open the printer
> properties dialog, the duplex options is grayed out. If this correct,
> then this is due to the fact that the PPD file describe the duplex option
> using a "non-standard" keyword. The duplex option (in the first page of
> the printer properties dialog) is bound to a standard option, according
> to the Adobe specification, named "Duplex". Your PPD file uses
> "EFDuplexing". So KDEPrint doesn't find the option it wants to, and just
> grey out the duplex selection box. HOWEVER, all options from the PPD file
> are still accessible in the "Driver Settings" page, where you can change
> the duplex option.

Hmm ok, I can live with that.  Are there any plans to put the Adobe standard 
Finishing options (staple, hole-punch, saddle-stich, trifold) in the KDE 
dialog?  :-)  (is finishing part of the standard?)

Is there an easier way to get to the "Driver Settings" page without going to 
the Printing Manager, selecting the printer, selecting the "Properties" tab, 
clicking on Driver and then clicking on "Change" to bring up the relevant bit 
of the wizard?  I'm running CVS HEAD if it makes any difference.

I tried going to the Instances tab and clicking on "Settings..." but it 
doesn't do anything at all.

> So to be short, you can still change duplex in the driver options, but
> KDEPrint doesn't find the standard option to bind it to its GUI. Note that
> they may be as many different keyword for duplex as you have printers
> on the market, so it's impossible to implement it in a safe way that'll
> work in all cases.

That works just fine for me, but KDEPrint isn't graying it out at all, CUPS 
just seems to be ignoring whatever I put there (your explanation still 
holds).

By the way, I have discovered that if I set KDE's printing dialog to NOT 
collate the pages, I get the correct number of pages for each set.

With collate turned on  (and the CUPS driver finishing set to collate) the 
problem I had was that if I had a 3 page document and I asked it to print 4 
times, I would get this out of the copier:

Page1|Page2			Page1|Page2
Page3|Page1			Page3|Page1
Page2|Page3			Page2|Page3
Page1|Page2			Page1|Page2
Page3				Page3

Page1|Page2			Page1|Page2
Page3|Page1			Page3|Page1
Page2|Page3			Page2|Page3
Page1|Page2			Page1|Page2
Page3				Page3

(i.e. 4 sets as I asked for, but each document was repeated 4 times in each 
set)

If I had that same 3 page document and asked for two copies I would get

Page1|Page2			Page1|Page2
Page3|Page1			Page3|Page1
Page2|Page3			Page2|Page3

(the number of repetitions in each document set was the same as the number of 
copies requested)

With KDE's "Collate" checkbox NOT checked, I get the desired output from the 
printer.  That is _weird_, but I have no explanation for it other than it may 
be that CUPS is getting confused by KDE asking (in the standard way) for 
collating, and the printer PPD already providing something.  The printer 
thinks that the document has only 3 pages, when it is actually printing out 
12 or 6 (in the examples above) in each set.  Very strange.

One question I do have (now that I've been fiddling with this for a while) -- 
what is the purpose of the "Additional Tags" tab?  What can be done there, 
setting additional tags as found in the PPD?

Thank you so much for your help in this.

Regards,
Andrew

Created an attachment (id=775)
driverselection.png

Created an attachment (id=776)
driversettings.png

Created an attachment (id=777)
printerproperties.png
Comment 7 Michael Goffioul 2003-01-18 02:29:17 UTC
> Hmm ok, I can live with that. Are there any plans to put the Adobe standard 
> Finishing options (staple, hole-punch, saddle-stich, trifold) in the KDE 
> dialog? :-) (is finishing part of the standard?) 

No, those options are available in the driver tab. Adding specific GUI for
these looks quite useless to me as they are (high-end) printer specific
and would be greyed out most of the time. Moreover you cannot rely on a
standard option keyword name to bind it to the GUI.

> Is there an easier way to get to the "Driver Settings" page without going to 
> the Printing Manager, selecting the printer, selecting the "Properties" tab, 
> clicking on Driver and then clicking on "Change" to bring up the relevant bit 
> of the wizard? I'm running CVS HEAD if it makes any difference.

Select the printer, right-click, choose configure, this brings you a dialog
where you can configure the driver.

> I tried going to the Instances tab and clicking on "Settings..." but it 
> doesn't do anything at all. 

It should :-( Note that an instance is a different concept: it's not a
printer on its own, it's the associtation of a printer with a set a
predefined options.

> That works just fine for me, but KDEPrint isn't graying it out at all, CUPS 
> just seems to be ignoring whatever I put there (your explanation still 
> holds). 

The duplex group box should be greyed out. At least it is the case for me.
I created a fake printer with the PPD file you sent me, and duplex is greyed
out. That's strange.

About collate problem, I'll investigate that on monday (I'm home now).

> One question I do have (now that I've been fiddling with this for a while) -- 
> what is the purpose of the "Additional Tags" tab? What can be done there, 
> setting additional tags as found in the PPD? 

This is to tag a print job arbitrarily. This is useful for example in
business environment where all printing are centralized in a printing
department: those additional tags can help the guy who does the actual
printing by giving some additional information (for example the color
of the paper to use). It doesn't have any effect, it's just additional
info. You can view all print job attributes from the job viewer, using
the action "Job IPP report".

Michael.
Comment 8 Michael Goffioul 2003-01-20 10:40:49 UTC
Subject: Re:  printing x copies makes 1 document, not x individual 
 documents

> Is there an easier way to get to the "Driver Settings" page without going to
> the Printing Manager, selecting the printer, selecting the "Properties" tab,
> clicking on Driver and then clicking on "Change" to bring up the relevant bit
> of the wizard?  I'm running CVS HEAD if it makes any difference.

I forgot to add that you should be able to change the driver settings
directly from the application. For example in konqueror, in the print
dialog, edit the printer properties, and use the "Driver Settings"
tab.

If you don't have such a tab, then this may explain why the duplex
option is not greyed out as well, and is usually related to a CUPS
configuration problem: you may have some access restrictions defined
in your cupsd.conf that prevents KDEPrint from retrieving the
driver.

Michael.

Comment 9 John Layt 2008-12-31 12:41:16 UTC
Closing old Resolved status bug.