[daip] Error(?) in postscript file.

Eric Greisen egreisen at nrao.edu
Wed Mar 11 14:56:13 EDT 2009


R. Craig Walker wrote:
> I am editing some postscript from LWPLA, PL file produced by KNTR.  A very
> early element in the file is a pair of lines giving moveto and lineto
> commands to delineate a box that exactly matches the bounding box.  That
> is followed on the second line by "fill stroke"  The sequence is preceded
> by setrgbcolor.  This appears to me to be an attempt to put a background
> on the full plot window.  However there is a hitch.  The "72 300 div dup
> scale" line is located earlier in the file.  So in fact what you get is
> this curious little box positioned below and to the left of the main plot,
> and mostly if not entirely outside of the bounding box.  It is very clear
> if you change the color from the default white, which you normally can't
> see when displaying the plot file because that is what the rendering
> engine puts there.  I have a bright red box now in the one I'm testing.  I
> suspect you'll get something closer to the desired effect by putting these
> lines ahead of the scaling line.
> 
> For whatever it's worth, there are both vectors and bitmaps in the file
> I'm talking about (contours and greys).

This background option comes from LWPLA itself and it seems to do it 
correctly - at least I just ran it on a PLOTR output and a KNTR output 
and in both cases the moverto, linetos, and fill stroke commands come 
before the scaling commands.  In your editing, did you accidentally 
reverse them?

Eric Greisen




More information about the Daip mailing list