On 10/10/14 20:38, Alex Korobkin wrote:
I don't know. How do PPDs for real PostScript printers (i.e. not
Foomatic) with hardware copying look like?
Ok, I see. This truly doesn't seem to make much sense, even with my
limited understanding of PJL...
I'm not sure why Koji Otani wrote it like that, or whether this
order was purposely chosen.
Are there PPDs which depend on this (strange) ordering?
Yes, that's what I would expect.
I took a look into what pstops.c does beside of generic PPD
handling, and I found this:
/*
* Tell the document processor the copy and duplex options
* that are required...
*/
doc_printf(doc, "%%%%Requirements: numcopies(%d)%s%s\n",
doc->copies,
doc->collate ? " collate" : "",
Duplex ? " duplex" : "");
/*
* Apple uses RBI comments for various non-PPD options...
*/
doc_printf(doc, "%%RBINumCopies: %d\n", doc->copies);
}
and
doc_printf(doc,
"%%RBIBeginNonPPDFeature: *NumCopies %d\n", doc->copies);
doc_printf(doc,
"%d/languagelevel where{pop languagelevel 2
ge}{false}ifelse\n"
"{1 dict begin/NumCopies exch def currentdict end "
"setpagedevice}\n"
"{userdict/#copies 3 -1 roll put}ifelse\n",
doc->copies);
doc_puts(doc, "%RBIEndNonPPDFeature\n");
But foomatic based filters use *Copies in their PPD instead.... with
the rather dumb "let's repeat the line for 1...100 copies". I've
seen a similar approach in one other PPD (for a real postscript
printer, IIRC) on the web; the only difference was, that it used
*JCLOpenUI instead of *OpenUI, etc.
You wrote in one of your earlier mails:
Making a "Number of Copies" dialog doesn't
seem to be a great idea, because users will never notice that.
They will keep setting the number of copies in the usual place in
GUI.
Are you basically saying that Foomatic-PPDs "breaks" the GUI in the
same way as using *Copies for pdftopdf?
Does using *Copies with pdftopdf actually work -- or isn't it
actually suffering from the same ordering problem you described for
*pdftopdfJCLCopies?
I do agree that pdftopdf has to add the hardware copies code.
And, as you have see, Koji Otani has implement PPD-based
JCL-insertion in pdftopdf and imagetopdf.
But now you are suggesting that this implementation is basically
broken-by-design (?).
What is your proposed change wrt. to the already existing
implementation/design?
Tobias