How to change \EUR to serif font?

You can redefine the command on preamble, inserting the Roman font family (\rmfamily).

\documentclass[a4paper]{article}
\usepackage{eurosym}

\renewcommand{\familydefault}{\sfdefault}

\makeatletter
%% from eurosym.sty
\def\EUR#1{{\rmfamily\if@EURleft\euro\,\fi#1\if@EURleft\else\,\euro\fi}}
\makeatother

\begin{document}

I'm just a test line \EUR{12345}. % ...like this!
\end{document}

Or maybe define a new command, eg, \rmEUR so you don't loose the default one.


Instead of loading eurosym, you can load textcomp and use the command \texteuro, or just type in €. If the current 8-bit legacy font has that symbol (and most of the ones in a modern TeX distribution do), it will use that. Otherwise, the package will try to fake it with C and =.

With a modern TeX engine, you can load fontspec and use the Unicode character. The \texteuro command still works, for backward compatibility. Only a few publishers still do not support modern fonts in 2019.

You might find the \EUR command useful enough to define yourself:

\documentclass{article}
\usepackage{fontspec} % Or:
%\usepackage[T1]{fontenc}
%\usepackage{textcomp}
%\usepackage[utf8]{inputenc}

\usepackage{parskip} % Removes the paragraph indentation.

\DeclareRobustCommand\EUR[1]{€\thinspace #1}

\begin{document}
\EUR{10} \textbf{\EUR 10} \textit{\EUR{10} \textbf{\EUR{10}}} \\
\textsf{\EUR{10} \textbf{\EUR 10} \textit{\EUR{10} \textbf{\EUR{10}}}}
\end{document}

Euro font sample

This uses the Euro symbol from the current font, followed by a thin, non-breaking space. If you would rather use the German convention of putting the symbol after the amount, do it that way instead. (#1\thinspace €) If you want to switch conventions within the same document, that would be more complicated.

Tags:

Eurosym