# Helvetica font has jagged edges

I use 'Helvetica' as my font and build my document using Texmaker. But the PDF generated has jagged edges while using this font and when I use a different font (say Times or even Helvetica sans-serif) it builds just fine.

Please suggest if there is anyway I can get over this. The problem with these jagged edges is that it appears very dull and unreadable at 100% resolution.

OK guys, now here is the MWE

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\documentclass[a4paper,twoside,12pt]{book}

%% Language %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\usepackage[T1]{fontenc}
\usepackage[latin1]{inputenc}
%\usepackage[utf8]{inputenc}
\usepackage{graphicx,color,subfigure}

%% Line Spacing %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\usepackage{setspace}
%\singlespacing        %% 1-spacing (default)
%\onehalfspacing       %% 1,5-spacing
\doublespacing        %% 2-spacing

%% Other Packages %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\usepackage[left=1.5in, right=1.5in, top=1in, bottom=1in, includefoot, headheight=13.6pt]{geometry}
\usepackage{helvet}
\usepackage[square,numbers]{natbib}
\usepackage{hyphenat}
\usepackage{fancyhdr}

\begin{document}

\pagestyle{empty} %No headings for the first pages.

\cleardoublepage %The first chapter should start on an odd page.

\pagebreak

%------------------------------------------------------------------------
\chapter{Divorce}

A major change that has occurred in the Western family is an increased incidence in divorce. Whereas in the past, divorce was a relatively rare occurrence, in recent times it has become quite commonplace. This change is borne out clearly in census figures. For example thirty years ago in Australia, only one marriage in ten ended in divorce; nowadays the figure is more than one in three (Australian Bureau of Statistics, 1996: p.45). A consequence of this change has been a substantial increase in the number of single parent families and the attendant problems that this brings (Kilmartin, 1997).

\end{document}

• Welcome to TeX.SX! Please add a minimal working example (MWE) that illustrates your problem. It will be much easier for us to reproduce your situation and find out what the issue is when we see compilable code, starting with \documentclass{...} and ending with \end{document}. – Ch'en Meng Dec 12 '13 at 6:21
• The image you've posted does not show text set in Helvetica. (Instead, it looks like Computer Modern.) Please post a different image. – Mico Dec 12 '13 at 6:30
• It is Helvetica with serif. – Rakesh Dec 12 '13 at 7:08
• Sorry, but no it isn't. Mico is right. It is set in Computer Modern also kind of compressed in height. Please give as an example so we can see, what is going wrong. If that really is Helvetica Serif, just have a look on the default font, which looks quite similar. – LaRiFaRi Dec 12 '13 at 7:47
• You cannot blame anybody here for not knowing a seriffed Helvetica. A quick google search brought me to Helvetica Neue Serif. But since Helvetica is a sans-serif font, we need to know what you are doing. Please providee an MWE as it has been requested by @Ch'enMeng before. It would be helpful as well to see the output of pdffonts. – Johannes_B Dec 12 '13 at 7:48

After reading the comments, I think there are some points which are not correctly understood by the OP, so I'll try to clarify them here. This is not properly an answer, but it is too long for a comment.

## 1. "Helvetica with Serif"

There is not such a thing. Helvetica is a Sans Serif font. When you use package helvet, you are asking TeX to substitute "Computer Modern Sans Serif" for "Helvetica", but the main text, which uses "Computer Modern Roman", is not changed.

At first, I thought (as other commenters) that the OP was indeed trying to use some obscure font based on Helvetica but with serifs, such as the one pointed by Johannes B. But now I think that the OP wrongly assumed that helvet package provided two kinds of Helvetica, one Sans, other with serifs. As explained, this it not the case.

## 2. "Jagged edges"

Original Computer Modern fonts created by Donald Knuth were made with a program called Metafont (also by Knuth). This program took a source which matematically describes the shapes of each glyph in a font, and produces one bitmap for each glyph. When generating PostScript or PDF, those bitmaps were collected into a "Type 3 Font" and embedded in the final file. These bitmaps are generated for a given printer resolution (eg: 300dpi). If you zoom above that resolution, the individual pixels of the bitmap are visible. In addition, even if you don't zoom, some PDF readers render those fonts somewhat blurry and difficult to read (Adobe Reader is one of these).

PDF (and PostScript) support another font format, called Type1 fonts, which do not have this problem, because it is a vectorial format. Instead of bitmaps, it contains the mathematical curves describing each glyph. Functionally this is the equivalent of the original Metafont format created by Knuth, but the "render" of those glyphs in order to display (or print) them are made by the PDF reader (or printer).

Given that Metafont and Type1 are conceptually equivalent, one could thing that it should be possible to convert the original Computer Modern fonts designed by Knuth with Metafont into PS/PDF Type1 fonts. Unfortunately, it is not possible beacuse they use different kind of mathematical curves to describe the glyphs.

The only reasonable approach to convert Metafont into Type1 is to, first convert Metafont into bitmap, then trace the bitmap and manually adjust the result to make it look good at any resolution.

This work was done time ago, and now TeX ships with Computer Modern fonts in Type1 format, so when generating PDF this is the font used, and all looks right at any zoom level.

## 3. Font encodings

