xmlgraphics-general mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jeremias Maerki <...@jeremias-maerki.ch>
Subject Re: EPSDocumentGraphics2D: "Error: /rangecheck in --setmiterlimit--"
Date Mon, 29 May 2006 13:04:23 GMT
On one side, it is good to see that moving the PostScript Graphics2D
implementation to XML Graphics Commons has already caused someone to use
it as a stand-alone component. That was one of the goals.

On the other side, what you're seeing is probably the effect that
PSGraphics2D was written specifically as a backend for Batik. It seems
that somehow the miter limit on a BasicStroke instance was set to 0.
However, the PS language reference says that only values >=1 are valid.
The interesting thing is that BasicStroke (Sun JVM) has a check that
makes sure the miterlimit value does not go below 1. I wonder how this
happened. Anyway, I've improved the code in Commons a little. Please
verify that it's better now.

http://svn.apache.org/viewvc?rev=410093&view=rev

On 27.05.2006 18:18:12 Thomas Maier wrote:
> Hi all,
> 
> I have just used XMLGraphics Commons for the first time and it worked
> almost great :).  When I try to display the EPS file, ghostscript
> complains with
> 
> Error: /rangecheck in --setmiterlimit--
> Operand stack:
>    0
> Execution stack:
>    %interp_exit   .runexec2   --nostringval--   --nostringval--   --nostringval--   2
  %stopped_push   --nostringval--   --nostringval--   --nostringval--   false   1   %stopped_push
  1   3   %oparray_pop   1   3   %oparray_pop   --nostringval--   1   3   %oparray_pop   1
  3   %oparray_pop   .runexec2   --nostringval--   --nostringval--   --nostringval--   2 
 %stopped_push   --nostringval--
> Dictionary stack:
>    --dict:1119/1686(ro)(G)--   --dict:0/20(G)--   --dict:114/200(L)--
> Current allocation mode is local
> Current file position is 193489
> ESP Ghostscript 815.01: Unrecoverable error, exit code 1
> 
> I hardly know anything about postscript except that I probably had to
> look for "something-that-leaves-0-on-the-stack setmiterlimit".  I looked
> into the file and when I removed all the lines "0 setmiterlimit" (sed -i
> -e 's/0 setmiterlimit//' /tmp/diag.eps), the file displayed.
> 
> Unfortunately I don't have a small example.  I used it straight in an
> Eclipse plug in that exports images to be able to generate EPS.  So what
> might cause those lines to appear and what can I do about them?


Jeremias Maerki


---------------------------------------------------------------------
Apache XML Graphics Project URL: http://xmlgraphics.apache.org/
To unsubscribe, e-mail: general-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: general-help@xmlgraphics.apache.org


Mime
View raw message