I tried a couple Mono Fonts and found them all kinda samey.
I ended up seeing a post here for Berkeley Mono, a paid font, and I noticed in particular that it was incredibly readable compared to other mono fonts I was using, so much so that I've zoomed out one level on VS Code and iTerm and have similar readability as before.
It was the first font I paid for, and I was quite happy with it.
I felt weird buying Berkeley but I’m very happy with it as well. I knew I liked it when I got the trial and yet I felt this aversion to paying for a font for several weeks. Then it dawned on me: I was depriving myself of enjoying someone’s hard work because I didn’t want to spend a fairly small amount of money for a thing I’d use for my work every day. Sort of an everyone loses situation. I can be bizarrely cheap, and it’s kind of embarrassing when I break it down. I lose time and money to my irrational cheapness.
Berkeley’s sharpness and legibility has been unmatched for me and I think that’s what draws me to it so much. I know others will say it’s not sharp or legible, and it’s a totally personal thing. We get good at reading on different screens with different characters, and we’re gradually trained to see in different ways. For me, Berkeley absolutely nails it.
I too have been following the Berkeley Mono font, and I think their website and promo materials are all very well designed. However, I tried the trial version of the font and found the kerning odd and unnatural seeming.
I can relate to GP's feeling here. When I first installed Berkeley Mono and looked at some code in it, I had the same reaction: the spacing between characters looked inconsistent in some words. I think that some other monospace fonts do a better job of making the narrow characters ("i", "l", etc.) match the width of wider characters.
That said, I've been using it for a couple weeks now, and have stopped noticing that.
My main issue with it now is that some italic glyphs get cut off in my terminal, but I'm not sure if that's the font's fault or my terminal's fault.
You're correct. I had assumed it was the "i" and "l" that were giving the "something is off about this text" feeling, but I just opened up some sample text to try to figure out exactly which characters are doing it and can see that the "i" and "l" actually look fine to me.
It seems like the "r" is actually the main culprit. The spacing before and after "r" tends to feel too big to my eye.
I used the wrong term but you nailed it. The 'r' is definitely a problem for me too.
EDIT: Ok, I feel like this demonstrates the issue pretty well. The 'r' is a problem for sure, but notice how off balance the rest of the word looks? Evidently, there is no kerning (as I've learned) with monospace fonts, but then why does the spacing between these letters appear to variable to my eyes? The spacing between the 'om' looks weird too. This is just a screen shot from Font Book.
Fira Code and others do an ugly thing with 'r' that is a huge point of contention. There is a thread on Github that describes the frustration well: https://github.com/tonsky/FiraCode/issues/601
This is a fundamental trade off between aesthetics of the char itself vs. the aesthetics of spacing between chars. It comes down to personal preference and fits the "boring" description from Berkeley Mono marketing page.
Perhaps there should be an option for two types of 'r', one with a base and one without. That'd be great!
> This is actually a problem with any font that has an 'r' without a base.
>
> For example, Andale Mono: https://i.imgur.com/PeLZrj4.png
But in Berkeley Mono it'd be easily fixable: when the lowercase r's upperbar is a straight horizontal line (as it is in Berkeley but not in Andale Mono), you can simply make that horizontal bar a little tiny bit wider, which shall give the illusion things are more balanced.
I did create my own font with a 'r' like that (but I cannot share it as I stole inspiration from commercial fonts).
If you look at the word "proc" and "return" here [1], it looks great and extremely well balanced. There is also a problem of choosing specific examples like the word "random" which has a bad pairing with "ra". You're right though, it can be improved.
You make it sound like I engineered this. "Random" was the first word that came to my mind because it was random. If you install the trial font, you'll notice this off balance look in a lot of the text you type, not just the example word I chose.
Even if monospace doesn't have "kerning" can't they create a "ligature" for "ra" instead? Doesn't have to be a weird hybrid symbol, just tweak the spacing so it looks right.
I keep glancing at Berkeley Mono's site since it popped up on HN recently when they added ligatures. As a Fira Code user for some time now the ligatures are a "must have" for me, so that helps a lot. Something about the overtly 70s Mainframe aesthetic doesn't quite hit for me (though very well crafted and almost), though I have to say what little is currently teased for their next font Houston Mono has me intrigued enough to sign up for their mailing list.
Why? This whole article and almost are all the comments are on how many existing choices there are and "designer supports ligatures" is an easy enough filter to find a good, strong subset. I don't need it to be anything more than a filter of current options.
For my mono font, I converted the Atkinson Hyperlegible[0] font into mono, and have been using it as my terminal and editor font for over a year now. It's pretty janky, but it's surprisingly lasted longer than many of the other fonts I've tried over the years.
This is a nice overview. I don't share the author's intense distaste for serifs. In my search I ended up on Cascadia Code, which wasn't part of this comparison: https://github.com/microsoft/cascadia-code
Of his existing incumbent choice, Inconsolata, the author says:
> Unfortunately I am failing to find the words to explain why this pleases my eyes so much; a screenful of it makes me happy.
One theory about why would be that he has been looking at it day in and day out for years, and we tend to think that things we are more familiar with are more beautiful.
This describes me. Every couple of years I read an article like this, download a handful of monospaced fonts, and try to use each one for at least an hour. Inevitably, every one of them has some little problem that rubs me the wrong way, and I go back to my old standby: Consolas, the dad jeans of programming fonts. I've been using it for 15 years, and I think I'm doomed to use it for the rest of my career.
Then there are people like me that will use the default font provided by the software they use. I have absolutely no idea what coding font I use (and it varies between IDE anyway).
Similar for me. Sometimes articles like this motivate me to find a new font. I spend some hours deciding on one and then use it. Until I wrote my device (I use windows, so once a year), lose the font, and don't even realize it. This repeats with the next article.
Inconsolata is also my choice. It's like a monospace font with light serifs, and looks great on high res displays. Very pleasing. In my case, I knew that I liked it shortly after discovering it.
Is there some sort of organisation or society for people who just don't care about fonts? I think we need a secret handshake or a bumper sticker or something.
I use Comic Code for programming[1]. At some point I got bored of all the squarish typewriter-like fonts that makes code look boring and mechanical. Comic Code is fun and human.
I used monofur[0] for the longest time, which is squarely in the category of quirky fonts, though definitely more regular than comic sans. It has basically no confusible characters in it at all which is a nice property.
oh I care, it's just that I think the ideal font is the one you're used to and so you should simply pick the OS default everywhere. Plus those fonts are pretty good anyway so why not.
> Uh, no, it smells of mainframes. Look at some of those 90° serifs, right out of the 1950’s.
maybe that's why I like IBM Plex Mono so much. My go-to font has always been DejaVu Sans and before that Bitstream Vera Sans, which are pretty much the same font. But I like IBM Plex after using it for awhile.
I'm not that anal about serifs or whatnot. But a font has to "feel" right with a page of code open. And the very minimum they have to get the O (letter "O") vs. 0 (number zero) right as well as I (letter "I") vs. 1 (number one). If you can't get that right then it's a useless coding font.
The problem with codingfont.com is that it overrides the line height, so you won't see what the line height will actually look like in your editor, which is something that I care about.
If your editor doesn't allow you to override the font's default line height (to whatever you like), there's a nice little tool you can use to do this to the font file itself: https://github.com/source-foundry/font-line
This is also useful for mixing and matching fonts. Nicolas Rougier uses this in NANO Emacs to hack the Victor Mono italic to have the same line height as Roboto Mono.
I think the point is that their editor does, but the website above for previewing doesn't. If you have to download and and edit the font file manually to get the website to preview it, you might as well just preview it in the editor instead.
Thanks for the send. I'm new to choosing a font for my editors, and just went through the tournament. I've got to say, Inconsolata is quite a finessed font for coding. It definitely seems to work well for me.
I do wish that site let you "exclude" certain options so they never appear in the tournament at all. It would have saved time, one or two are so awful they aren't work doing comparisons on.
It even includes Anka/Coder, my personal favorite. It doesn't include anything but Regular, not its variants like Narrow, but still quite a complete project.
Playing the font tournament is fun, especially with the font names turned off. I ended up with Fira Code (my current preference) vs Fira Mono in the final round.
i downloaded my winner, installed it, changed my editor... and immediately went back to Monaco :) there's a lot of cognitive momentum to overcome in switching fonts.
I thought it would be silly or I would hate it, but the comic sans like nature of Fantasque Sans Mono really surprised me and worked well for coding/IDE use (especially in Python): https://github.com/belluzj/fantasque-sans
Yes, my favorite font for text editing. Not too unprofessional like comics-san but not dull/sterile like most mono fonts. Not sure why, but it has sort of an artistic personality, if I could describe it. Only thing I dislike is the "k" so I use the non-loop version.
I really don't get the current trend of font ligatures for things such as !=. It seems to me you loose the fundamental structure of the code. I get it looks good in screen shots on Twitter but when I tried a font with them it just seems to make me have to pause and think more.
Agree with you, tried it a couple of times and found it more distracting than anything. One gripe is seeing one character, hitting backspace and instead of removing one character, it changes to another character rather than deletes it ("≠" -> hitting backspace expecting "" but instead seeing "!" now).
I love ligatures. I find that well crafted ones make code look more coherent without detracting in any way from the structure (unlike proportional fonts which I abhor).
They're also very useful for languages which have operators which are easy to confuse, like the triple equal of PHP and JS (in which case having a ligature that's really distinct from the double equal is very convenient).
The difference is obvious when paired together next to each other like that, but the issue with code is often you are looking at examples (often with weary eyes) that are "miles apart" or the only one in a file and trying to spot the difference.
The ligatures that stack a third bar vertically across the space of three characters do jump out at you as much more meaningfully distinct in isolation. You don't have to just count width or whitespace, you have a third "clue" to work with, and sometimes that extra "clue" is incredibly important when you are tired and staring a bunch of code you expected to work and has a subtle bug and need to visually spot the subtle bug.
I love them and use them everywhere I can, mostly with JS/TS. I find the code displayed with ligatures more readable, and the only time I notice any overhead is when modifying === to !== or back, when I have to remember that I have to change only the initial character. Having => as arrows instead of `equals+more than` is enough of improvement, for me, that I keep using them, even without all other tiny tweaks that they give you.
I used to use "Fira Code", but then I've migrated to "JetBrains Mono" everywhere.
Personally, I generally agree with you - ligatures add a layer of ambiguity. Toyed around with the idea of "precision ligatures", but it only works a subset of ligatures.
It's important to keep in mind that ligatures are at the presentation layer, i.e. when the glyphs are drawn. You can still copy and paste the text, underlying representation is still individual chars. Also, ligatures are optional, so why not; a lot of people love them.
Slightly off-topic, but why does your site not work in Russia? I'm currently in Russia visiting family, and need to turn a VPN on just for you, as anything else I use works perfectly fine. I sure hope it's not politics, because the last thing I need is fonts to be politically charged.
It seems like a little bit weird to have ligatures in a monospaced font. The whole reason ligatures exist is so that bits of letterforms in closely-spaced type don't crash. That shouldn't happen in a monospace font. If you're just changing the space so that two characters are grouped as a kind of unit, that to me defeats the purpose of using monospace to begin with.
I'm a big fan of ligatures and it is now a "must have" when choosing a coding font for me.
The "fundamental structure of the code" doesn't change, all those same mostly-ASCII code points are there unchanged. (Copy and paste still works. Source control works, obviously.) It's just a presentation thing.
There's also an argument (often used most especially by Functional Programming proponents and languages) that the "fundamental structure of the code" is actually the math behind the code and our mostly-ASCII assortment of programming language symbols are the easier-to-type/encode/transmit compromise of the mathematical fundamentals. From that perspective, ligatures are more "fundamental" by better expressing their mathematical underpinnings than the raw text that describes them.
> it just seems to make me have to pause and think more
A classic Python mantra is that "code is read far more often than it is written". If it might be a little slower to write, but it speeds up reading comprehension, that alone can be a major productivity win, per that mantra.
Of course, I think there's a familiarity thing at play here, too. Just like most things we learn, there's an early learning curve where it seems harder to work with something like ligatures because you are unfamiliar with them, but eventually you gain familiarity and are just as fast writing it as you were before.
Since an editor setup is very personal, it doesn't really matter if other people can't immediately recognize that the ligature is == or != .
Personally I love ligatures and find that they help me to immediately grasp code structure since they are unique glyphs. Without them there is a slight delay when scanning things and your brain needs to do lookahead and lookbehind to be sure -> isn't just > or the ! in != isn't a random not.
Fira Code and Cascadia Code add an entire third "bar" vertically to the triple equals. It may be subtle at first, but eventually it becomes a massively useful difference.
Yes!! I would so like to have a fontconfig option to just disable ligatures altogether, but afaik, one would have to enumerate ALL fonts that one would like to disable them for in the config file - and that's not feasible. So I mostly live with it, and shake my fist in helpless anger whenever somethings f_cks up my otherwise beautifully monospaced flow with this most damned misfeature of digital typesetting.
because it isn't "≠", it's "!=". that's what the compiler accepts in most/all languages I know.
show me a keyboard made today that can enter that character directly. that character can't be entered directly because the USB-HID spec doesn't specify a keycode for that character.
I understand that some people want their computer programming languages to look like APL but we tried that, and it failed. Fortunately or unfortunately.
I understand your point, I didn't make that clear.
!= and ≠ are merely visual representations of a concept, so I understand and agree that preference matters here.
the bytes in the file are the Unicode code points for "!" and "=", and that's what the compilers and parsers of the world care about, so that's what I want to see.
I don't want my text editor lying to me about the contents of the file. one could argue that showing ≠ does indeed tell you that "!=" is in the file. it will also appear if the Unicode code point "≠" is in the file. you may see the nice symbol you want to see, but the compiler or interpreter will not understand that and will show you an error which you may or may not immediately recognize as the wrong thing.
I want my text editor to show me what is actually present in the file.
Yup. I emailed myself the string "-misc-fixed-medium-r-semicondensed--13-120-75-75-c-60-iso8859-1" a couple decades ago just to make sure I didn't lose it. Not sure what I'll do when I finally get a HiDPI display. I think it's part of the reason I haven't made the jump yet.
Years ago I fell in love with Anonymous Pro. Everything seems to fit just right. I've never had an issue wondering which character is which nor have I run into missing common characters.
I switched to Iosevka for both iTerm and Emacs several years ago and have been pretty happy with the added horizontal density. My only real complaint is that Emacs behaves a bit weirdly when lines exceed the buffer width, but I haven't tried switching back to a "normal" typeface to confirm that it's Iosevka's fault.
I like ligatures, little quirks (relative to ordinary fonts) make output more interesting.
I wanted to get a portable monitor with a high hz rate for VR applications, and separately text test output. The best I could find, without spending too much on something that'll be better in the near future, is 16" 2560×1600. So not very high PPD. Anyone have any suggestions for a font that won't look grainy? I use it in portrait.
The last thing I want is for my text to look interesting. I want it to be boring and instantly recognizable. I want text editors showing it to work predictably. Two characters should show as two glyphs with the background showing through the middle. All glyphs should be the same width. Ligatures break these universal consistencies and stick out, screaming for attention. I want my text to be absolutely silent.
I find ligatures makes certain symbols instantly recognizable. Two characters, such as "=>" or "<-" look like math symbols, but then it takes one more step to realize no it's an arrow.
I recently started using a font that has ligatures - they don't break alignment of mono-spaced text, for example a two-character ligature takes up the space of two characters.
I am not thrown by != showing up as an equals sign with a slash through it, because I can remember that this is in fact "!=". It's easier to read than the "raw" version. All in all I'm sold.
I can remember that the inequality symbol means != but I'd prefer the lower cognitive load of not having to recall anything at all.
I like that Typing "!=" results in "!=" being printed to the screen. I like that pressing backspace only affects the single preceding character/glyph instead of converting the ligature back into its constituent parts.
It's a consistency thing. I'm never reading math textbooks written with latex and all the fancy ligatures and symbols. I spend my entire day reading and writing code, so consistency there is paramount.
Weird; I see the former symbol all day every day and have no trouble recalling. I see the second symbol almost never, maybe once a month, definitely not as easy to recall.
I’m still enamored with Monaco after all this time. It’s fun and legible. It has bitmap and vector variants. Whenever I search for a new monospaced font, I always think: but it isn’t Monaco!
Unfortunately, I've tried using a version of Monaco on Windows, and whatever version I downloaded just doesn't... quite... render just right. So I stick with Droid Sans Mono on that _other_ OS.
I dislike most mono fonts, but I found a monospace version of Atkinson Hyperlegible a while back and was using it until the author made a new monospace font they call Unolexic[1]; I've been using it since. They also have done posts comparing different parts of different fonts[2], making quasi-monospace fonts[3], etc., which are fascinating to read.
I’ve stuck with Victor Mono for a while now, since I like having comments in cursive. I know that’s not for everyone. I just seem to parse prose a little easier with joined up letters.
Looking at the screenshots, to me the fonts with the stronger and more defined lines seem slightly better than others:
- Go Mono
- JetBrains Mono
- MesloLGS NF
In comparison, there are some that are clearly harder to read:
- Iosevka Term
- Inconsolata Light
I actually commented on the fonts that I use (Liberation Mono for readability and PT Mono for stylistic preferences) a while ago, with my own example images, but I'll also agree with the statement that most modern fonts look a bit samey: https://news.ycombinator.com/item?id=34588312
However, I can't help but to wonder how exactly one would measure how light or heavy a font is, when compared against other fonts. Maybe some measurement of how much contrast there is to the edges of the strokes (e.g. the font doesn't appear blurry and is readable, given a certain quality of eyesight, at a particular size and distance), or just how much of the image is made up by dark tones, or how clear the strokes are?
Comparing the histograms seems borderline useless, for example, even between Go Mono and Inconsolata Light the differences are very slight: https://imgur.com/a/BWbzJzj
Iosevka comes with about a million different variations (and you can build custom variations by building the font from source). From the screenshot, it looks like the author was using the light weight; I almost always use medium. Similarly, if you don't like serifs, you can turn them off; I use the "hooky" variant which adds loopy tails to some letters.
I like old mono. I was reading Guy Steele's Common Lisp book and loved the font so much I looked it up. Turns out it's called Letter Gothic Standard, and it looks awesome in code: https://www.wfonts.com/font/letter-gothic-std
It looks good, and is surprisingly readable when shrunk down a bunch. It's a fantastic quick-setup font. I only don't use it as my main font anymore because I have a very personalized Iosevka build. But that takes time and motivation to do (and a mind-blowing amount of RAM).
I'm a big fan of this font, I use it every day and have never regretted the purchase. Unfortunately the OP noted they didn't like Iosevka, which I think is pretty visually similar.
Pragmata Pro is a huge influence on Iosevka, the author has admitted it. What makes Pragmata Pro work, afaict (since I've yet to actually buy the damned thing), is it is insanely well hinted... this is the one thing Iosevka will never have (it depends on ttfautohint, which although acceptable, will never be good as a talented font hinter producing his art).
Having tried, and evaluated, basically every mono font in existence worth using here, I may end up just buying Pragmata Pro.
My current daily driver is Input, and not set as a compressed or condensed style. Input is only hinted for the weights Light, Regular, Medium, and Bold, for normal width; the other three more narrow widths are not hinted at any weight. At the sizes I prefer text, Input requires the hinting supplied by the author.
I love PragmataPro. It's not just the look, but also the character support and many of its design features. I work with linguists in academia and get to work on a lot of plain text data - transcriptions and what not. PragmataPro's IPA support is something I make use of every, single day, not just for coding. If I had to pick a single font to use for anything and everything for the rest of my life, this would be it - including reading.
I finally bought it a month ago after years of "trial". It's an expense that student me would never had approved, but now I'm glad to give back because the font makes me so happy.
Why would he miss the best of all? DejaVu Sans Mono. This font is the only thing I come back to decade after decade. There's too much good to say about it.
I'm a big fan of Lilex and use it currently: https://github.com/mishamyrt/Lilex. I think it looks quite a bit like Inconsolata which I used to use a long time ago.
Anyone know of a similar comparison of screenshots using subpixel-AA instead of "monoscale"? (it's not really "grayscale" as the color used is not gray).
I know OS X dropped subpixel-AA but, to me, the only criticism about subpixel-AA is long gone: on monitors with low DPI it could make letters a bit blurry in some kind of a psychedelic way.
But now all monitors have higher DPI and I'm devv'ing on Linux only, which does support subpixel AA, and I turn subpixel-AA on where I can. If anything it makes rendering less blurry.
Answering my own question, user "cornellion" posted in this HN thread a link to a site which uses your system to actually render the fonts in order to compare them, as opposed to screenshots, so as my system uses subpixel-AA I can see what they're going to actually look like on my system:
I used Envy Code R for a long time and switched to Iosevka a few years back. Most mono fonts feel too spread out. (From the looks of the fonts, most folks probably feel the opposite of me...)
If you had asked me 1 year ago whether I would pay $75 for a coding font I would have laughed at you. And yet, here we are, my font of choice is Berkeley Mono any day, everyday.
> I got a huge number of suggestions, of which I downloaded 16, basically all the ones that are free. In general I prefer to pay for things and am suspicious of anything that’s free on the Net, but when there are so many good free options I just don’t think there’s a business model.
This sentiment is quite odd; given that who would ever pay for a font? I get being suspicious of "free" but if you use Google, or have a gmail account. Heck even Mastodon is a free software package.
I see this a lot with older development communities; even though I've been writing code for many years; while working on an old application I was met with a prompt to purchase a license to use a library. It took me aback because while I've heard about buying and selling libraries, I've never (ever) ran into it before working at my current job. It's odd, and thankfully a dying way of making money since every dev license is at minimum $500 for a year; to $5000 annually to use those libraries in production, not even just the time to develop with them.
You’re glad it’s a dying way to make money but I remember developing and selling software tools and libraries was fulfilling and a lot of fun. Definitely beats writing hundreds of yaml configuration for open source libraries and fishing for thumbs up in GitHub issues so they get more attention :)
I have switched to Operator Mono about 10 years ago. This font is not free though. However it was the only font (at the time I was looking at at least) that had a monospaced italic version which I found looked slick. So I ended up buying that font and used it ever since.
operator mono has always been my goto since i first went into a deep dive on this topic, and i LOVE it. in the interest of full disclosure, i... torrented it... many, many years ago, but now that i'm thinking about it i will go buy a copy-- i definitely owe them at this point. highly, highly recommend operator mono-- i just feel like if you are optimizing for pure aesthetics it wins out. the italic version is definitely a big part of that.
Seeing as everybody's using this space to plug their favourite font, and the one I use hasn't been mentioned yet: I'm partial to Generic Mono II (http://luc.devroye.org/fonts-75172.html & https://github.com/organicplanning/hackedfonts). It has slashed zeroes and, with a reduced character spacing, just looks nice and otherwise doesn't distract from what I'm doing. Though it's coverage outside of the Latin character set leaves a bit more to be desired.
I'm currently using Menlo in VS Code (on Mac) since SF Mono is too restrictive for my needs. I like Fira Code but the ligatures, while very nice, would be confusing for my students and probably best not used.
The font rendering engine affects the font appearance significantly. Fonts that look good on macOS don't necessarily look as good on Linux or Windows and visa versa. There are also fonts designed specifically for macOS, Linux or Windows. For example, the rendering of Iosevka Term on macOS looks quite bad, but on Linux it's rendered very well both in 96 dpi and hidpi. So there are no "best" fonts. You have to try them all and decide for yourself which one looks the best.
And now for the comparison on 96(-ish) PPI screens…! I find that many more recent fonts simply do not look good on those. Some are even outright terrible, glitching all over the place with subpixel rendering.
Part of the project are some interesting duospace and quad-space versions that I probably wouldn’t use for code, but are great for editing general text.
Shame he apparently only tries one of the very light weights of Iosevka. I love my Iosevka Slab. The “light” weight works great on retina displays imho.
It isn't important to the article but whenever someone writes an article about doing something new/different because "I got a new computer" the first comment is always "what computer did you get?"
I guess the author knows this and so pre-empted the question and decided to just answer it before anyone asks (although someone will no doubt still ask).
Not sure the obvious needs to be stated, but it feels totally up to the author to add any detail they like. And perhaps frequent readers are interested in the tools the author uses besides their programming font?
last year I made a custom build of Iosevka using the customizer on the website and building it on my machine, and I can't use any other font now. If you like the general look of Iosevka, but prefer certain glyph variants over others - highly recommended to look into creating a custom iosevka build for yourself
In my experience on every setup: different OS version, different screen, etc. the rendering of fonts gives slightly different results, to the point, I just choose whatever works best at a given moment, and don't get too attached to it.
Whenever I‘m trying a different font, it doesn’t last for long. Not only does Iosevka support all kind of variations (as in: there’s a style for everyone), it‘s also very narrow. I always find it odd when looking at different fonts taking up 1.5 times the horizontal space, especially in terminals.
If you are willing to entertain non free options: MonoLisa is a pretty good font and you can customize which ligatures you are willing to entertain. (I’m basically at zero)
"Information density" normally means "how much information can fit in a piece of the screen", which is going to be the same for all monospace fonts (at the same font size, anyway)
I don't know why this gets me so hot but you really don't need to be using a monospaced font for code anymore. Monospaced fonts are an abomination created because it made programming early terminals easier, we've long since outgrown our use for them and yet they are entrenched in programming culture because we still use terminal emulators based on those same standards to this day. Give your eyes a rest and look at your code in a variable width font. I've been using Avenir for years and it is so nice.
The key to using a proportional font is to give up alignment completely, and only use indentation.
Once you do that, it no longer matters whether you use a proportional or monospaced font.
The Black formatter for Python is an interesting example. It strictly uses indentation only and never uses alignment.
As a result, Black-formatted code is equally readable in any font, monospaced or proportional. I use my own customized proportional font called Trebuchet++, and Black code looks great in it.
If you didn't know I was using a proportional font, you might not even notice that it wasn't monospaced.
As you may guess, Trebuchet++ started out as Trebuchet MS, which I found I really enjoy reading on a high-DPI display. Then I started tweaking things in FontForge:
Trebuchet MS has a terrible tilde character that looks too much like a minus sign. So I put in a better defined glyph for that.
One problem in a proportional font if you use names_with_underscores as required by too many coding standards: the underscore character is much too wide compared to a period. This gives a visual grouping that is the opposite of what you want, for example in foo_bar.moo_car(), "bar" and "moo" are closer together than "foo" and "bar" or "moo" and "car". This is misleading visually.
So I used FontForge to add a bit of space on each side of the dot, and add negative space on each side of the underscore. In the example above, this pulls the "foo" and "bar" in "foo_bar" closer to each other, and similary for "moo_car". At the same time, it adds some separation between "bar" and "moo".
The difference is subtle, but in terms of visual grouping it avoids having the code read like this:
foo bar moo car
So it reads more like this:
foo bar moo car
I have a couple of other tweaks I haven't gotten to yet. In particular I want to add a bit of margin on the inside of parentheses and square brackets. In my own code where I get to choose the style, I've always uses a space inside those. I find this offers a real improvement in readability. But if I can't do that, at least I can fix it with some font tweaks!
I've found I don't miss the ability to carefully align stuff outside of the initial indentation. I actually use a slightly modified Avenir that prints a wider space if it's the first thing in a line, making the indentation stand out more. The rhythm of a general line of code I think is improved because it reads like regular text.
That's where the nonexistent support for variable-width tabulation (or flexible tabstops) comes in!
Unfortunately even the newer programming editors don't match these type of Word-level basics
Are there any variable width fonts with ligatures? While a bit of a debate on their usefulness, I quite enjoy fonts with them. In addition, how well does block-editing work with variable width fonts? I don't do it too often, but it does massively speed up my workflow when I have to.
It's such a great font. I've been through them all, and even hacked together my own custom version of Office Code Pro, and while I switch every now and then, the iA Writer fonts are my favourites. I pair them with the Quatro version for code comments.
Wow screenshots of text rendered on a notoriously bad text renderer, then downscaled and posted in a blog. A text-based description of the fonts might be worse, but only barely.
Yeah, man, so much effort and every screenshot looks identical in context in the blog post.
All words in use today were made up at some point and then accepted through popular use. Merriam-Webster accepted this one into their dictionary some years ago.[1]
And Dictionary.com acknowledges it may have been published previously in 1884 by C.A. Ward as an example of a barbarous verb.[2][3]
That may be why it -- and Envy Code R -- are the only "modern" monospace fonts I can stand for very long. Everything else just looks like IBM Letter Gothic, or some other typewriter vendor's substitute for Letter Gothic. Hence why I use bitmap or bitmap-like fonts for terminals.
I ended up seeing a post here for Berkeley Mono, a paid font, and I noticed in particular that it was incredibly readable compared to other mono fonts I was using, so much so that I've zoomed out one level on VS Code and iTerm and have similar readability as before.
It was the first font I paid for, and I was quite happy with it.
https://berkeleygraphics.com/typefaces/berkeley-mono/