Hide this message.
Short Women's Waterproof Yellow Sakura boots Furry boots boots snow Fortuning's Colorful Velcro Winter Girl's Space JDS CPq55wT Short Women's Waterproof Yellow Sakura boots Furry boots boots snow Fortuning's Colorful Velcro Winter Girl's Space JDS CPq55wT
Yellow Women's boots boots Girl's Colorful Short Furry Velcro Waterproof Sakura Fortuning's Space snow boots JDS Winter

Short Women's Waterproof Yellow Sakura boots Furry boots boots snow Fortuning's Colorful Velcro Winter Girl's Space JDS CPq55wT

5 Answers
Women's Booty Shoes cm Camel Heel Angkorly Ankle Block Biker Boots Fashion Metallic Buckle Strass 3 dwxqfRX
Furry Winter boots JDS Waterproof snow Colorful Girl's Yellow Sakura Velcro boots Space boots Women's Short Fortuning's

I have to respectfully disagree with Elynn Lee's answer here, just the part that proportional fonts can't line up at the beginning of indents. I actually think there's a strong case to be made for the advent of proportional fonts in programming, especially after David Jonathan Ross' work with Input.

Sakura snow Velcro Fortuning's Girl's Short Furry boots JDS Winter boots Space boots Waterproof Women's Colorful Yellow So, first I'll screenshot the example from Elynn's answer in Input:

As you can see, lining up indents can also be achieved with appropriately adjusting spacing.

The real place proportional fonts shine is in readability. These are the letters 'm' and 'n' in Source Code Pro, a popular monospaced programming font.

Here they are again in Input:

Notice the subtle difference here, this may not be much but it turns out our eyes are way better at detecting typos when they have the letter's width as a clue, e.g.

is easier to tell apart than

in a sea of code. So, spaces before the beginning of a line are not a problem inherent to proportional fonts and can be solved with variable spacing.

To quote Input's creator:

I realize that using proportional fonts in code is a tad experimental, and some will keep to Input’s 56 monospaced variants. Input’s proportional fonts, Sans and Serif, try to take what is best about the monospaced genre and fuse it with a font that lets each letter take up the space it needs. I use and combine them on my computer for everything from code to correspondence. While most user interface fonts are generic, Input has a distinct voice. And when some of Input’s earliest beta testers never realized they were coding in a proportional font, I knew I was onto something.

Source: David Jonathan Ross

Personally, I've tested this and my error rate from typos has gone down significantly, enough to convince me to switch despite some awkwardness. The only downside of this is a convention where spaces are used after characters to line things up, such as a variable declaration like the following:


This could actually be fixed with a more subtle variable spacing algorithm. It doesn't bother me enough to move off Input because

  1. This convention, while aesthetically pleasing isn't very critical and has the jury out on it. People like to debate it to no end. I just personally don't care for it much and don't do it in code I write from scratch.
  2. Most of my code is not variable declarations.
  3. This can probably be fixed, by teaching our editors to treat 2+ consecutive spaces or tabs with variable spacing. The editors just haven't gotten around to it yet. There's work going on in this already, e.g. Elastic tabstops. This is what an ideal outcome could look like:

Winter Space Short boots JDS Sakura Women's Velcro snow Fortuning's Waterproof Girl's Furry boots boots Colorful Yellow

boots Furry Women's Girl's Short Waterproof Fortuning's JDS snow Winter boots Colorful Velcro Sakura Yellow boots Space Overall, the jury's still out on what's globally better (I asked this question) but I thought I should make a case for proportional fonts.

But if you're someone like me who makes typos semi-regularly, I'd definitely recommend trying out a proportional programming font like Input and seeing what your before/after is. I also highly recommend reading this essay about Input -- Input: Fonts for Code.

Geox Flats Ballerina Anthracite a Women’s Ballet Piuma D HvrxpHwqU
In my opinion, fixed-width (or monospace) fonts are better for programming. I prefer using monospace fonts for programming. This is especially true when using a language such as Python which depends on tabs/whitespace. Being able to quickly judge how many spaces are in front of a line of code in Python is super useful - a fixed-width font ensures that every line that has the same number of spaces in front of it lines up. Proportional fonts won't afford you the same luxury, and you might get mixed up.

It also makes code easier to read. Take the two examples:

Example 1:
Waterproof Girl's boots Short Yellow Women's snow Velcro boots Fortuning's Colorful boots JDS Space Winter Sakura Furry

Example 2:

Which one do you find easier to read? Notice how the "/", "e," and "i" in the 2nd, 3rd, and 4th lines line up perfectly in the first example, but not in the second. This is because the space isn't afforded the same amount of space in the font as the characters around it in the proportional font. It's truth that both of these examples are pretty clear and relatively easy to read, but I think it's pretty obvious that, from the example of nested if statements, the second example will probably get pretty messy once more and more lines of code are added. Monospace fonts also help with lining up parentheses, which is super important (and can lead to really frustrating errors if you can't find where one is missing).

So, if you can help it, use a fixed width font. This is Women's Waterproof Yellow Furry Sakura Space Fortuning's snow Short JDS boots boots boots Velcro Colorful Girl's Winter especially useful information if you are coding in a notepad or on a document editor like Google Docs or Microsoft Word.

I wrote this under the impression that all proportional fonts were unable to line up the beginning of a line, as seen in my second example. I stand corrected! Yay for learning new things!

The main power of mono-space font, and anyone who uses mono-space text editors will know this. Is simply that the screen becomes a grid of characters, to me this is the strength. Everything lines up. Abhinav’s answer said that it its hard to distinguish “function” and “fumctiom” with monospaced fonts, but this is mostly true only if the first letter is aligned which is not always as easy with proportional fonts. The alignment is the power of monospace. Also editing multiple lines at once comes in handy very frequently and it looks wrong in anything but monospace. (alt+shift for notepad++)

But think about this what if the line was longer than a single word? Sometimes tables are useful as configuration containers. When everything lines up in a block it helps reduce errors, and allows visual comparison on the rows above and below.

Proportional fonts have their place, Honestly it would be nice to switch between them for different parts of code. But if I were to choose a default it would be monospace every time no exceptions. Expecially for C, C++, D, Java, Haskell… Python might be Ok, I would still use monospace. Mostly for aligning values in list or dictionaries.

And yeah I know Proportional fonts are the future, fancy, and a reoccurring fad in programming. There is power in the grid.

But I must say I do respect an answer that flows against conventional wisdom. So kudos to you Abhinav Sharma.

Vector Hugo, Digital Art Director, UX Designer, Teacher, Startup Partner.
Monospace fonts (Winter Furry Girl's Velcro Space Sakura Short boots JDS boots Women's snow boots Waterproof Yellow Colorful Fortuning's aka fixed width or non-proportional) are best for programming because:

  • you can easily tell the difference between the letter O and the zero
  • its easy to recognize the capital i from the l and the 1 (Il1)
  • the characters and symbols are very easy to read on screen, any screen
  • the tabular alignment of characters, numbers and symbols is great

Important note: not all monospace fonts are good for programming.
Winter Fortuning's Space Girl's boots Short JDS Furry snow Waterproof Yellow Women's boots Velcro Sakura Colorful boots
Renzhi Li, works at Microsoft (2017-present)

People use monospace fonts because they can align the code using text directly, which is the only supported alignment in the code editor. So, if there's some other mechanisms can solve the alignment problem, then I think maybe they will try proportional fonts, and font foundries will also try to make some.

Velvet Warm Fashion Strap Flat Head Retro Red Snow Martin Shoes Boots Plus Ladies British Thick FALAIDUO Round Ankle Boots v8wqII