Changes

Jump to navigation Jump to search
2,738 bytes added ,  15:37, 21 November 2005
</texcode>
If you are including graphics made by an external program, you might want to match the colour name used in the graphic with the colour name in your '''ConTeXt ''' set-up so that only one colour space is used in the final file. Unfortunately Pantone names and others tend to have spaces and numbers in them, so you need to do a low-level mapping trick from your base name to the name you want embedded in the file:
<cmd>doregisterspotcolorname</cmd><tt>{PantoneTwoNineFour}{PANTONE 294 CV}</tt>
Now your output file should work beautifully with graphics embedded!
 
Regarding the use of <cmd>doregisterspotcolorname</cmd>, you can now use the 'e' key when defining your spot colours in order to specify the precise colour names to be used by your ConTeXt set-up in the output file. For example:
 
<texcode>
% Define spot colours using 'e=....' to specify colour name to use
% in output file
\definecolor
[PantoneThreeZeroEight]
[c=1,m=.05,y=0,k=.47,e=PANTONE 308 CV]
 
\definecolor
[PantoneTwoNineEight]
[c=.69,m=.07,y=0,k=0,e=PANTONE 298 CV]
 
% Define tints of spot colours to be used in document for colouring text
\definecolor
[DarkBlue]
[PantoneThreeZeroEight]
[p=1]
 
\definecolor
[LightBlue]
[PantoneTwoNineEight]
[p=1]
</texcode>
 
(Tested only on minimal Linux distribution dated 31 Aug 2005 - can others confirm this
to be true across the board now?)
 
Any text between a <cmd>startcolor[DarkBlue]</cmd> and <cmd>stopcolor</cmd> should now be assigned to the correct spot colour channel - Pantone 308 CV - on output. More importantly if you include an external figure containing areas of this colour then your text and those parts of the graphic which have the same colour should now appear together in the 'Pantone 308 CV' colour channel on colour separation.
 
For example, if your original graphic is an EPS file containing the following lines:
 
%%DocumentCustomColors: (PANTONE 298 CV)
%%+ (PANTONE 308 CV)
%%CMYKCustomColor: 0.69 0.07 0 0 (PANTONE 298 CV)
%%+ 1 0.05 0 0.47 (PANTONE 308 CV)
 
and you convert this to a PDF using <tt>ps2pdf</tt> for inclusion in your '''ConTeXt''' document your PDF graphic will then contain something like:
 
<code>
8 0 obj
[/Separation
/PANTONE#20308#20CV
/DeviceCMYK
9 0 R]endobj
10 0 obj
[/Separation
/PANTONE#20298#20CV
/DeviceCMYK
11 0 R]endobj
</code>
 
Note how the space characters in the colour name are now encoded as '#20', but the colour names are essentially identical between the original EPS graphic, the new PDF graphic and your text.
 
A good way of testing colour separation if you don't have access to expensive pre-flight PDF validation tools is to use the following GhostScript command:
 
gs \
-dBATCH \
-dNOPAUSE \
-sDEVICE=tiffsep \
-dDOINTERPOLATE \
-dTextAlphaBits=4 \
-dGraphicsAlphaBits=4 \
-sOutputFile=output.tif \
-r120 \
-MaxSeparations=8 \
input.pdf
 
This renders a PDF file <tt>input.pdf</tt> as a set of TIFF files:
 
output.tif - Composite including CMYK approximations to spot colours
output.tif.Black.tif - K channel
output.tif.Cyan.tif - C channel
output.tif.Magenta.tif - M channel
output.tif.Yellow.tif - Y channel
output.tif.s0.tif - Pantone 308 CV
output.tif.s1.tif - Pantone 298 CV
=Multitones=

Navigation menu