groff
[Top][All Lists]
Advanced

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

Re: [Groff] patch for pdfroff


From: Zvezdan Petkovic
Subject: Re: [Groff] patch for pdfroff
Date: Fri, 16 Jun 2006 22:07:16 -0400
User-agent: Mutt/1.4.2i

On Fri, Jun 16, 2006 at 03:03:25PM +0100, Keith Marshall wrote:
> Thanks for suggesting this potential enhancement.  I think, however, that 
> I prefer `--emit-ps', or `--emit-postscript', (one or the other, but not 
> both, otherwise abbreviation becomes unwieldy), to your choice of 
> `--leave-postscript-output', for the name of the new option.

I agree.

> One problem I do see, with your patch, is that it always assumes that 
> `--no-toc-relocation' is the desired behaviour; this may not always be 
> the case.  Better to define `PDFWRITE="$CAT"', rather than its normal 
> `PDFWRITE="$GS ..." definition, if `--emit-ps' is specified, I think.

Well, the patch was for my personal use, and since gpresent generates
TOC for the slides I never really needed that feature.
However, I agree that in general case it should be considered.
The new patch and the patch to the man page are attached.

One issue I had is that your sed script erased completely valid EPS
files (created by ImageMagick convert program from JPG and PNG) embedded
in my presentations.  Thus I decided to make it an empty script for
--emit-ps option.  If you ever fix it, so that it doesn't remove images,
but rather blank pages only, it could be used without if-else-fi.
Till then, I think it is safer to assume that a user of --emit-ps wants
an unchanged PostScript output.

I'd fix that sed script myself if I had a faintest idea how to
reliably distinguish a valid embedded EPS from a blank page.

> I also note that you've added the `-dSAFER' option to the `gs' invocation.
> I'd prefer not to do that, as not all users may want it.  Better to add a 
> `--gs-options="option list"' option to pdfroff, so that users can make 
> the choice, IMHO.  (This is something which was discussed before, but I 
> simply haven't found the time to implement it).

No need.  I call it from Makefile as

        env GS_OPTIONS="-dSAFER" pdfroff ...

Ghostscript respects GS_OPTIONS environment variable.

Best regards,

        Zvezdan Petkovic

Attachment: pdfroff.diff
Description: Text document

Attachment: pdfroff.1.diff
Description: Text document


reply via email to

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