[OS X TeX] epstopdf

Ross Moore ross at ics.mq.edu.au
Thu Sep 29 01:35:40 CEST 2005


Hi Piet,

On 29/09/2005, at 8:12 AM, Piet van Oostrum wrote:

> A simple change in epstopdf can cure this:
>
> Replace the lines:
>
>   my $pipe = "$GS -q -sDEVICE=pdfwrite $GSOPTS -dAutoRotatePages=/ 
> None" .
>           " -sOutputFile=$OutputFilename - -c quit";
> with:
>
>   $OutputFilename =~ s/'/'"'"'/g;
>   my $pipe = "$GS -q -sDEVICE=pdfwrite $GSOPTS -dAutoRotatePages=/ 
> None" .
>           " -sOutputFile='$OutputFilename' - -c quit";

OK, that works ...

[GlenLivet:~/Documents/tests/test_pdfs] rossmoor% ./epstopdf -debug A 
\'B.eps
* Input filename: A'B.eps
* BoundingBox comment: %%BoundingBox:
* Output filename: A'B.pdf
* Ghostscript command: gs
* Compression: on
* Ghostscript pipe: gs -q -sDEVICE=pdfwrite  - 
sOutputFile='A'"'"'B.pdf' - -c quit
* The first eol character was a CR (23) and not immediately followed  
by a LF (-1)
* Scanning header for BoundingBox
* Old BoundingBox: 0 0 205 188
* New BoundingBox: 0 0 205 188
* Offset: 0 0
* Ready.


  ... but the construction makes for a very clumsy  Ghostscript pipe .

Using instead:
                 $OutputFilename =~ s/'/'\\''/g;

also works, producing:

* Ghostscript pipe: gs -q -sDEVICE=pdfwrite  - 
sOutputFile='A'\''B.pdf' - -c quit

which is a bit neater.

Is there any effective difference between these substitutions ?
That is, can you think of any situation where one fails
while the other works ?



Cheers,

     Ross


>
> -- 
> Piet van Oostrum <piet at cs.uu.nl>
> URL: http://www.cs.uu.nl/~piet [PGP 8DAE142BE17999C4]
> Private email: piet at vanoostrum.org
> ------------------------- Info --------------------------
> Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
>           & FAQ: http://latex.yauh.de/faq/
> TeX FAQ: http://www.tex.ac.uk/faq
> List Archive: http://tug.org/pipermail/macostex-archives/
>
>

------------------------------------------------------------------------
Ross Moore                                         ross at maths.mq.edu.au
Mathematics Department                             office: E7A-419
Macquarie University                               tel: +61 +2 9850 8955
Sydney, Australia  2109                            fax: +61 +2 9850 8114
------------------------------------------------------------------------


------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
          & FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/




More information about the macostex-archives mailing list