summaryrefslogtreecommitdiff
path: root/Master/tlpkg/tlgs/Resource/Init/gs_cspace.ps
diff options
context:
space:
mode:
Diffstat (limited to 'Master/tlpkg/tlgs/Resource/Init/gs_cspace.ps')
-rw-r--r--Master/tlpkg/tlgs/Resource/Init/gs_cspace.ps78
1 files changed, 3 insertions, 75 deletions
diff --git a/Master/tlpkg/tlgs/Resource/Init/gs_cspace.ps b/Master/tlpkg/tlgs/Resource/Init/gs_cspace.ps
index c612ea9acf4..ff5955a9577 100644
--- a/Master/tlpkg/tlgs/Resource/Init/gs_cspace.ps
+++ b/Master/tlpkg/tlgs/Resource/Init/gs_cspace.ps
@@ -1,4 +1,4 @@
-% Copyright (C) 2001-2018 Artifex Software, Inc.
+% Copyright (C) 2001-2019 Artifex Software, Inc.
% All Rights Reserved.
%
% This software is provided AS-IS with no warranty, either express or
@@ -62,19 +62,6 @@ end % colorspacedict
/DeviceCMYK_array /DeviceCMYK 1 array astore readonly def
%
-% - initgraphics -
-%
-% Although the internal routine gs_initgraphics resets the color space,
-% it does not reset the color space we store in the 'interpreter'
-% graphics state (so that we can hand it back in currentcolorspace).
-% So we need to do that in the PostScript world.
-%
-%
-/initgraphics
- { initgraphics systemdict /DeviceGray_array get setcolorspace }
-.bind odef
-
-%
% These routines used for the NOSUBSTDEVICECOLORS switch. This prevents
% substitution of DeviceGray, DeviceRGB and DeviceCMYK with a Default*
% colour space when /UseCIEColors is true. If the job includes a
@@ -92,6 +79,8 @@ end % colorspacedict
% If the boolean is true then the C code must set the additional colour space
% and execute .includecolorspace before finally setting a DeviceGray space.
%
+% called from C code, can't undef. Use this to trigger the code:
+% -sDEVICE=pkmraw -dMaxBitmap=4000m -r72 -dNOSUBSTDEVICECOLORS ./tests/Ghent_V3.0/110_defaultcolourspace_x3.pdf
/..nosubstdevicetest
{
//false mark 3 -1 roll
@@ -118,67 +107,6 @@ end % colorspacedict
} ifelse
}bind def
-%
-% <color_space_name> ..includecolorspace -
-%
-/..includecolorspace
-{
- % If we have already recorded this space, don't repeat it.
- systemdict /..page_default_spaces get 1 index known {
- pop
- } {
- mark exch
- {
- % Check to see if this space was defined by defineresource, if so then
- % the job defined it, otherwise its the usual default, so ignore it.
- dup /ColorSpace resourcestatus {
- pop 0 eq {
- % Job defined /Default*, so record it and allow the device access to it
- systemdict /..page_default_spaces get 1 index //true put
- gsave
- { dup /ColorSpace findresource //setcolorspace exec .includecolorspace
- } stopped pop
- grestore
- } if
- } if
- } stopped pop
- cleartomark
- } ifelse
-} bind def
-
-%
-% <color_space> <color_space_name> cs_substitute_generic <color_space1> <color_space2>
-%
-/cs_substitute_generic
-{ .getuseciecolor
- {NOSUBSTDEVICECOLORS
- { //..includecolorspace exec dup }
- { /ColorSpace findresource }
- ifelse
- }
- { pop dup }
- ifelse
-}
-bind def
-
-%
-% <color_space> <color_space_name> cs_substitute_DeviceRGB_for_PDFX_or_PDFA <color_space1> <color_space2>
-%
-/cs_substitute_DeviceRGB_for_PDFX_or_PDFA
-{ systemdict /PDFX .knownget not { //false } if
- systemdict /PDFA .knownget not { //false } {0 eq {//false}{//true} ifelse} ifelse
- or {
- dup /ColorSpace resourcestatus {
- pop pop
- } {
- (Error: Need a /DefaultRGB /ColorSpace resource for generating a PDF/X or PDF/A document.) =
- /cs_substitute_DeviceRGB_for_PDFX_or_PDFA cvx /undefined signalerror
- } ifelse
- /ColorSpace findresource
- } {
- //cs_substitute_generic exec
- } ifelse
-} bind def
end
%