groff
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Groff] EPS from PIC?


From: Ted Harding
Subject: Re: [Groff] EPS from PIC?
Date: Thu, 30 Oct 2003 14:12:24 -0000 (GMT)

This is very weird! See below. I think there must be a bug somewhere!

On 30-Oct-03 Christian Lindig wrote:
> On Thu, Oct 30, 2003 at 12:20:04PM -0000, Ted Harding wrote:
>> 'ps2eps' should do the job. (It calls 'ps2epsi' and then cuts out the
>> "preview" block). [detailed explanation of bounding box]
> 
> Ted,
> 
> thanks a lot for your detailed discussion of the bounding box. At least
> on my Debian Linux system, ps2epsi(1) does not work because gs(1) trips
> on the PostScript generated by groff when it tries to find to bounding
> box.
> 
>     $ cat foo.pic
>     .PS
>     right; box "one"; arrow ->; box "two"; arrow ->; box "three"
>     .PE
> 
>     $ gpic foo.pic | groff -Tps > foo.ps
>     $ ps2epsi foo.ps
>     Error: /invalidaccess in --.setdevice--
>     Operand stack:
>        --nostringval--
>     Execution stack:
>     ....
> 
> Maybe this is problem of the gs version, but I doubt it. Does this work
> for you?

The basic problem with ps2epsi is that there seems to be a "blank page".

After some experimentation (groff 1.18.1) I came up with the following
facts. But first I preceded your above code with ".bp" so as to initiate
a break to the first page, so the input file is foo.pic:

.bp
.PS
right; box "one"; arrow ->; box "two"; arrow ->; box "three"
.PE

Next, I found that

cat foo.pic | groff -p -Tps > foo.ps
gv foo.ps
cat foo.pic | groff -p -Tps -ms > foo.ps
gv foo.ps

all gave blank displays. Then I found that

cat foo.pic | groff -pe -Tps -ms > foo.ps
gv foo.ps

DOES work! I.e. running foo.pic through both pic and eqn works.
You can see the diagram in gv.

Then doing ps2eps on foo.ps does not fail, but the result is
no good (a BoundingBox with no content).

However (reverting to the above experiment) I also found that

cat foo.pic | groff -pe -Tps > foo.ps

(using both pic and eqn but this time not using ms macros)
again gave a blank page.

Something is wrong here ...

Ted.


--------------------------------------------------------------------
E-Mail: (Ted Harding) <address@hidden>
Fax-to-email: +44 (0)870 167 1972
Date: 30-Oct-03                                       Time: 14:12:24
------------------------------ XFMail ------------------------------

reply via email to

[Prev in Thread] Current Thread [Next in Thread]