[XeTeX] graphics inclusion

Guy camatkara at gmail.com
Mon Dec 10 03:31:07 CET 2007


Thanks for the help, guys.  Since I'd tried a few different pdfs to
include as graphics, I didn't think that could be the problem.  But
your hunches were right, Will (and Jonathan), that does seem to be
part of the issue.  While the .pdf Will sent me still doesn't get
included via latex, it does via xelatex.  Here is the terminal output
for the .tex file Will sent:

> latex example_doc.tex
> This is pdfTeXk, Version 3.141592-1.40.3 (Web2C 7.5.6)
>  %&-line parsing enabled.
> entering extended mode
> (./example_doc.tex
> LaTeX2e <2005/12/01>
> Babel <v3.8h> and hyphenation patterns for english, usenglishmax, dumylang, noh
> yphenation, loaded.
> (/usr/share/texmf-texlive/tex/latex/base/article.cls
> Document Class: article 2005/09/16 v1.4f Standard LaTeX document class
> (/usr/share/texmf-texlive/tex/latex/base/size10.clo))
> (/usr/share/texmf-texlive/tex/latex/graphics/graphicx.sty
> (/usr/share/texmf-texlive/tex/latex/graphics/keyval.sty)
> (/usr/share/texmf-texlive/tex/latex/graphics/graphics.sty
> (/usr/share/texmf-texlive/tex/latex/graphics/trig.sty)
> (/etc/texmf/tex/latex/config/graphics.cfg)
> (/usr/share/texmf-texlive/tex/latex/graphics/dvips.def))) (./example_doc.aux)
>
> ! LaTeX Error: File `example' not found.
>
> See the LaTeX manual or LaTeX Companion for explanation.
> Type  H <return>  for immediate help.
>  ...
>
> l.4 \includegraphics{example}
>
> ?

And it fails to produce a .pdf.  Here is its log file:

> This is pdfTeXk, Version 3.141592-1.40.3 (Web2C 7.5.6) (format=latex 2007.12.1)  9 DEC 2007 20:23
> entering extended mode
>  %&-line parsing enabled.
> **example_doc.tex
> (./example_doc.tex
> LaTeX2e <2005/12/01>
> Babel <v3.8h> and hyphenation patterns for english, usenglishmax, dumylang, noh
> yphenation, loaded.
> (/usr/share/texmf-texlive/tex/latex/base/article.cls
> Document Class: article 2005/09/16 v1.4f Standard LaTeX document class
> (/usr/share/texmf-texlive/tex/latex/base/size10.clo
> File: size10.clo 2005/09/16 v1.4f Standard LaTeX file (size option)
> )
> \c at part=\count79
> \c at section=\count80
> \c at subsection=\count81
> \c at subsubsection=\count82
> \c at paragraph=\count83
> \c at subparagraph=\count84
> \c at figure=\count85
> \c at table=\count86
> \abovecaptionskip=\skip41
> \belowcaptionskip=\skip42
> \bibindent=\dimen102
> )
> (/usr/share/texmf-texlive/tex/latex/graphics/graphicx.sty
> Package: graphicx 1999/02/16 v1.0f Enhanced LaTeX Graphics (DPC,SPQR)
>
> (/usr/share/texmf-texlive/tex/latex/graphics/keyval.sty
> Package: keyval 1999/03/16 v1.13 key=value parser (DPC)
> \KV at toks@=\toks14
> )
> (/usr/share/texmf-texlive/tex/latex/graphics/graphics.sty
> Package: graphics 2006/02/20 v1.0o Standard LaTeX Graphics (DPC,SPQR)
>
> (/usr/share/texmf-texlive/tex/latex/graphics/trig.sty
> Package: trig 1999/03/16 v1.09 sin cos tan (DPC)
> )
> (/etc/texmf/tex/latex/config/graphics.cfg
> File: graphics.cfg 2007/01/18 v1.5 graphics configuration of teTeX/TeXLive
> )
> Package graphics Info: Driver file: dvips.def on input line 90.
>
> (/usr/share/texmf-texlive/tex/latex/graphics/dvips.def
> File: dvips.def 1999/02/16 v3.0i Driver-dependant file (DPC,SPQR)
> ))
> \Gin at req@height=\dimen103
> \Gin at req@width=\dimen104
> ) (./example_doc.aux)
> \openout1 = `example_doc.aux'.
>
> LaTeX Font Info:    Checking defaults for OML/cmm/m/it on input line 3.
> LaTeX Font Info:    ... okay on input line 3.
> LaTeX Font Info:    Checking defaults for T1/cmr/m/n on input line 3.
> LaTeX Font Info:    ... okay on input line 3.
> LaTeX Font Info:    Checking defaults for OT1/cmr/m/n on input line 3.
> LaTeX Font Info:    ... okay on input line 3.
> LaTeX Font Info:    Checking defaults for OMS/cmsy/m/n on input line 3.
> LaTeX Font Info:    ... okay on input line 3.
> LaTeX Font Info:    Checking defaults for OMX/cmex/m/n on input line 3.
> LaTeX Font Info:    ... okay on input line 3.
> LaTeX Font Info:    Checking defaults for U/cmr/m/n on input line 3.
> LaTeX Font Info:    ... okay on input line 3.
>
>
> ! LaTeX Error: File `example' not found.
>
> See the LaTeX manual or LaTeX Companion for explanation.
> Type  H <return>  for immediate help.
>  ...
>
> l.4 \includegraphics{example}
>
> ?
> (./example_doc.aux) )
> Here is how much of TeX's memory you used:
>  515 strings out of 95087
>  6060 string characters out of 1183278
>  51457 words of memory out of 1500000
>  3748 multiletter control sequences out of 10000+50000
>  3640 words of font info for 14 fonts, out of 1200000 for 2000
>  28 hyphenation exceptions out of 8191
>  25i,1n,19p,204b,36s stack positions out of 5000i,500n,6000p,200000b,5000s
>
> No pages of output.

When I specify the file type (i.e., \includegraphics{example.pdf}),
latex can then find the graphic (located in same directory), but it
then has a bounding box issue.  Terminal output for that is:

>  latex example_doc.tex
> This is pdfTeXk, Version 3.141592-1.40.3 (Web2C 7.5.6)
>  %&-line parsing enabled.
> entering extended mode
> (./example_doc.tex
> LaTeX2e <2005/12/01>
> Babel <v3.8h> and hyphenation patterns for english, usenglishmax, dumylang, noh
> yphenation, loaded.
> (/usr/share/texmf-texlive/tex/latex/base/article.cls
> Document Class: article 2005/09/16 v1.4f Standard LaTeX document class
> (/usr/share/texmf-texlive/tex/latex/base/size10.clo))
> (/usr/share/texmf-texlive/tex/latex/graphics/graphicx.sty
> (/usr/share/texmf-texlive/tex/latex/graphics/keyval.sty)
> (/usr/share/texmf-texlive/tex/latex/graphics/graphics.sty
> (/usr/share/texmf-texlive/tex/latex/graphics/trig.sty)
> (/etc/texmf/tex/latex/config/graphics.cfg)
> (/usr/share/texmf-texlive/tex/latex/graphics/dvips.def))) (./example_doc.aux)
>
> ! LaTeX Error: Cannot determine size of graphic in example.pdf (no BoundingBox)
> .
>
> See the LaTeX manual or LaTeX Companion for explanation.
> Type  H <return>  for immediate help.
>  ...
>
> l.4 \includegraphics{example.pdf}
>
> ?

Its log file is:

> This is pdfTeXk, Version 3.141592-1.40.3 (Web2C 7.5.6) (format=latex 2007.12.1)  9 DEC 2007 20:27
> entering extended mode
>  %&-line parsing enabled.
> **example_doc.tex
> (./example_doc.tex
> LaTeX2e <2005/12/01>
> Babel <v3.8h> and hyphenation patterns for english, usenglishmax, dumylang, noh
> yphenation, loaded.
> (/usr/share/texmf-texlive/tex/latex/base/article.cls
> Document Class: article 2005/09/16 v1.4f Standard LaTeX document class
> (/usr/share/texmf-texlive/tex/latex/base/size10.clo
> File: size10.clo 2005/09/16 v1.4f Standard LaTeX file (size option)
> )
> \c at part=\count79
> \c at section=\count80
> \c at subsection=\count81
> \c at subsubsection=\count82
> \c at paragraph=\count83
> \c at subparagraph=\count84
> \c at figure=\count85
> \c at table=\count86
> \abovecaptionskip=\skip41
> \belowcaptionskip=\skip42
> \bibindent=\dimen102
> )
> (/usr/share/texmf-texlive/tex/latex/graphics/graphicx.sty
> Package: graphicx 1999/02/16 v1.0f Enhanced LaTeX Graphics (DPC,SPQR)
>
> (/usr/share/texmf-texlive/tex/latex/graphics/keyval.sty
> Package: keyval 1999/03/16 v1.13 key=value parser (DPC)
> \KV at toks@=\toks14
> )
> (/usr/share/texmf-texlive/tex/latex/graphics/graphics.sty
> Package: graphics 2006/02/20 v1.0o Standard LaTeX Graphics (DPC,SPQR)
>
> (/usr/share/texmf-texlive/tex/latex/graphics/trig.sty
> Package: trig 1999/03/16 v1.09 sin cos tan (DPC)
> )
> (/etc/texmf/tex/latex/config/graphics.cfg
> File: graphics.cfg 2007/01/18 v1.5 graphics configuration of teTeX/TeXLive
> )
> Package graphics Info: Driver file: dvips.def on input line 90.
>
> (/usr/share/texmf-texlive/tex/latex/graphics/dvips.def
> File: dvips.def 1999/02/16 v3.0i Driver-dependant file (DPC,SPQR)
> ))
> \Gin at req@height=\dimen103
> \Gin at req@width=\dimen104
> ) (./example_doc.aux)
> \openout1 = `example_doc.aux'.
>
> LaTeX Font Info:    Checking defaults for OML/cmm/m/it on input line 3.
> LaTeX Font Info:    ... okay on input line 3.
> LaTeX Font Info:    Checking defaults for T1/cmr/m/n on input line 3.
> LaTeX Font Info:    ... okay on input line 3.
> LaTeX Font Info:    Checking defaults for OT1/cmr/m/n on input line 3.
> LaTeX Font Info:    ... okay on input line 3.
> LaTeX Font Info:    Checking defaults for OMS/cmsy/m/n on input line 3.
> LaTeX Font Info:    ... okay on input line 3.
> LaTeX Font Info:    Checking defaults for OMX/cmex/m/n on input line 3.
> LaTeX Font Info:    ... okay on input line 3.
> LaTeX Font Info:    Checking defaults for U/cmr/m/n on input line 3.
> LaTeX Font Info:    ... okay on input line 3.
>
>
> ! LaTeX Error: Cannot determine size of graphic in example.pdf (no BoundingBox)
> .
>
> See the LaTeX manual or LaTeX Companion for explanation.
> Type  H <return>  for immediate help.
>  ...
>
> l.4 \includegraphics{example.pdf}
>
> ?
> File: example.pdf Graphic file (type eps)
> <example.pdf> [1
>
> ] (./example_doc.aux) )
> Here is how much of TeX's memory you used:
>  512 strings out of 95087
>  6070 string characters out of 1183278
>  51457 words of memory out of 1500000
>  3750 multiletter control sequences out of 10000+50000
>  3640 words of font info for 14 fonts, out of 1200000 for 2000
>  28 hyphenation exceptions out of 8191
>  25i,4n,19p,418b,142s stack positions out of 5000i,500n,6000p,200000b,5000s
>
> Output written on example_doc.dvi (1 page, 272 bytes).

