|
|
} bind | } bind |
.dicttomark readonly def | .dicttomark readonly def |
| |
% Define the keys used in input attribute matching. |
% M. Sweet, Easy Software Products: |
/.inputattrkeys [ |
% |
/PageSize /MediaColor /MediaWeight /MediaType /InsertSheet /ManualFeed |
% Define NOMEDIAATTRS to turn off the default (but unimplementable) media |
% The following are documented in Adobe's supplement for v2017. |
% selection policies for setpagedevice. This is used by CUPS to support |
/LeadingEdge /MediaClass |
% the standard Adobe media attributes. |
] readonly def |
NOMEDIAATTRS { |
% Define other keys used in media selection. |
% Define only PageSize for input attribute matching. |
/.inputselectionkeys [ |
/.inputattrkeys [ |
/MediaPosition /Orientation |
/PageSize |
] readonly def |
] readonly def |
|
% Define no other keys used in media selection. |
% Define the keys used in output attribute matching. |
/.inputselectionkeys [ |
/.outputattrkeys [ |
/noInputSelectionsKeys |
/OutputType |
] readonly def |
] readonly def |
|
|
% Define no keys used in output attribute matching. |
|
/.outputattrkeys [ |
|
/noOutputAttrKeys |
|
] readonly def |
|
} { |
|
% Define the keys used in input attribute matching. |
|
/.inputattrkeys [ |
|
/PageSize /MediaColor /MediaWeight /MediaType /InsertSheet /ManualFeed |
|
% The following are documented in Adobe's supplement for v2017. |
|
/LeadingEdge /MediaClass |
|
] readonly def |
|
% Define other keys used in media selection. |
|
/.inputselectionkeys [ |
|
/MediaPosition /Orientation |
|
] readonly def |
|
|
|
% Define the keys used in output attribute matching. |
|
/.outputattrkeys [ |
|
/OutputType |
|
] readonly def |
|
} ifelse |
| |
% Define all the parameters that should always be copied to the merged | % Define all the parameters that should always be copied to the merged |
% dictionary. | % dictionary. |
|
|
% They are expected to consume the top 2 operands. | % They are expected to consume the top 2 operands. |
% NOTE: we currently treat all values other than 0, 1, or 7 (for PageSize) | % NOTE: we currently treat all values other than 0, 1, or 7 (for PageSize) |
% the same as 0, i.e., we signal an error. | % the same as 0, i.e., we signal an error. |
|
% |
|
% M. Sweet, Easy Software Products: |
|
% |
|
% Define NOMEDIAATTRS to turn off the default (but unimplementable) media |
|
% selection policies for setpagedevice. This is used by CUPS to support |
|
% the standard Adobe media attributes. |
|
SETPDDEBUG { (Rolling back.) = pstack flush } if |
0 { % Set errorinfo and signal a configurationerror. | 0 { % Set errorinfo and signal a configurationerror. |
pop dup 4 index exch get 2 array astore |
NOMEDIAATTRS { |
$error /errorinfo 3 -1 roll put |
% NOMEDIAATTRS means that the default policy is 7... |
cleartomark |
pop 2 index exch 7 put |
|
} { |
|
pop dup 4 index exch get 2 array astore |
|
$error /errorinfo 3 -1 roll put |
|
cleartomark |
/setpagedevice .systemvar /configurationerror signalerror | /setpagedevice .systemvar /configurationerror signalerror |
|
} ifelse |
} bind | } bind |
1 { % Roll back the failed request to its previous status. | 1 { % Roll back the failed request to its previous status. |
SETPDDEBUG { (Rolling back.) = pstack flush } if | SETPDDEBUG { (Rolling back.) = pstack flush } if |