[Tex/LaTex] Friggeri resume – Very different rendering in different readers

pdfresumeviewersxetex

I wrote my CV using the Friggeri resume template, but I just noticed a problem: the document it's rendered very differently between Acrobat Reader and FoxIt PDF Reader and Document Viewer:

The document as displayed on FoxIt and Document Viewer

The document as displayed on Adobe Acrobat

I used xelatex and the icons are symbols from FontAwesome, following this tutorial: https://coderwall.com/p/r67dyq where I defined a new fontawesome.sty.
Also I changed the in the friggeri-cv.cls the colorcounter function to get only the first letter coloured:

\newcounter{colorCounter}
\def\@sectioncolor#1{%
  {%
    \color{%
      \ifcase\value{colorCounter}%
        blue\or%
        red\or%
        orange\or%
        green\or%
        purple\or%
        brown\else%
        headercolor\fi%
    } #1%
  }%
  \stepcounter{colorCounter}%
}

I call the icons on the sections as: \section{{\FA \faStar} Expertise}

Here is my code of the resume, reduced at the essential:

    \documentclass[]{friggeri-cv} 
    % \documentclass{article}
    \usepackage{unicode-math}
    \usepackage{fontawesome}

    \definecolor{light-gray}{gray}{0.55}
    \definecolor{skype}{HTML}{12A5F4}
    \definecolor{html5}{HTML}{e34c26}
    \definecolor{php}{HTML}{6c7eb7}
    \definecolor{db}{HTML}{FF9900}
    \definecolor{linkedin}{HTML}{1683BB}


    \setmathfont{STIXGeneral}
    % \addbibresource{bibliography.bib} % Specify the bibliography file to include publications

    \begin{document}
    \newfontfamily{\FA}{FontAwesome}
    \header{Kiker}{Surname}{Front End Web Developer} % Your name and current job title/field

    %----------------------------------------------------------------------------------------
    %   SIDEBAR SECTION
    %----------------------------------------------------------------------------------------

    \begin{aside} % In the aside, each new line forces a line break
    \section{contact}
    {\color{light-gray}{\FA \faHome}}
    {\color{skype}{\FA \faSkype}} \href{skype:myskype.myskype?call}{myskype.myskype}
    {\color{light-gray}{\FA \faEnvelope}} \href{mailto:myemail@gmail.com}{myemail@gmail.com}
    ~
    {\color{html5}{\FA \faFire}} \href{http://www.mywebsite.de}{Portfolio}
    {\color{gray}{\FA \faPencil}} \href{http://www.myblog.net}{My Blog}
    {\color{linkedin}{\FA \faLinkedin}} \href{http://au.linkedin.com/pub/}{LinkedIn}
    {\color{gray}{\FA \faGithubSign}} \href{https://github.com/}{GitHub}
    \section{programming}
    \small{{\color{red} \FA \faHeart} JavaScript, jQuery,
    {\color{html5}\FA \faHtml5} HTML5, CSS3,
    {\color{php}\FA \faCode} PHP, Groovy/Grails,
    {\color{gray}\FA \faLinux} Linux, LEMP, NGINX,
    {\color{db}\FA \faTh} MySQL, Amazon AWS}
     \section{languages}
     \emph{proficient} English
     \emph{mother tongue} Italian
     \emph{notions} Spanish \& French
    \end{aside}

    \section{{\FA \faUser} About me}

    \section{{\FA \faStar} Expertise}

    \textbf{Professional Capabilities}
    \begin{itemize}
        \item{High-quality front-end development for web sites and applications}
        \item{Modular, DRY, robust and reusable code}
        \item{Performance optimization, progressive enhancement, usability}
        \item{SEO with semantic HTML, Micro Formats and schema.org structures}
        \item{Site planning}
        \item{User interface design}
    \end{itemize}

    \textbf{Technical Skills}
    \begin{itemize}
        \item{Scalable HTML and CSS}
        \item{JavaScript Development (includes advanced jQuery and plugins development, HTML5 API, vanilla JavaScript)}
        \item{Responsive Web Design}
        \item{Mobile development (in browser)}
        \item{Experience with Linux environments.}
        \item{Working knowledge of PHP, using: CodeIgniter, ExpressionEngine, WordPress}
        \item{Experience with Groovy/Grails}
        \item{Working experience with software versioning, in particular Git and Mercurial}
        \item{CSS Preprocessor (SASS, SCSS and LESS)}
    \end{itemize}

    \clearpage
    \section{{\FA \faSuitCase} Experience}

    \section{{\FA \faBook} Education}

    \begin{entrylist}

    \entry
    {2004--2010}
    {Degree in {\normalfont Computer Science and Automation Engineering}}
    {Polytechnic Marche University, Italy}
    {  }

    \end{entrylist}


    \section{{\FA \faQuote} Recommandations}


    \end{document}

** This is how the fontawesome.sty looks like:**
I have the fontawesome font installed on my system

\def\faUserMd{\symbol{"F200}}

\def\faLinux{\symbol{"F17C}}
\def\faHtml5{\symbol{"F13B}}
\def\faCode{\symbol{"F121}}
\def\faQuote{\symbol{"F10D}}
\def\faSuitCase{\symbol{"F0F2}}

Best Answer

I also encountered this problem while trying to achieve exactly the same thing as you with the Friggeri template. This problem comes from a bug with the pdf engine of XeLaTex with OTF font file format when it is at a particular resolution as discussed in http://typophile.com/node/46451.

As a workaround, you can use the .ttf version of the font. To do this, download the latest FontAwesome package at http://fortawesome.github.io/Font-Awesome/. Then extract the content and copy the file named "fontawesome-webfont.ttf" in a sub-folder named "fonts" in your LaTex document's location. Then, the font can be loaded and used in LaTex manually like this for example:

\documentclass{report}

\usepackage{fontspec}

\newfontfamily{\FA}[Path = fonts/]{fontawesome-webfont}

\def\faLinux{{\FA\symbol{"F17C}}}
\def\faSE{{\FA\symbol{"F18D}}}
\def\faSkype{{\FA\symbol{"F17E}}}
\def\github{{\FA\symbol{"F092}}}

\begin{document}

\noindent
Linux icon: \faLinux \\
StackExchange icon: \faSE \\
GitHub icon: \github \\
Skype icon: \faSkype

\end{document}

Which is supposed to yield to:

enter image description here

Everything seems to work fine so far for me. You can take a look at my GitHub where I exactly did this with the Friggeri-cv template. I am working in the Ubuntu 14.04 LTS environment.

Related Question