Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I am trying to insert an image from Inkscape. I saved it as a pdf, checking the PDF + Latex option.
Inside my Latex file, I wrote the following code :

\begin{figure}  
  \centering  
  \def\svgwidth{\columnwidth}  
  \input{topo4serv.pdf_tex}  
\end{figure}

but when i try to compile using pdflatex, it gives me the following error message:

ERROR: Undefined control sequence.  

--- TeX said ---  
<argument> \includegraphics  
                            [width=\unitlength ]{topo4serv.pdf}
l.52 ...raphics[width=\unitlength]{topo4serv.pdf}}
                                                   %

In the output pdf file the text of the svg file is there but not the shapes...
If someone has an answer i would be very grateful.

share|improve this question
5  
Welcome to TeX.SX! Did you say \usepackage{graphicx} in your document? –  egreg Jun 29 '12 at 13:45
    
First time I am seeing something like topo4serv.pdf_tex. I would rather say \includegraphics{topo4serv.pdf} –  azetina Jun 29 '12 at 14:21
    
@azetina Usage seems correct as it is stated here: tug.ctan.org/tex-archive/info/svg-inkscape –  interlude Jun 29 '12 at 15:14
1  
It is correct to use \input{file.pdf_tex}. If you open that file, it has instructions for its usage. Like egreg said, you need to have \usepackage{graphicx} in your preamble for this to work. –  Scribblemacher Jun 29 '12 at 17:45

1 Answer 1

up vote 5 down vote accepted

\includegraphicsis giving error because it is not defined, which means you need to \usepackage{graphicx} on document's preamble

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.