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.
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.
ReplyDeleteI just use whatever font comes with emacs ;)
ReplyDeleteDidn't know I had such a big number of fonts to choose for...
Ruben
Might want to check out http://www.cosmix.org/software/ for variations on Droid Sans Mono with dotted and slashed zeros
ReplyDeleteI was looking for a new monospace font just last weekend, and I quite liked the ANSI commisionned OCR-A font.
ReplyDeletehttps://secure.wikimedia.org/wikipedia/en/wiki/OCR-A
It is fixed width and ttf, and can be found in most GNU/Linux distributions' repositories.
You must be from Linux. You've made nice fonts look ugly.
ReplyDeleteAndale Mono is the best. Trust me.
ReplyDeleteIs there a reason your samples contain no lowercase? Adding this would make for better comparison. Otherwise, interesting article.
ReplyDeleteSlashed zeros are not the only thing to compare.
ReplyDeleteA 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.
You might find this interesting, it's a comparison of different monospaced and proportional fonts for programming:
ReplyDeletehttp://nickgravgaard.com/elastictabstops/news/programming-fonts/
I've become fond of Liberation Mono by Steve Matteson of Ascender (like the Droid Mono font). - http://www.dafont.com/liberation-mono.font
ReplyDeleteI typically use Consolas, Deja Vu Sans Mono, Crisp or Courier New.
ReplyDeleteI especially like fonts with big differences between l/1 and O/0
Have used them all. Hard to unseat Dina, Consolas, and Lib. however current champion is M+ 1m, also referred to as Mplus mono.
ReplyDeleteHere are the results of the poll:
ReplyDeleteAnonymous Pro
1 (1%)
Bitstream Vera Sans Mono
3 (4%)
Consolas
13 (20%)
Courier New
5 (7%)
DejaVu Sans Mono
6 (9%)
Droid Sans Mono
2 (3%)
Envy Code R
2 (3%)
Inconsolata
11 (17%)
Lucida Console
3 (4%)
Monaco
4 (6%)
Monofur
1 (1%)
Proggy
3 (4%)
Triskweline
3 (4%)
Other (please comment)
6 (9%)
Try terminus.
ReplyDeleteBecause 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!
ReplyDeleteTry 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. :(
http://web.nickshanks.com/fonts/microsoft-core-web-fonts
Lucida console is the best for me, as it packs more lines for the same point size. If someone creates a dotted zero version, it would be perfect.
ReplyDeletefonts not only for monitor or prints but also for LCD projector.
ReplyDeleteYears 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.
Well i just tried Anonymous Pro and it seems the best fur me
ReplyDeleteRobert Pelloni's worse proportional web font (bobsgame.ttf) is downloadable from game.bobsgame.com and file size is 25.7 KB. Lacks Macintosh Roman naming data.
ReplyDeleteAnonymous Pro contains most of the necessary diacritics for Indo-Tibetan studies.
Consolas might have a zero with no dot, accessible as OpenType features.
The font bobsgame is made by Robert Pelloni. Has a single-story a and a slashed zero. Available in proportional only.
Folks should also take a look at Source Code Pro: http://blogs.adobe.com/typblography/2012/09/source-code-pro.html
ReplyDeleteSee a Triskweline-Code, Slashed zero + bold & some unicode chars. https://github.com/ideasman42/triskweline-code-font
ReplyDelete