bug-gv
[Top][All Lists]
Advanced

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

Re: [bug-gv] gv fails when navigating back and forth


From: William Bader
Subject: Re: [bug-gv] gv fails when navigating back and forth
Date: Fri, 11 Oct 2019 16:16:55 +0000

I think that what you are doing is valid. I ran a test multi-page ps through ps2ps from gs 9.27 and saw the same problem with page up.
In theory, everything (from the top of a PS file to the %%EndProlog) + (the area between any two consecutive %%Page comments) + (the %%Trailer to the end) should be a valid page both for viewing and for (what I think was the original intention years ago when everything was much slower) parallelized printing.
The gv code to parse the comments is really complicated to handle programs that make incorrect files.
I agree with you that the issue is probably gs ps2write (because gv is one of the few applications that would notice if the comments are not correct) but there is a small chance that it is gv.
When I page up, I get the 'ERROR: typecheck' message in the gv document window (instead of in a pop-up window that gv shows for gs errors), so I think that the prolog generated by ps2ps is catching an error and displaying it. The error might be related to the new security in gs, but unsetting SafeDir and Safer in gv didn't help. Or maybe something in the ps2ps prolog sets a global state in gs and doesn't like being run twice.
If you can work with PDFs, you could try changing ps2ps to ps2pdf.
Regards, William


From: Frank Steiner <address@hidden>
Sent: Friday, October 11, 2019 2:54 AM
To: William Bader <address@hidden>; address@hidden <address@hidden>
Subject: Re: [bug-gv] gv fails when navigating back and forth
 
Hi Williamn,

William Bader wrote:

> Can you post a small file? PgUp works only on files that have
> comments like %%Page and that have the prolog separated correctly.

thanks for your explanation. I looked at our ps file and figured out
that ghostscript is the culprit. We send our files through ps2ps
before printing (with the option for a preview with gv, during which
the pgup fails) and this seems to destroy the page stuff.

E.g.
   echo -e "asfd\fasf\fasdf" |a2ps -o 1.ps
will create a ps file that gv can scroll back and forth. But using
  gs -sDEVICE=ps2write -sOutputFile=2.ps 1.ps
(which is what ps2ps basically does) will make scrolling through pages
fail with 2.ps.

We need ps2ps to make files fit into a certain paper format and I'm
not aware how to do this else, so I guess I'll have to ask the
ghostscrpt people.

So, it's not the fault of gv, just our way of using it after ps2ps.

Thanks for your help!

cu,
Frank



--
Dipl.-Inform. Frank Steiner   Web:  http://www.bio.ifi.lmu.de/~steiner/
Lehrstuhl f. Bioinformatik    Mail: http://www.bio.ifi.lmu.de/~steiner/m/
LMU, Amalienstr. 17           Phone: +49 89 2180-4049
80333 Muenchen, Germany       Fax:   +49 89 2180-99-4049
* Rekursion kann man erst verstehen, wenn man Rekursion verstanden hat. *

reply via email to

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