2

I realized that Latin Modern font looks heavier in XeLaTeX and lighter in pdfLaTeX. Why? How can I get the same lighter look in XeLaTeX? IMHO, the XeLaTeX look is too heavy and I'd like to have the pdfLaTeX look with XeLaTeX. (I need to use XeLaTeX due to another .ttf monospaced font.)

(In the screenshot below, left is pdfLaTeX and right is XeLaTeX.)

Screenshot to illustrate the issue

  • This is very much reader dependent. pdflatex and xelatex use different font types (type1 postscript for pdflatex, and otf for xelatex). The readers may handle these differently and therefore may look different on screen. – ArTourter Jan 3 '16 at 1:08
  • @ArTourter It seems you're right: I've tested with the Google Chrome's internal pdf viewer, and now there's no visual difference. Thank you very much! – Ricardo Pérez López Jan 3 '16 at 9:24
5
\documentclass{article}
\usepackage{ifxetex}

\ifxetex
  \usepackage{fontspec}
\else
  \usepackage{lmodern}
\fi

\begin{document}

\huge Desarrollo web en entorno servidor

\end{document}

I compiled this with

pdflatex -jobname desapdf desarrollo

and with

xelatex -jobname desaxe desarrollo

Top pdflatex, bottom xelatex:

enter image description here

I see no difference.

  • Could you please provide the full source code which produces your output? Thank you! – Ricardo Pérez López Jan 3 '16 at 0:56
  • Thanks again :). It seems to be a reader's issue, as @ArTourter suggested. – Ricardo Pérez López Jan 3 '16 at 9:22
  • as a last favour, could you please provide both .pdf files, so I can test them with my viewers? Thanks a lot! – Ricardo Pérez López Jan 3 '16 at 14:08
  • @RicardoPérezLópez The site doesn't allow adding PDF files. – egreg Jan 3 '16 at 14:11
  • oops, didn't know that, thanks anyway! – Ricardo Pérez López Jan 3 '16 at 14:17
0

As @ArTourter suggested, it seems to be a reader issue: I've tested with the Google Chrome's internal pdf viewer, and now there's no visual difference.

Screenshot

(LaTeX on left, XeLaTeX on right).

Interestingly, both Evince (the Gnome PDF viewer) and the TexStudio interval viewer has the same issue.

This is TexStudio with LaTeX output:

TexStudio with LaTeX

And this is with XeLaTeX output:

TexStudio with XeLaTeX

Maybe both Evince and TexStudio use the same render engine?

[Edit to comment that the Xpdf PDF viewer has the same issue:]

enter image description here

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.