Which colour scheme is better?
stitcher.io
stitcher.io
I used to use molokai (dark, fairly high contrast); a few years ago I decided to build a new minimal, light, high contrast one from scratch, which I called “bland”, inspired by the printed code of yesteryear. Paired with Triplicate, the only true serif monospace font that I can think of (I have a vague feeling I found one other once, but can’t think what it was). Black text, white background, keywords bold, comments italic, that was it. I tried that for a few days and decided I liked it, but did want strings and comments distinguished, so I made strings red, comments green, numbers blue. Over time then I’ve added a small number of other cases for specific languages and constructs, but it’s stayed very minimal compared with what almost everyone’s doing.
Well, I deliberately tried it for a couple of weeks, then went back to molokai for a week before I broke and went back to bland because I found it just so much better.
It’s what I use in code blocks on my website, though with light grey backgrounds rather than white. See https://chrismorgan.info/blog/rust-fizzbuzz/ for an example.
It was a couple of years before I even bothered to make a dark variant of the theme, for the occasional low-light situation where dark actually works better, and because I wanted to have a dark mode on my website. I almost never use bland-dark.
Tempus is a collection of themes for Vim, text editors, and terminal emulators that are compliant at the very least with the WCAG AA accessibility standard for colour contrast (which stands for a minimum contrast ratio of 4.50:1—while some items have a 7.00:1 rating, or else WCAG AAA).
I use one of the AAA schemes. It's not perfect though, certain color pairs are low contrast (typically the "dark" and "light" variant of the same color).
There is a litany of posts and opinions of people who say their eyes hurt with a light color scheme, or it produces spots in their vision, or it hurts their concentration etc. I have no reason not to believe them. Many people prefer to even show their code in a dark scheme on websites. Furthermore, many people don't care but think dark is cooler.
On the other hand, I know that for myself, coding in a dark scheme is rather painful, especially if the background is very dark (as opposed to some gray). It makes it very hard to concentrate and I experience this on all of my displays. I do not have scientific evidence for any of that, nor do I really care to produce it. However, I look at code every day, so I know what works for me. The same will be true for other people here.
I think developers should treat it as an accessibility issue. Apps should have a dark mode, since many people clearly need it. Apps should also have a light mode, since people like me need it.
It's not that these people are lying, but it is common that people's subjective experience is biased by their expectation.
If I expect that dark themes are easier on the eye, I'm likely to experience any eye strain that might be caused by a bright theme in an exaggerated fashion.
Similarly, if I were to buy into this "the Pulfrich effect will slow you down" hypothesis, I might subjectively experience a benefit from switching to a light theme.
I don't buy into the hypothesis, so I'm sticking with a dark theme (as well as f.lux cranked up to eleven).
However, I do notice that "because science says so" is becoming a more and more common "you are not allowed to argue with my conclusions" kind of add-on to any assertion. It is an oddly religious, faith-like use of the word "science".
Conclusions are based on science? So, in a sense, they are the best result available based on evidence, best accepted theories, reasoning? Isn't it logical to say then that one approach is better that another because it's "based on science"?
What is faith-like here? Faith in scientific method, instead of having scientific method based on best results?
True. I don't care with what science says, I actually tried to use a light theme and I just couldn't do anything.
I'll basically repeat my comment from below, but ergonomically set up displays meet ambient brightness, but don't exceed it (much). If you're sitting in front of a display set to 80 % brightness (~300+ cd/m²) in the evening, you're simply holding it wrong and compensate by limiting the content to dark tones only, which is a crutch at best.
That's not to say people shouldn't use dark themes. But if the reason for choosing a dark theme whenever possible is mostly "white is so bright it literally hurts my eyes", then the environment is decidedly wrong and needs fixing.
Example: https://www.prad.de/wp-content/uploads/2020/07/lg-34gn850-ko...
Get the URL from here, maybe: https://en.wikipedia.org/wiki/Display_Data_Channel#External_...
This is true in a world where many UI backgrounds are close to "white", i.e. maximum brightness. That in itself is an unfortunate situation (though driven in part by the technical limitations of display technology until now) because there are plenty of cases where you actually do want the ability to display above ambient brightness, just not for what is meant to be a neutral background. HDR displays are designed for high peak brightness and shine with photorealistic content - pun intended.
Content such as games, video, photos all have in common that their colour/brightness histograms are much less skewed towards the extremes than typical UIs which are dominated by large uniform, mostly bright areas. Those should be limited to ambient brightness, and ideally on a true brightness plane, not clipped to the faces of an RGB cube.
My work office, back when I had to go into the office, used overhead LED ‘energy efficient’ lights that were far too bright and had a colour temperature that was too white. They then painted the office walls white, I thought I was entering limbo every morning.
I think the key takeaway is that it all comes down to personal taste, and there is no universal colour scheme or brightness level that everyone is comfortable with.
I'm astonished (dismayed?) by how many people give presentations or record otherwise very useful videos with dark mode content. That content is unviewable when the ambient light of the viewer's surroundings is high (such as daylight, or especially when outside). A great presentation is diminished in worth if it can only be consumed in less than all circumstances.
As an aside, it is important to control the ambient light if possible, especially where "daylight" (high K) LED lights are concerned. Not only does the high volume of blue rays take a toll on your eyes, but it also impacts melatonin production. And of course it means you likewise have to have your display brighter.
> Of course, I adjust my overall monitor brightness according to the ambient light (so do not use full brightness in the evening).
I suspect this may actually play a significant role here, since "light themes are way too bright / blinding / etc." is a common reason for the preference for dark schemes, and hints at incorrect monitor brightness settings.
As a rule of thumb, indoors in an office space around 100-150 cd/m² are the right ballpark. This corresponds to a brightness setting of around 20-30 % on most screens. In the evening with a little bit of bias light 0-5 % are usually the right area, though too bright on some models.
Why is it assumed that this delay is a bad thing or necessarily increases cognitive load? It seems to me like it could just as easily be a positive.
Reading faster doesn't indicate higher reading comprehension. There's a substantial amount of cognitive load in reading "flat" text and constructing the whatever structured representation exists in one's mind. Slightly delayed reading speed could help rather than hinder comprehension and higher-level semantic processing.
On another note, there are the often cited user studies that show that interfaces that are purely more aesthetically pleasing tend to be used more efficiently vs the exact same interfaces with “uglier” presentation. So a color scheme that is most aesthetically pleasing to each user might provide a subconscious boost in wielding their editor and its features.
As a third and less related thought, I think we could make much bigger strides in understanding code by creating better tools, better static analysis, better IDEs, etcetera. This is just my opinion but I would guess that additional tooling to help you discover and analyze the behavior, relationships, and history of the code you’re reading could yield better results than the 15ms character recognition optimization. I would also guess that for most, far more time could be saved speeding up builds and tests. That’s not to say that it’s not worthwhile to optimize character recognition speed. But I would guess that character recognition speed is not the main processing time in the mental “stack” when reading code.
For myself, I prefer an "off-white" theme, with a light parchment background. The old Xcode "Sunset" theme used to be my go-to. They have removed that, now, so I modified the Classic (Light) theme to have a parchment background, and that does me fine.
I find it kind of amusing how much some folks use choices of editor/theme as a "value judgment" on our skillset.
People do what's comfortable, and what helps them to work more efficiently. In some cases, it's all CLI, in a spartan black and white screen, for others, it's Romper Room GUI. Whatever helps us to work more effectively. Even if it's a "placebo effect," if it helps me to be more productive, it helps me to be more productive.
There's a number of singers that perform barefoot, and are highly skilled (Google "Rhiannon Giddens" I saw a video where she sang at the White House, and wore a really long dress). Basquiat would often paint in Armani suits (and barefoot).
Every now and then, I'll try something new. I'll usually give it several days, before making a decision. Sometimes, I adopt it.
It took me months to become effective at a standing desk. It was an issue of health, for me, so I powered through all the awkwardness.
Is the fact that some people like dark colour schemes really that threatening?
Computer science is not a field in which learners can reason about best practises for themselves. There is so much to learn that most of the habits we adopt are just articles of faith.
For example, it took me 15 years to ask myself if I was really happy using camelCase. When I thought about the issue for myself, it was glaringly clear that snake_case is easier to read and reason about.
If light color schemes are truly easier to read, it benefits the industry to have people advocating for it.
So, I tried light themes predominantly from about 1995-2015, after using dark themes predominantly from 1985-1995, and before using dark themes predominantly from 2015-present.
But, sure, a week will make a difference.
The commercial web popularized white background. Companies like eBay, for example. Although my favourite website back in those days (Webwereld) had some kind of pastel light yellow, IIRC. Marktplaats (popular alternative to eBay, old) also still has this. I suppose the colour is mostly akin to old newspapers, and backlight.
HN also has this colour, by default. Goes very well with the orange (tho I'm biased as that is my fav colour). Though I use a CSS sheet to turn HN into Solarized Dark (which according to the article is voluntarily hurting myself). I'm actually fine with the HN theme, during day. I'd be OK with Solarized Light during day, and Solarized Dark during night. Same with Android and macOS. What worries me is that it ain't going to work fluently for all the programs and settings.
Mentions the Pulfrich effect, but this is for lateral movements with stationary vision. Author then leaps into a discussion about how this happens every time you "rescan" without giving a single line of evidence that this happens.
This is especially dubious given Saccadic Masking[0] meaning there's no perceived visual input while the eyes are in motion. How exactly are we being slowed by the Pulfrich Effect during reading if motion ("lateral motion" required to satisfy the conditions of the effect) is blocked by the brain?
The argument about light themes being "blinding at night" I don't buy. If the screen is blinding you, then you should get better lighting in your room, it's not good to work in the dark.
Also, dark themes give me depression. When I open the IDE and it's a dark grayish rectangle I am like "oh no, I have to work with that again".
well I might be working in the dark because I am sitting in the same room as my sleeping son because he might have problems if nobody is there. I assume other people might have similar reasons why they would be in the dark instead of a well lit room at night, given that most people have electricity and know how to switch on the lights.
There's also plenty of shades between white and black, and maybe there's some kind of sweet spot.
Another issue is that syntax highlighting is easier to notice on dark themes, and differentiating between type annotations and variables and functions and operators probably takes much more brain power than the visual recognition of the text.
Grab a pair of 3D glasses and point the side with the linear polarizer towards your LCD screen (it is the one that will not let the screen show through if rotated correctly). You can now adjust the brightness of this image by changing the relative angle between glasses and screen to change the intensity of the 3D effect.
Here is the explanation. 3D projectors normally use circularly polarized light because this method is insensitive to head movements and tilts which would lead to unpleasant effects if they were using linearly polarized light instead.
The different images for both eyes are projected with clockwise and counter-clockwise circularly polarized light. The glasses first convert the circularly polarized light coming from the cinema screen (these are special screens that don't mangle the polarization) to linearly polarized light which is then going through a linear polarizer, eliminating the unwanted polarization. The filter for the other eye eliminates the other polarization which allows to target the left and right eye individually.
Because the glasses are built like this, the linear polarizer has to be towards the eye and therefore we need to turn it around for us to work here. It doesn't matter for the eye that the remaining light goes through the quarterwave plate by the way.
(I'm not sure why this technique works with different colors at once btw!).
If you want to read more about this: https://en.wikipedia.org/wiki/Polarizer#Absorbing_and_passin...
One of the reasons is that the minimum brightness of my screens are just too bright compared to ambient light at night, and I love my ambient light at night, that is quite bright but illuminates all the room, so I can work on the room, and use things like blackboards or notepads, not just the computer screen.
It hurts my eyes to have white rectangles at the middle of the night so higher than the environment.
Those screens are supposedly high quality and they can be way too bright in order to compete with the sun, but not dim enough for low light places.
Dark themes let you have letters with higher visual contrast as all colors contrast with dark way more than against white.
It is a complex issue with multiple variables, not just one.
BTW I don't see science anywhere in the article. Science needs you testing your hypothesis with actual experiments and collecting data.
If you're on a Mac, there are several freeware utilities to do exactly that, Shady was at one point the most popular. I assume there are similar utilities for Windows and Linux.
They work by lowering the RGB intensities of all the pixels on your screen, instead of lowering the backlight further. It has exactly the same effect in the end.
Yes... at minimum brightness #000 isn't pure black, it's a very, very, very dark gray.
But nevertheless -- there's still plenty of contrast. So while it's technically true you get slightly lower contrast... I don't see how, in practice, this would be a problem for anyone who's simply doing reading/writing/coding.
(Remember, many coding themes are intentionally lower-contrast anyways -- black text on white is really dark gray, bright text on dark background is a dark gray background. So it's doubly not a problem.)
There must be a reason why the print developed as black-on-white, maybe people preferred it this way.
So pick what you prefer: paper-style or CRT-style.
I used dark schemes for years but having switched to a light one in recent months, I don't see myself switching back. This area is mired in dogma unfortunately.
However I find it easier to distinguish individual characters with a dark theme. So when trying to parse something like a line of jsx, it's better.
Overall I prefer (and use) a light theme, but I will admit that dark themes look 1000x cooler.
Dark background during the night, and light background during the day, in most cases.
As simple as that.
I wish my text editor would switch automatically and I might write a script to do that at some point, but this is a minor annoyance.
In the settings turn on `window.autoDetectColorScheme: true` then select a theme for each: `workbench.preferredLightColorTheme` & `workbench.preferredDarkColorTheme`
It would be great, since my personal preference is also light theme during the day, dark at night.
[1] https://bugs.chromium.org/p/chromium/issues/detail?id=998903
[2] https://extensions.gnome.org/extension/2236/night-theme-swit...
A few milliseconds? What are you talking about?
No, your eyes are not different than theirs or mine. We share a common psysiology and optical mechanisms. Eyes work (in the absense of some mutation or disease, which covers most of us) the same way, with the same wiring, etc.
Your preference (e.g. like vs dark backgrounds) might be different, but that's not the same as your eyes being different.
And you could very well slow down/hurt or dellude yourself that your preference is better.
This is akin to someone saying a salad plus chicken is healthier than a McBurger and another replying that they like McBurgers, that what's important is what they can "comfortambly" eat, and that your mouth is "different" than theirs.
The preference part simply doesn't matter as to whether something is better on the eyes or not.
And while the "Pulfrich effect" might not be a good or enough justification, it's much less absurd than the above, which implies that there can't ever be a justification because whats easier/faster to process/etc on the eye is just "taste".
Did you read the whole post? There's
- The Pulfrich effect
- The way human eyes are built
- The case of astigmatism
- Studies targeted towards computer screen use
The only time I managed to use a light theme for an extended period of time was a couple of years in a room with weird lighting and reflective screen of an imac. That's when I was using Solarised Light, because my Zenburn just couldn't provide enough contrast.
Then I moved to a different room and it was back to Zenburn.
What did it say?