A free font for coders by Jens Kutílek
In 2009 I wasn’t satisfied with the available text editor fonts and decided to draw my own: Sudo. Over the last years I used it as my main font in the Terminal, as well as my text editor font for coding on Mac and Windows. Whenever something bugged me, I refined the design and could instantly evaluate if a change was an improvement.
Download Sudo v0.40 for free. (1.6 MB zip file, desktop and web fonts.)
If you are not sure yet, have a look at the glyph proof for Sudo Regular (PDF, 470 kB).
There are many reasons why most programmers still prefer monospaced fonts. All letters have the same width in all weights. Proportional alternates are available for some letters via OpenType layout features.
When some letter forms are ambiguous in prosa, we can easily read them because we know the context. But when coding, all characters have to be unmistakably recognizable. It is common to add serifs to an uppercase I or a hook to the lowercase l. I don’t care very much for dotted or slashed zeroes, so I decided to make all numbers one line width smaller than the uppercase letters. They still stand out enough because most code is in lowercase anyway.
A dotted zero is included via the ‘zero’ OpenType feature, but text editor support is lacking. If you absolutely must have a dotted zero, you can use the Python script ‘patch_dotted_zero.py’ included in the download to make the alternate zero the default form. The patcher requires an installation of the Python FontTools.
From version 0.37, the default zero has a dot by popular demand. You can still wap it with a dotless 0 via OpenType feature ‘zero’ or with the included Python script ‘patch_dotted_zero.py’. The patcher requires an installation of the Python FontTools.
The width of all letters is 44% of the font size. This allows you to fit more code in the same space. For example, the character width in other fonts is between 55% (Consolas) and 60% (Courier).
Sudo has been designed on a pixel grid for a font size of 16 pixels, but works well in other sizes as well.
This is a first: As far as I know, Sudo is the first and only font to feature what I like to call ‘coder’s quotes’. Some programming languages use the acute and grave accents as a replacement for opening or closing quotes. The standalone accents in Sudo are much bigger than the ones on the accented letters and work well together with the straight and typographic quotes.
I designed Sudo strictly for my own needs. Completist as I am, I couldn’t resist adding Greek and Cyrillic letters, but a lot of these haven’t left the pixel design stage. For me they don’t have a very high priority, sorry. If you like to work on their design, please send me any additions via GitHub.
The Bold weight is far from finished. The basic alphabet is done, but lots of less common characters are still the same as in Regular. The Italic weights are just the upright styles slanted by 11.31° with partial corrections. The Thin masters are extrapolated from Regular and Bold, also with partial corrections. If you fix something, I’d like to get your pull requests.