Importing *.pdf_tex file error

4.7k Views Asked by At

I have made a graphic with inkscape. Now I'm trying to build it in Latex. I' m working with TEXMaker. Therefore I have exported my graphic as *.pdf_tex and *.pdf. In macros i have added the following

\usepackage{color}
\usepackage{transparent}
\graphicspath{{fileWithPictures/}}

my picture is build in like this:

\begin{figure}
\centering
\def\svgwidth{175pt}
\input{fileWithPictures/pic.pdf_tex}
%\includegraphics[width=2in]{fileWithPictures/pic.pdf_tex}

\end{figure}

Here I'm getting the following error. "!Package pdftex.def Error: File'pic.pdf" not found. See the pdftex.def package.."

I have tryed also to work with includegraphics which not succed. Because there he it doesn't recognize pdf_tex format.

Interesting is that the compiler says that there is not a file called "pic.pdf" and not "pic.pdf_tex". Althought both files are clearly in the file. To be sure i put the pic.svg file in the file. Now i have no more ideas and would be happy to get some help

Thanks

1

There are 1 best solutions below

0
On

Use resizebox to set the width of your file instead of \def\svgwidth{175pt} it will solve your problem

\resizebox{\textwidth}{!}{
    \input{fileWithPictures/pic.pdf_tex}
}