I am inserting an image from Inkscape using the pdf + LaTeX option since I want the text to appear in the same font and size as in the rest of my document.
Can I change the color of the text?
\documentclass{article}
\usepackage{graphicx}
\usepackage{color}
\begin{document}
Some text before the figure.
\color{red}
\begin{figure}
\centering
\def\svgwidth{\textwidth}
\input{figure.pdf_tex}
\caption{Example Figure}
\end{figure}
Some text after the figure.
\end{document}
The following is the content of the figure.pdf_tex file:
\begingroup%
\makeatletter%
\providecommand\color[2][]{%
\errmessage{(Inkscape) Color is used for the text in Inkscape, but the package 'color.sty' is not loaded}%
\renewcommand\color[2][]{}%
}%
\providecommand\transparent[1]{%
\errmessage{(Inkscape) Transparency is used (non-zero) for the text in Inkscape, but the package 'transparent.sty' is not loaded}%
\renewcommand\transparent[1]{}%
}%
\providecommand\rotatebox[2]{#2}%
\ifx\svgwidth\undefined%
\setlength{\unitlength}{782.075bp}%
\ifx\svgscale\undefined%
\relax%
\else%
\setlength{\unitlength}{\unitlength * \real{\svgscale}}%
\fi%
\else%
\setlength{\unitlength}{\svgwidth}%
\fi%
\global\let\svgwidth\undefined%
\global\let\svgscale\undefined%
\makeatother%
\begin{picture}(1,0.48489595)%
\put(0,0){\includegraphics[width=\unitlength]{figure.pdf}}%
\put(0.21413974,0.24055332){\color[rgb]{0,0,0}\makebox(0,0)[lb]{\smash{Text}}}%
\end{picture}%
\endgroup%

\color{red}work? If not please post a small example – David Carlisle Feb 18 '14 at 14:02\put(0.21413974,0.24055332){\color[rgb]{0,0,0}\makebox(0,0)[lb]{\smash{Text}}}%of the pdf_tex file and it seems to work. However, I wonder if it's possible to change the text color without having to mess with the pdf_tex file. – Bettina Feb 18 '14 at 14:57