[pdftex] Illustrator 9.0 files with pdflatex and graphicx?

Hans Hagen pragma at wxs.nl
Thu Jun 14 09:32:03 CEST 2001

At 05:18 PM 6/13/01 -0500, Peter Schröder wrote:
>The more I think about it the less I understand why \includegraphics
>looks at the MediaBox. That is almost certainly the wrong thing. It's as
>if you were looking at %%DocumentSize in a ps file when including some
>ps file in a graphic. Instead one looks at BBox.

I don't know how includegraphics works, but if it's directly using the
pdfimage primitives, it's pdftex itself looking at tbe mediabox and
calculating the dimensions from it. 

>Out of curiosity, why does \includegraphics look at MediaBox? And how do
>I turn this behavior off and have it look for BBox instead? (I did try
>to give an explicit bbox argument which I set to the correct values, but
>that did not help).

see previous sentence, there is no reason to look at the media box 

>Note, my goal is to use Illustrator pdf directly. That way I don't have
>any conversions in the way (it strikes me as a natural thing to want; or
>is there some reason not to want this?). I could save from Illustrator
>to eps and then convert by hand, but that only invites synchronization
>lossage between the Illustrator source and the included file.

i think you should take a look at th eillustrator settings, make sure that
the media is not A4 or so, and make the mediabox [i.e the media] the same
as cropbox [there are a few more boxes btw]. In rare cases that the
mediabox is wrong i simply overload it by the cropbox using the following

=== crop2med.pl ==================================

# Hans Hagen, www.pragma-ade.com, 1999

if (open (PDF, "@ARGV[0].pdf"))
  { open (OUT, ">@ARGV[0].pdc") ;
    binmode PDF;
    binmode OUT ;
    while (<PDF>)
      { s/\/MediaBox/\/FunnyBox/go ;
        s/\/CropBox /\/MediaBox/go ;
        print OUT $_ }
    close (OUT) }
close PDF ;


hm, i should build this into texutil -) 

                                  Hans Hagen | PRAGMA ADE | pragma at wxs.nl
                      Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
 tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com

More information about the pdftex mailing list