However, I get the appropriate graphics-included output by calling the
original file with pdflatex (as before) and now xelatex, though my
original graphic still doesn't work with xelatex.  I'll work on
producing another copy of that graphic to see whether I can get a new
version to work with xelatex.  Thanks again for the troubleshooting
help.

Guy

p.s.  Ross, your comment regarding quotation marks seems to have been
on the mark.  I'd configured Kile to use smart quotes, which was
interfering with calling the graphic using the \XeTeXpdffile command.
Now I just get an overfull \vbox error in the terminal:

> (/usr/share/texmf-texlive/tex/latex/base/fixltx2e.sty)) (./example_doc.aux)
> Overfull \vbox (522.0pt too high) has occurred while \output is active
> (./example_doc.aux) )
> (see the transcript file for additional information)
> No pages of output.


On Dec 9, 2007 7:02 PM, Ross Moore <ross at ics.mq.edu.au> wrote:
> Hello Guy,
>
> On 10/12/2007, at 4:45 AM, Guy wrote:
>
> > Yes, the terminal has this error when I run xelatex on that file:
> >
> >> ! Unable to load picture or PDF file '``srikanthacrop.pdf'.
>
> Jonathan mentioned those extra quotes `` .
>
> Perhaps when you tried:
>
>     \XeTeXpdffile "srikanthacrop.pdf"
>
> you also have a pre-processing step that replaces
>   "<letters>   with  ``<letters> .
>
> While this kind of gimmick is useful in normal paragraphed text,
> it will certainly cause failure here.
> The pattern-matching rules for this kind of replacement need to
> be thought out very carefully to avoid this.
>
>
> Another possibility is that " is an active character within
> your document, that "looks ahead" to see what is the next character,
> to guess whether opening or closing quotes are intended.
> This will fail for the same reason as above.
> You need to make the " unactive, if you want to use it in this context.
>
>
> To help you further we need to see complete document source,
> cut-down to be as short as possible, which allows us to see the
> complete context in which normal commands seem to be failing
> for you.
>
>
>
> >> <to be read again>
> >>                    \unhbox
> >
> > and, despite the log file, there is just a blank space where my
> > included graphic should be in the output.  Pdflatex will produce the
> > proper graphic-included output, but not latex (which produces an empty
> > box) or xelatex (blank space).  It seems that I'm missing some basic
> > element or configuration in latex and xelatex, no?  Does pdflatex come
> > bundled with anything that those two don't?  Or are there any basic
> > dependencies for xe/latex that I might have overlooked?  Thanks again.
>
> Rather than you missing anything, it is far more likely that
> your situation is actually more complicated than you are telling us,
> in terms of packages, active characters and macro definitions.
>
>
> >
> > guy
>
>
> Hope this helps,
>
>         Ross
>
> ------------------------------------------------------------------------
> 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
> ------------------------------------------------------------------------
>
>
>
> _______________________________________________
> XeTeX mailing list
> postmaster at tug.org
> http://tug.org/mailman/listinfo/xetex
>


More information about the XeTeX mailing list