[comp.lang.postscript] Color in OpenWindows pageview program?

montnaro@spyder.crd.ge.com (Skip Montanaro) (03/03/90)

I am using the pageview program that comes with Sun's OpenWindows to preview
the color PostScript file that appears at the end of this message. If I
image at 36, 72, or 100 dpi, it is shown in color. If I image at 150, 300,
or 400 dpi, however, it is shown in black and white. Can someone tell me if
this is a bug or a feature? Is there a workaround other than avoiding the
higher resolutions?

Thanks, and beware the trailing signature.

Skip (montanaro@crdgw1.ge.com)

%!

save /psnewssav exch def

% "@(#)drawlib.ps 1.1 12/19/89 Arthur van Hoff (Turing Institute)";

% -- drawlib.ps -- Header file for PostScript drawings.
/SC {dup length 3 eq {aload pop setrgbcolor} {aload pop setgray} ifelse} def
/MX {1 0 0 1} def
/CT {curveto} def
/CP {closepath} def
/LT {lineto} def
/PT {moveto} def
/PC {{lineto} stopped {moveto} if} def
/LN {0 0 PT LT} def
/LC {0 0 PC LT} def
/FL {SC fill} def
/ST {SC setlinewidth stroke} def
/FS {gsave FL grestore ST} def
/CM {matrix currentmatrix exch concat} def
/SM {setmatrix} def
/BO {gsave newpath concat} def
/EO {grestore} def
/SG {gsave SC eofill grestore ST} def
/FG {SC eofill} def

/AR {	%  c s a x y --
	newpath matrix currentmatrix 5 1 roll
	newpath translate rotate
	0 0 moveto 0 0 3 -1 roll -20 20 arc 0 0 lineto
	setmatrix FL
} def
/DA {	% x y --
	matrix currentmatrix 3 1 roll
	scale 0 1 1 -90 0 arc
	setmatrix
} def
/DR {	% w h --
	0 0 moveto
	exch dup 0 lineto
	1 index lineto
	0 exch lineto
	closepath
} def
/DO {	% w h --
	matrix currentmatrix 3 1 roll
	scale 0.5 0.5 translate 0 0 0.5 0 360 arc
	setmatrix
} def
/RR {	% w h c --
	10 dict begin /c exch def /h exch def /w exch def
	c 0 moveto
	mark
	w 0 w h c arcto
	w h 0 h c arcto
	0 h 0 0 c arcto
	0 0 w 0 c arcto
	cleartomark closepath
	end
} def
/DP {	% d1 d2 w h --
	matrix currentmatrix 5 1 roll scale
	0.5 0.5 moveto
	0.5 0.5 0.5 5 -2 roll arc
	0.5 0.5 lineto
	setmatrix
} def
/SF {	% text col fontsize font -- text width
	findfont exch scalefont setfont SC
	1 1 index {stringwidth pop abs 2 copy lt {exch} if pop} forall
} def
/TS {	% width w h --
	exch 2 index div exch scale
} def
/TL {	% text w h lh --
	5 dict begin /h exch def 0 exch moveto pop
	{gsave show grestore 0 h rmoveto} forall
	end
} def
/TR {	% text w h bh --
	5 dict begin /h exch def moveto 
	{ gsave dup stringwidth pop neg 0 rmoveto show 
	  grestore 0 h rmoveto} forall
	end
} def
/TC {	% text w h bh --
	5 dict begin /h exch def 
	exch 2 div exch moveto 
	{ gsave dup stringwidth pop 2 div neg 0 rmoveto show 
	  grestore 0 h rmoveto} forall
	end
} def
/IR {	% w h
	DR gsave 1 setgray fill grestore 0 setgray stroke
} def
/IC {	% str w h --
	scale LoadImage imagecanvas
} def
/IM {	% ... --
	/pstr exch string def
	0 exch translate scale
	{} settransfer
	0 0 3 -1 roll 0 0 6 array astore
	{currentfile pstr readhexstring pop} image
} def
/EPSdict 10 dict begin
/initmatrix {
	#Matrisk# setmatrix 
} def
/initgraphics {
	systemdict /initgraphics get exec 
	#Matrisk# setmatrix 
} def
/showpage {} def
currentdict end def
/BEPS {
	save 5 1 roll
	EPSdict begin
	gsave scale translate
	matrix currentmatrix /#Matrisk# exch def
	systemdict /initgraphics get exec
	#Matrisk# setmatrix
	500 dict begin
} def
/EEPS {
	end grestore end
	restore
} def
gsave initmatrix -172.180 -206.580 translate
0.820 0.820 scale
[1 0 0 1 0 0 ] BO
1166 1470 DR
[.7891 1 0.058] FL
EO
[1 0 0 1 399 958 ] BO
[1 0 0 1 9 9 ] BO
30 30 DO
1 [0 0 1] ST
EO
[1 0 0 1 0 0 ] BO
48 48 DO
1 [1 .6305 .1929] ST
EO
[1 0 0 1 25 24 ] BO
0 15 LN
1 [1 .6305 .1929] ST
EO
[1 0 0 1 25 24 ] BO
14 0 LN
1 [1 .6305 .1929] ST
EO
EO
[1 0 0 1 472 938 ] BO
[1 0 0 1 0 36 ] BO
195 0 LN
4 [1 0 0.03] ST
EO
[1 0 0 1 56 78 ] BO
0 -77 LN
4 [1 0 0.03] ST
EO
[1 0 0 1 140 78 ] BO
0 -78 LN
4 [1 0 0.03] ST
EO
[1 0 0 1 2 36 ] BO
54 40 DA
4 [1 0 0.03] ST
EO
[1 0 0 1 193 36 ] BO
-53 38 DA
4 [1 0 0.03] ST
EO
[1 0 0 1 102 50 ] BO
38 26 DA
4 [1 0 0.03] ST
EO
[1 0 0 1 102 50 ] BO
-46 24 DA
4 [1 0 0.03] ST
EO
EO
showpage grestore psnewssav restore
--
Skip (montanaro@crdgw1.ge.com)