Original Computer Modern fonts used internally a special encoding called OT1. This encoding defines a mapping between numeric values (the code of each character), and the glyph (the graphical representation of that character). OT1 is mostly compatible with ASCII, so character code 65 is associated with the glyph which draws an "A".

However OT1 encoding did not provide codepoints (nor glyphs) for some characters widely used in European languages. For example, there is no glyph for any accented char. When the author of a document types \'e, TeX generates two "overimposed" codes, one for the glyph "e", other for the glyph with the accent.

This approach has some drawbacks. First, the PDF actually contains two codes for the "é" (one for the accent, other for the "e"). This can cause problems with copy&pasting text from the PDF, or searching in the PDF. Also, the TeX hyphenation rules have problems with words containing accents, due to this encoding.

To solve those problems, T1 encoding has to be used. Beware, T1 does not mean "Type1 fonts". A "Type3 font" can also use T1 encoding. Fonts using T1 encoding have specific glyphs for accented chars and other chars originally absent from Computer Modern. So, if \usepackage[T1]{fontenc} is used, TeX will load fonts with T1 encoding and when the author writes \'e, TeX will output the code of the glyph "é" (instead of separate codes for the accent and the "e").

But in order this to work, some T1-encoded fonts are required. By default TeX ships with a variant of Computer Modern encoded with T1, sometimes called "European Computer Modern". When you request T1 encoding, if the font in use is Computer Modern, TeX will load "European Computer Modern" instead. And, guess what? this font is only available in Metafont format, and thus rendered as bitmap.

Note that you don't require T1 encoding if you write in plain english (no accented chars, etc.) Default OT1 encoding is ok for english, and in this case TeX will use OT1-encoded Type1 CM fonts, which do not look "jagged".

## 4. cm-super and lmodern

Recently all those problems were solved by the creation of new fonts based on Computer Modern and European Computer Modern, but in vectorial Type1 format. Indeed, there are two solutions.

cm-super is a "drop-in" replacement for Computer Modern. If you install this "package", TeX will be configured to use those fonts by default. Then you don't need to change anything in your document (no \usepackage required). Just compile it again and you'll get proper Type1 vectorial fonts, and T1 encoding. All problems solved.

lmodern is an alternative font with the same goal, but it requires \usepackage{lmodern} in order to be used.

## 5. Solution to OP question

So, apparently the OP asked for a way to have "Helvetica with Serifs" properly rendered in the document. But there is not such a thing. So what alternatives does he have?

1. Use package helvet to change to Helvetica only the headers, leaving the remaining of the document with Computer Modern. To avoid the "jagged" edges in this case, \usepackage{lmodern}.

2. Use Helvetica for the whole document (both headers and main text). See Johannes B's answer for this.

3. Search some font with serifs which "looks good" with Helvetica, and use it for the main text. Traditionally, the serif font used with Helvetica is Times Roman. You can get it with \usepackage{times}. This font is available by default with T1 encoding and Type1 vectorial format, so it will not cause troubles. Another possibility is \usepackage{tgtermes} which uses font TeX Gyre Termes, based on Times but heavily extended (thanks to Johannes_B for suggesting it).

• Can you mention Tex Gyre Termes along with times? +1 for your effort – Johannes_B Dec 12 '13 at 15:32
• But shouldn't TeX be using the type 1 versions of the fonts anyway? So that output suggests that the type 1 versions of CM are not properly installed, doesn't it? Since TeX will use those in place of metafont CM if they are available? At least, that's what I thought... – cfr Dec 15 '13 at 3:34
• @cfr CM fonts are available out-of-the-box in Type 1 only for OT1 encoding. If you switch to T1 encoding, then Type1 fonts may be not available, unless you install cm-super or lmodern packages. If cm-super is installed, then your assumption would be true, i.e. tex will use Type1 version transparently. However, for lmodern fonts the author has to add \usepackage{lmodern} in the document to force their use. – JLDiaz Dec 15 '13 at 9:46
• Very illuminating answer @JLDiaz, thank you for taking the time to be so helpful to the OP (and to everyone else who discovers this question). – ShreevatsaR Oct 13 '16 at 3:12

As suggested in the LaTeX Font Catalogue you need to load the font before loading fontenc. But much more important is to use a sans-serif font. If you want to write the complete document with the helvetica, uncomment the line at the beginning of the example. A look at TeX Gyre Heros might be interesting as well.

\documentclass[a4paper,twoside,12pt]{book}
\usepackage[scaled]{helvet}
\renewcommand*\familydefault{\sfdefault} %% Only if the base font of the documen%t is to be sans serif
\usepackage[T1]{fontenc}
\usepackage{selinput}
\SelectInputMappings{
germandbls={ß}
}
\usepackage{blindtext}

\begin{document}
\chapter{Divorce}
\blindtext
$a^b$

{\sffamily \blindtext}
\end{document}


If you can avoid it, do not doublespace your lines. It looks really ugly.
Be aware, that the Helvetica and the standard math font do not work well together.

• You can get some characters in your math to be sans serif by using Don­ald Arse­neau's package sansmath: ctan.org/pkg/sansmath – WillAdams Dec 12 '13 at 13:42