Bugfixes, improvements and new symbols/nosymbols option for all styles (#34)

* fix Researcher ID (still) doesn't display Issue #29.
* make options 'symbols' and 'nosymbols' available to all styles to toggle whether symbols should be used or not. Include symbols in oldstyle by default.
* migrate older newcommand syntax in moderncvcollection.sty to the xparse syntax.
* Fix resumé typo in template. Is now résumé.
* remove loading lmodern fonts in all styles as they can produce issues with german characters, see https://tex.stackexchange.com/questions/496630/lualatex-problems-with-german-characters.
* remove loading inputenc package by default. Only load the package when pdflatex is used.
This commit is contained in:
David Seus 2021-01-26 12:57:04 +01:00 committed by GitHub
commit 35138209d3
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
13 changed files with 143 additions and 60 deletions

View file

@ -17,8 +17,13 @@
\DeclareOption{left} {\edef\moderncvstyleheadoptions{\moderncvstyleheadoptions,left}}
\DeclareOption{right}{\edef\moderncvstyleheadoptions{\moderncvstyleheadoptions,right}}
% toggle use of symbol fonts.
\@initializeif{\if@symbols}\@symbolsfalse
\DeclareOption{symbols} {\@symbolstrue}
\DeclareOption{nosymbols} {\@symbolsfalse}
\DeclareOption*{}% avoid choking on unknown options
\ExecuteOptions{right}
\ExecuteOptions{right,symbols}
\ProcessOptions*\relax% \ProcessOptions* processes the options in the order provided (i.e., with the later ones possibly overriding the former ones), while \ProcessOptions processes them in the order of the package
%-------------------------------------------------------------------------------
@ -30,17 +35,20 @@
% \setsansfont{Latin Modern Sans}
% \setmathfont{Latin Modern Math}
%\else
\IfFileExists{lmodern.sty}%
{\RequirePackage{lmodern}}%
{}
% \IfFileExists{lmodern.sty}%
% {\RequirePackage{lmodern}}%
% {}
%\fi
% symbols
\RequirePackage{ifxetex}
\ifxetexorluatex
\moderncvicons{awesome}
\if@symbols
\ifxetexorluatex
\moderncvicons{awesome} % use font-awesome symbols if lualatex or xelatex is used
\else
\moderncvicons{marvosym} % use marvosym symbols pdflatex is used
\fi
\else
\moderncvicons{marvosym}
\moderncvicons{letters} % do not use symbols, use letters
\fi