15

I downloaded the cm-super package and for comparison, created 5 versions of my document with different fonts:

  • Computer Modern
  • CM-Super
  • CM-Super with microtype
  • Latin Modern
  • Latin Modern with microtype

All 5 versions were then uploaded to Google Docs and viewed with their PDF viewer which AFAIK generates PNG images for the browser to display.

Here is an image showing a portion with Computer Modern:

This is Latin Modern with microtype:

As you can see Latin Modern was rendered into an ugly duckling. The same happened to CM-Super too. Disturbing about this is that CM-Super and Latin Modern look much better in Adobe Reader than CM, so it seems I have to decide between online and offline viewing.

My question is:

  1. Why does this happen?
  2. How can I disable cm-super in MiKTeX if I decide upon using the original CM font? Is uninstalling in Package Manager the only way (and does it work)? (Sorry for so distant questions.)

EDIT: MWE
Unfortunately you can't switch cm-super on and off so simply.

\documentclass{minimal}
\usepackage[magyar]{babel}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
%\usepackage{lmodern}
%\usepackage{microtype}
\begin{document}
A természettudományok az általuk vizsgált jelenségeket gyakran differenciálegyenlet-rendszerrel írják le. Ekkor fontos szemponttá válik annak eldöntése, hogy az adott rendszer stabil-e. A stabilitás hozzávetőlegesen azt jelenti, hogy a külső körülmények (kezdeti feltételek) piciny megváltoztatása nem okozza a rendszer működésének (a megoldásnak) radikális megváltozását.
\end{document}

EDIT 2: It seems that Google Docs' problem is with vectorized fonts in general. The non-T1 encoded original CM fonts also looked ugly. (The T1 encoded CM fonts are raster fonts.)

7
  • See also tex.stackexchange.com/q/18519/627
    – Lev Bishop
    Dec 14, 2012 at 22:01
  • 1
    Is it possible that Google Docs is screwing up the rendering?
    – percusse
    Dec 14, 2012 at 22:30
  • 4
    Add \pdfmapfile{} at the beginning of your document and no map file will be read in. If the document uses only CM (or, more precisely, European Modern, as you're using T1 encoding), the bitmap versions will be created and used. It's not difficult to create a new map file that doesn't use the CM-Super fonts.
    – egreg
    Dec 14, 2012 at 22:36
  • @percusse That's for sure.
    – marczellm
    Dec 14, 2012 at 22:44
  • @egreg Thanks, that worked! Is that safe?
    – marczellm
    Dec 14, 2012 at 22:45

1 Answer 1

15

I don't think that making one's PDF worse just because a bad previewer isn't able to render it is the right answer. If a previewer is bad, I simply don't use it.

However, it's not difficult to prepare a personal map file that doesn't use the CM-Super fonts.

  1. Copy pdftex.map in a working directory, renaming it to, say, pdftex-nosuper.map; you find the location of pdftex.map by looking in any log file created by pdflatex, but on a Unix system (and bash), just

    cp $(kpsewhich pdftex.map) .
    

    will do.

  2. Open the file in a text editor

  3. Remove all lines where the string cm-super appears (a Perl or sed script can do it automatically)

  4. Save the file and put a copy of it in your personal tree; on a GNU/Linux system this should be in ~/texmf

    mkdir -p ~/texmf/fonts/map/pdftex
    cp pdftex-nosuper.map ~/texmf/fonts/map/pdftex/
    
  5. Put the line

    \pdfmapfile{pdftex-nosuper.map}
    

    at the start of your LaTeX document.

When pdftex will process your document, bitmaps for the fonts covered by the CM-Super fonts will be created and downloaded in the PDF output.

Note: if you're using MacTeX on Mac OS X, then instead of the ~/texmf prefix, use ~/Library/texmf. With TeX Live on Windows, the commands for creating the directory and doing copies of files will be different. For the correct location with MiKTeX, consult the documentation.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .