Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I just got a new computer and installed MikTex 2.9 for Windows7 64-bit.

When I compiled my resume for the first time (moderncv, theme casual), it compiled in roman vs. sans serif fonts. I did not specify the roman argument, so the document should default to sans serif fonts.

Why can't I get sans serif fonts? I hate roman.

Example of file:

\documentclass[10pt,letter]{moderncv}

\moderncvtheme[green]{casual}                
\usepackage[utf8]{inputenc}     
\usepackage{fontenc}
\usepackage[scale=0.835]{geometry}

\AtBeginDocument{\recomputelengths}  

\firstname{Fname}
\familyname{Lnmae}

\address{123 Main St.}{city, state 00000}
\mobile{999 999 9999}

\email{person@email.com}

\nopagenumbers{} 
\hyphenpenalty=100000

\begin{document}

\maketitle
\vspace{-.5in}

\section{Objective}
\cvline{}{Hire Me!}

\section{Experience}

\cventry{Summer 2009}{Trading Post Manager}{Company Name}{Somewhere, NC}{}{Implemented ECR system to manage and report inventory of 350+ items; managed daily operations.}

\end{document} 

Excerpt from \listfiles:

*File List*
moderncv.cls    2012/10/31 v1.2.0 modern curriculum vitae and letter document c
lass
  size10.clo    2007/10/19 v1.4h Standard LaTeX file (size option)
    [...]
 fontenc.sty
   t1enc.def    2005/09/27 v1.99g Standard LaTeX file
 lmodern.sty    2009/10/30 v1.6 Latin Modern Fonts
    [...]
  ot1lmr.fd    2009/10/30 v1.6 Font defs for Latin Modern
  omllmm.fd    2009/10/30 v1.6 Font defs for Latin Modern
 omslmsy.fd    2009/10/30 v1.6 Font defs for Latin Modern
 omxlmex.fd    2009/10/30 v1.6 Font defs for Latin Modern
share|improve this question
1  
Welcome to TeX.sx! Is the lmodern package installed? It might be helpful if you include \listfiles at the beginning of your document, recompile, and add the list of files printed in your .log file to your question here by clicking edit. –  doncherry Nov 14 '12 at 20:34
    
Welcome to TeX.sx! Please add a minimal working example (MWE) that illustrates your problem. It is considered a lot better to put in some code that will compile, as it makes it a lot easier for us to copy it into our text editor and work with it, and see exactly what it is you are trying to do. –  Martin Schröder Nov 14 '12 at 20:35
    
I added the list of files; it appears that the lmodern package is in use. –  meryl Nov 14 '12 at 20:56
1  
@Xavier While it is a good idea to clean up questions and especially the code, in my opinion you went too far in this case – not to mention, that you in your answer refer to code, which you deleted now. Instead you should have shown a good MWE in your answer (there’s a typo now, so you have to edit anyway). Also the output of \listfiles was asked in a comment above. I just made a rollback. –  Speravir Nov 14 '12 at 23:17
1  
@Speravir Since Xavier is the author of the package in question and he also fixed the irrelevant parts of the code I think it's not that dramatic in this very specific problem. –  percusse Nov 15 '12 at 1:33
show 5 more comments

1 Answer 1

The sans class option, for sans serif fonts, need to be specified explicitly when loading moderncv since version 0.15, i.e.

\documenclass[sans]{moderncv}

Note also that \moderncvtheme is deprecated, in favor of \moderncvstyle and \moderncvcolor, and that \AtBeginDocument{\recomputelengths} is not required anymore.

Your MWE would then look like

\documentclass[sans]{moderncv}

\moderncvstyle{casual}                

\firstname{Fname}
\familyname{Lname}    
\address{123 Main St.}{City, State 00000}{Country}
\mobile{999 999 9999}
\email{person@email.com}

\begin{document}

\maketitle

\section{Objective}
\cvline{}{Hire Me!}

\end{document}
share|improve this answer
    
Thanks. The sans option does the trick. Surprised that this JUST starting being a problem for me if that change has been in effect since 0.15. –  meryl Nov 14 '12 at 23:54
    
@meryl Well, it depends what distribution you use and how frequently it updates packages. I had to go check my commits to find out when the behavior changed :) –  Xavier Nov 15 '12 at 3:15
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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