You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Mar 10, 2026. It is now read-only.
Repository navigation
This repository was archived by the owner on Mar 10, 2026. It is now read-only.
When a printer is set up with a PPD (rather than using an IPP Everywhere printer), CUPS internally maps (some) PPD options to respective IPP attributes.
Among others, this makes it possible to access the device capabilites without using the deprecated PPD API. Options that are not mapped to IPP attributes are still unavailable, as recently discussed in the thread "PPD API: Status, future and alternatives to handle printer-specific options" on the CUPS mailing list. [1], [2]
The output of ipptool -t -v ipp://localhost/printers/myprinter get-printer-attributes.test > ipptool_output_attributes_Ricoh_MP_C5504.txt (where "myprinter" has been set up with the attached PPD file of a RICOH MP C5504) is attached.
The following line indicates that stapling is supported:
finishings-supported (1setOf enum) = none,staple
The PPD file provides various possibilities for stapling (PPD keyword "StapleLocation"). However, when this is mapped to IPP attributes, the only option that is available is to enable or disable stapling (no more detailed options like where to staple).
As suggested on the CUPS mailing list [1], I am asking to support more (non-standard) keywords to map stapling options from the PPD to respective IPP attributes.
(Note: I used cups 2.2.2 on Debian experimental for testing.)
OK, so right now CUPS depends on the cupsIPPFinishings keyword to provide the vendor-specific mapping of finishing options in the PPD to the corresponding IPP finishing templates.
Will look at updating _ppdCacheCreateWithPPD and cupsd's load_ppd to support better heuristics when dealing with PPDs not optimized for use with CUPS, and (for cupsd) to use the cupsIPPFinishings attribute (when present) when populating the finishings-supported attribute.
So what kind of values can I expect from the option finishings when I parse it from the output of lpoptions? I see it usually is 3 when there are no finishings but what value does it have when there are finishings? Will it be a string or an array of magic numbers that stand for some combination of finishings?
@douira The lpoptions output will show the default value, so 3 is 'none', 4 is 'staple', 5 is 'punch', etc., just as show in the IANA IPP registry. Multiple values can typically be used ("4,5" to staple and punch holes), although that (obviously) depends on the printer and values.
Activity
michaelweghorn commentedon Feb 7, 2017
These are the mentioned attachments (PPD and output of
ipptool):Ricoh-MPC5504-Postscript-deutsch-V1.2.ppd.txt
ipptool_output_attributes_Ricoh_MP_C5504.txt
michaelrsweet commentedon Mar 8, 2017
OK, so right now CUPS depends on the cupsIPPFinishings keyword to provide the vendor-specific mapping of finishing options in the PPD to the corresponding IPP finishing templates.
Will look at updating _ppdCacheCreateWithPPD and cupsd's load_ppd to support better heuristics when dealing with PPDs not optimized for use with CUPS, and (for cupsd) to use the cupsIPPFinishings attribute (when present) when populating the finishings-supported attribute.
First half of the changes for Issue #4960, Issue #4961, and Issue #4962…
Report finishings based on the PPD cache (Issue #4960, Issue #4961, I…
michaelrsweet commentedon Mar 9, 2017
Changes in TOT...
douira commentedon Aug 18, 2019
So what kind of values can I expect from the option
finishingswhen I parse it from the output oflpoptions? I see it usually is 3 when there are no finishings but what value does it have when there are finishings? Will it be a string or an array of magic numbers that stand for some combination of finishings?michaelrsweet commentedon Aug 19, 2019
@douira The lpoptions output will show the default value, so 3 is 'none', 4 is 'staple', 5 is 'punch', etc., just as show in the IANA IPP registry. Multiple values can typically be used ("4,5" to staple and punch holes), although that (obviously) depends on the printer and values.