0

I'm using XeLaTeX to make my Europass CV, because I want to use a custom system font.

I've used the package europecv without any problem before understanding it gets me the old CV layout.

\documentclass{europecv}
\usepackage[a4paper,top=1.27cm,left=1cm,right=1cm,bottom=2cm]{geometry}
\usepackage{fontspec}
\setmainfont{Ubuntu}

\begin{document}
\begin{europecv}

\ecvpersonalinfo[20pt]

\end{europecv}
\end{document} 

old layout with custom font

But, trying to use the class europasscv, which gives the new 2013- layout, something goes wrong

\documentclass[a4paper]{europasscv}
\usepackage{fontspec}
\setmainfont{Ubuntu}

\begin{document}
\begin{europasscv}

\ecvpersonalinfo

\end{europasscv}
\end{document}

LaTeX Font Warning: Font shape `EU1/phv/m/n' undefined

(Font) using `EU1/lmr/m/n' instead on input line 6.

LaTeX Font Warning: Some font shapes were not available, defaults substituted.

new layout

Line 6 being the one corresponding to \begin{europasscv}. As a side note, even if irrelevant, the font I'm trying to use is, as can be read from the source code I've posted, Ubuntu Regular. I'm on Arch Linux and I've installed it using the distro's package ttf-ubuntu-font-family. Anyway, works with no problem on the old class. Something in the new one's title isn't compatible with the font, or any custom one, as I've tried with others as well.

1

In the class file Helvetica (phv) is hardcoded all over the class, so we ask fontspec to use Ubuntu everywhere phv is requested with \newfontfamily\myfont[NFSSFamily=phv]{Ubuntu}:

\documentclass[a4paper]{europasscv}
\usepackage{fontspec}
\setmainfont{Ubuntu}
\newfontfamily\myfont[NFSSFamily=phv]{Ubuntu}

\begin{document}
\begin{europasscv}

\ecvpersonalinfo

\end{europasscv}
\end{document}
  • This only changed the"Curriculum vitae" writing. I looked into the class file for any other command in which Helvetica is hardcoded and renewed all those commands removign the selectfont part like you did, but that didn't change anything either. – Jeffrey Lebowski Jan 21 '17 at 14:30
  • @JeffreyLebowski updated. Now works. – Astrinus Jan 23 '17 at 15:26
  • Sorry for the delay, busy as hell. Thanks a lot, it now works! – Jeffrey Lebowski Jan 24 '17 at 9:56

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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