July 26, 2016 20:11 / desktop fonts linux /
For the past six months or so, I've been experimenting with a variety of monospace fonts in a quest to find the perfect coding font . While I haven't found a clear winner, I have found a dozen nice-looking fonts and learned a lot about typefaces in general. I've also learned quite a bit about font rendering on Linux , which I hope to summarize in a separate post soon.
In this post I'd like to share some screenshots (or "swatches") of my favorite fonts.
NoteThe screenshots presented below were generated using a little bash script that opened a terminal, sets the font, prints some colored text, then takes a screenshot. It looks a bit like this:
#!/bin/bash font="$1" size="$2" urxvt \ -fn "xft:$font:size=$size" \ -geometry 50x18 \ -e /bin/bash \ -c "demo-text && echo "$font $size" && sleep 0.5 && scrot -u '$font.png' && sleep 0.5" TrueType fontsThe following fonts are rendered with autohinting disabled, medium hinting, no subpixel rendering, lcddefault filter. For example, here are the relevant settings for "Agave" at 11 points:
$ fc-match -v "Agave-11" ... antialias: True(w) hintstyle: 2(i)(w) hinting: True(w) autohint: False(w) rgba: 5(i)(w) lcdfilter: 1(i)(w) ...Here is how these settings look when zoomed in:

Note how, by disabling subpixel rendering, there are no bizarre colors showing up that would lead to color fringing. I also found that using slight hinting would cause some fonts to appear too fuzzy, while full hinting robbed the glyphs of their unique character -- so I settled on medium and have been happy with the results.
Agave
Agave is bundled with some other nice fonts as part of the codeface project .
Ahamono
Available for free on gumroad
Anka/Coder Normal and Condensed

Available for free at fontlibrary.org .
Apercu
BPMono

Available for free at backpacker.gr .
Bront
Available for free on GitHub .
CamingoCode
Available at myfonts.com .
Consola Mono
Available for free at fontsup.com .
Courier Prime Sans
Available for free at quoteunquoteapps.com . Be sure to check out Courier Prime Code as well.
Ecocoding
Available at myfonts.com .
Envy Code R
Available for free on the designer's website .
Fantasque Sans Mono
Available for free on GitHub .
Hermit
Available for free on the designer's website .
Input Mono Narrow
Available for free at fontbureau.com .
Iosevka Term
Available for free on GitHub .
Luculent
Available for free on the designer's website .
M+ 1m
Available for free here .
M+ 1mn
Available for free here .
Monaco
Monofur

Available for free on the designer's website .
Mononoki
Available for free on GitHub .
MonoOne (predecessor to Mononoki)
Available for free on GitHub .
Monospace Typewriter
Available for free on fontsquirrel.com .
MS Gothic
NittiPX

Available on boldmonday.com .
Operator Mono
Available on typography.com .
Pointfree
Available for free on dafont.com .
Pragmata Pro
Available on fsd.it .
Profont (windows version)
Available for free on the designer's website .
SV Basic Manual
Available for free on dafont.com .
Vivala Code
Available on myfonts.com .
Bitmap FontsBitmap fonts require no special rendering as they fit perfectly into the pixel grid. If I zoom way in, you can see that everything lines up:

Dina

Available for free on dafont.com .
Envypn
Available for free in this GitHub repo .
Gohufont
Available for free at font.gohu.org .
Tamsyn
Available for free on the designer's website .
Tamsyn-Modified
Tamzen

Terminus

Available for free on sourceforge, ew .
Termsyn
Tewi

Available for free on GitHub .
Thanks for readingThanks for taking the time to read this post. I hope you found a couple new fonts to try out in your editor. If you're looking for more fonts, I recommend checking out the following GitHub projects:
https://github.com/chrissimpkins/codeface https://github.com/ryanoasis/nerd-fonts https://github.com/Tecate/bitmap-fontsTo learn more about font rendering on Linux, I recommend starting with the Arch wiki . Freetype looks to be changing some things up in the 2.7.0 release, including subpixel hinting ("ClearType"), so keep an eye out for it.