# Error when including .tex file created with XCircuit in Latex mode

I've recently created an eps figure using XCircuit. Labels of the components written in "LaTeX Mode" to have the default LaTeX font. When i try to compile my .tex file i get the following error:

(/usr/local/texlive/2014/texmf-dist/tex/latex/graphics/epsfig.sty)
No file ELEC331_mono.aux.
[1] (../fig/exp1_bridge2.tex

! Package keyval Error: scale=1 undefined.

See the keyval package documentation for explanation.
Type  H <return>  for immediate help.
...

l.16    }
% close 'scalebox'
?


Here is my main .tex file:

\documentclass[11pt,a4paper,titlepage,twoside]{article}
\usepackage[turkish,english]{babel}
\usepackage[latin5]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{graphicx}
\usepackage{titlesec}
\usepackage{float}
\usepackage{enumitem}
\usepackage{cite}
\usepackage{url}
\usepackage{epsfig}

\graphicspath{{../fig/}}
\title{\textbf{ELEC 331 - Electronic Circuits 2} \\ Laboratory Manuals}
\author{Author}

\begin{document}

\maketitle
\input{../fig/exp1_bridge2.tex}

\end{document}


And here is the .tex file created by XCircuit:

% XCircuit output "ELEC331_LAB/fig/exp1_bridge2.tex" for LaTeX input from ELEC331_LAB/fig/exp1_bridge2.eps
\def\putbox#1#2#3#4{\makebox[0in][l]{\makebox[#1][l]{}\raisebox{\baselineskip}[0in][0in]{\raisebox{#2}[0in][0in]{\scalebox{#3}{#4}}}}}
\def\rightbox#1{\makebox[0in][r]{#1}}
\def\centbox#1{\makebox[0in]{#1}}
\def\topbox#1{\raisebox{-0.60\baselineskip}[0in][0in]{#1}}
\def\midbox#1{\raisebox{-0.20\baselineskip}[0in][0in]{#1}}
\scalebox{1}{
\normalsize
\parbox{4.42188in}{
\includegraphics[scale=1]{exp1_bridge2}\\
% translate x=672 y=278 scale 0.38
\putbox{3.97in}{1.25in}{1.20}{vout(t)}%
\putbox{0.06in}{1.34in}{1.20}{vin(t)}%
\putbox{2.22in}{1.92in}{1.20}{D1}%
} % close 'parbox'
} % close 'scalebox'
\vspace{-\baselineskip} % this is not necessary, but looks better


• Don't load epsfig. Period. – Werner Jul 24 '15 at 5:53
• For volunteers. The following MWE shows the same issue: \documentclass{article} \usepackage[turkish,english]{babel} \usepackage[demo]{graphicx} \begin{document} \includegraphics[scale=1]{exp1_bridge2} \end{document} – LaRiFaRi Jul 24 '15 at 6:48
• The problem is with turkish language that makes the character = active. See tex.stackexchange.com/q/160385/27635 for a workaround – karlkoeller Jul 24 '15 at 19:15
Thanks karlkoeller, it was related with turkish language. As you suggested in your other comments, adding \shorthandoff{=} and \shorthandon{=} before and after \includegraphics command solved the problem.