3

I'm trying to reduce the title font size but the "|" separator is not matching the text size. Is it possible to change it to another symbol (like "--") or reduce its font size to match the rest of the title size?

Here's what I have so far:

\documentclass[11pt,a4paper,sans]{moderncv}
\moderncvstyle{banking}
\moderncvcolor{blue}
\usepackage{lipsum}
\usepackage[scale=0.75]{geometry}


\firstname{\large John}
\familyname{\large Doe}

\title{\large Machine Learning | Data Science}
\address{52 Mercer's Drive}{St. John's, NL}


\email{emailaddress@gmail.com}


\begin{document}

\makecvtitle

\end{document}

And this is how it looks like:

enter image description here

1 Answer 1

2

The default size of the divider is set to \Huge. You should redefine the font-related settings for the name and titles, like I did below.

enter image description here

\documentclass[11pt,a4paper,sans]{moderncv}

\moderncvstyle{banking}
\moderncvcolor{blue}

\makeatletter
\renewcommand*{\namefont}{\large\bfseries\upshape}% Default is \Huge\bfseries\upshape
\renewcommand*{\titlefont}{\large\mdseries\upshape}% Default is \Huge\bfseries\upshape
\renewcommand*{\titlestyle}[1]{{\titlefont\textcolor{color2!85}{~$|$~\@title}}}% Default is {\titlefont\textcolor{color2!85}{#1}}
\makeatother

\firstname{Example}
\familyname{Doe}

\title{Machine Learning~\texorpdfstring{$|$}{|}~Data Science}
\address{52 Mercer's Drive}{St.\ John's, NL}

\email{emailaddress@gmail.com}

\begin{document}

\makecvtitle

\end{document}

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.