Monday, 3 May 2010

Recently I started to look for an alternative programming font after spending far too many hours staring at Courier New. I needed to find a free fixed-width font that's easy on the eye and clearly distinguishes between similar characters, e.g. O01Il.

Here's a quick round up of the best alternatives I found. Which programming font are you using? Did I miss your favourite?

Default Monospace Fonts

First let's take a look at the default fonts. The examples show the font at 12 point with subpixel rendering switched off:

Consolas

Consolas is a monospace programming font created for Microsoft by Lucas de Groot and ships with Windows Vista / Windows 7. Has a slashed zero and designed to look best with ClearType enabled.

Courier New

Courier New is perhaps the most familiar monospace font having been introduced in 1992 with Windows 3.1. Courier New is a serifed font designed by Adrian Frutiger and lacks a slashed zero.

Lucida Console

Lucida Console designed by Charles Bigelow and Kris Holmes is the default font for Windows Notepad and also lacks a slashed zero.

Monaco

Monaco is a sans-serif monospace font designed by Susan Kare and Kris Holmes and ships with Mac OS X. Includes a slashed zero.

Alternative Monospace Fonts

While some of the default fonts aren't too bad, we can do much better. Here are some great alternatives mostly designed with programmers in mind:

Anonymous Pro

Anonymous Pro is a programming font designed by Mark Simonson. The serifed font was influenced by Susan Lesch and David Lamkins' Anonymous 9. Very clear with plenty of white space and a slashed zero.

Bitstream Vera Sans Mono

Bitstream Vera Sans Mono is a sans-serif coding font designed by Jim Lyles from Bitstream. The zero is dotted and the bottom of the lower case l curls to the right.

DejaVu Sans Mono

DejaVu Sans Mono is extended from Bitstream Vera Sans Mono and supports a wider selection of characters. The clean sans-serif font ships with a number of Linux distributions.

Dina

Dina is a sans-serif programming font created by Jørgen Ibsen and is available in 8, 9 or 10 point. Has a slashed zero.

Droid Sans Mono

Droid Sans Mono was designed by Steve Matteson of Ascender Corporation. The sans-serif font is clear but lacking a slashed or dotted zero.

Envy Code R

Envy Code R is a clean sans-serif programming font designed by Damien Guard and includes a slashed zero.

Inconsolata

Inconsolata is a monospace programming font created by Raph Levien and inspired in part by Consolas. Has a slashed zero.

Monofur

Monofur is a quirky monospace font created by Tobias Benjamin Köhler. Includes a dotted zero and a curl on the lower case l.

Proggy Clean

Proggy Clean was designed by Tristan Grimmer and is available with either a dotted or slashed zero. Several variants of the Proggy font are available.

Triskweline

Triskweline is a clear monospace font created by Henning Koch. Lacks a slashed zero and only available in 10 point.

21 comments:

O'Reilly uses LucasFonts' TheSansMonoCd for printing code. That's a gorgeous, compact font, and is the best and most efficient thing i've seen so far for typesetting. I haven't tried it for programming (since I don't actually own the font, as it's payware), but I'm curious to know whether it works as a programming font.

Slashed zeros are not the only thing to compare.A good fot for text editor should be:- monotyped- extremely readable- reader should easily distnguish 0 (zero) and O (uppercase o)- reader should easily distnguish 1 (one), l (lowercase L) and I (uppercase i) can be distiguished.

Because of searching for a better font for txt-editor and text-mails i found this article - and after 4h intensive search i found the BEST monospace font of the world: Share-TechMono!

Try yourself, especially in little font sizes (8-12) is has the best and clearest type face AND it is condensed, though a few more letters are in the same line. :)

http://www.dafont.com/share-techmono.font

My 2nd best mono-font is "Liberation Mono", because it is much smaller in line-spacing than the DejaVu-Fonts!

https://fedorahosted.org/liberation-fonts/

--> Hope that helps other people who also find this site by searching for a better font than Times New Courier in Windows.

:) Thomas from Germany

P.S.: Envy Code R is also a very, very good font. And if you like it "a bit lighter", than try "Andale Mono" - the only negative thing - in my eyes - is the "komma" which cannot be seen very good; is looks like a point at a bigger screen resolution of >1024 pixel width. :(

fonts not only for monitor or prints but also for LCD projector.Years i use Lucida Console because its bold, 1 and l is different, best brackets : () and {} looks great on LCD (old) projectors. But the cons of Lucida is O and 0, also the less height of its capital letters. Now I'm looking for font better than Lucida.