Become a fan of Slashdot on Facebook

 



Forgot your password?
typodupeerror
×
Programming IT Technology

Best Color Scheme For Coding, Easiest On the Eyes? 763

Marzubus writes "I tend to do a lot of code editing in vim and sometimes get the 'burning eyes' or headaches. I have been trying to find a background / foreground combination for my terminal sessions which is easiest on the eyes but cannot seem to find any real data on this subject. Does anyone know of a study / data on this topic?"
This discussion has been archived. No new comments can be posted.

Best Color Scheme For Coding, Easiest On the Eyes?

Comments Filter:
  • Probably not colors (Score:5, Informative)

    by clang_jangle ( 975789 ) * on Thursday July 03, 2008 @09:19AM (#24042323) Journal
    I doubt that the colors will make half as much difference as the quality of your monitor, unless you've been using chartreuse on magenta or something. Not that I know a great deal about the technical details, but I have observed that many cheaper CRTs or LCDs seem to make my eyes hurt sooner than a more expensive one. Apple's monitors are excellent for this, BTW, but they do price them terribly high. These days I'd expect you can get something equivalent for less, though it won't be a $129 model. Also, in 2004 the same question was discussed at length here [slashdot.org], probably at least some of that is still relevant.
  • Color Scheme Sampler (Score:5, Informative)

    by slifox ( 605302 ) * on Thursday July 03, 2008 @09:20AM (#24042337)

    I've looked into this topic a few times in the past...

    Last time, I found a page that shows samples of hundreds of VIM color schemes:

    http://www.cs.cmu.edu/~maverick/VimColorSchemeTest/index-pl.html [cmu.edu]

    I don't use VIM (I use JOE), but the color schemes are easy to convert manually

    Whats nice is that you can scan through a _lot_ of schemes very quickly, and easily pick out the ones that work very well.

  • Zenburn (Score:5, Informative)

    by Anonymous Coward on Thursday July 03, 2008 @09:21AM (#24042367)

    Zenburn is a low-contrast colour scheme for low-light conditions. It is popular color scheme among programmers because it is very easy on the eyes.

    Legend says it was used by the ancients when they developed teh internets and our realm.

    * http://www.codinghorror.com/blog/archives/000682.html [codinghorror.com]
    * http://slinky.imukuppi.org/zenburn/ [imukuppi.org]
    * http://www.vim.org/scripts/script.php?script_id=415 [vim.org]
    * http://slinky.imukuppi.org/2006/10/31/just-some-alien-fruit-salad-to-keep-you-i [imukuppi.org] n-the-zone/
    * http://termos.vemod.net/zenburn-for-konsole [vemod.net]

  • Here is an answer... (Score:3, Informative)

    by Anonymous Coward on Thursday July 03, 2008 @09:21AM (#24042369)

    It is I, 1100101, and this was asked three months ago with a good discussion. I guess slashdot operates in quarterly cycles. :)

    Here is the previous discussion: http://science.slashdot.org/article.pl?sid=08/04/08/2213222 [slashdot.org]

    As to not karma-whore, here was my response as a doc...
    http://slashdot.org/comments.pl?sid=515908&cid=23008272 [slashdot.org]

  • by nikomen ( 774068 ) on Thursday July 03, 2008 @09:25AM (#24042439)
    I concur. A while ago I purchased a couple cheap LCDs. I noticed that the LCDs at my university were easier on my eyes than my home LCDs. I sold my LCDs to my parents who I knew wouldn't be on the computer for any long lengths of time. I bought a couple HP LCDs that were recommended to me and they make a world of difference. This isn't an ad for HP, just simply stating that cheaper LCDs probably cause some kind of eye strain compared to a little more pricey (yet not horribly expensive) LCDs.
  • by Ihlosi ( 895663 ) on Thursday July 03, 2008 @09:30AM (#24042553)

    This combination is the most relaxing for the eye. Also, illuminate the area around and behind the monitor.

    Why ? Depth-of-focus. Brightness will make the pupils contract, which increases the depth of focus and decreases the amount of regulating that the eye needs to do.

    Maybe you need to have your vision checked, too. Having a quarter of a diopter too much or too little is hardly noticable, but wil give you headaches in the long run.

  • by Bandman ( 86149 ) <bandman.gmail@com> on Thursday July 03, 2008 @09:30AM (#24042555) Homepage

    With CRTs, refresh rate was a big deal, so that might have been part of it.

    If your monitor's refresh rate was equal to the ambiant lighting's refresh rate, you could almost guarantee a headache

  • If your using Ubuntu (Score:1, Informative)

    by Anonymous Coward on Thursday July 03, 2008 @09:30AM (#24042565)
    Try the high contrast theme with your screen brightness adjusted to a comfortable level. Works for me!
  • Bias lighting? (Score:5, Informative)

    by Guanine ( 883175 ) on Thursday July 03, 2008 @09:33AM (#24042621)

    The few scientific studies [sfasu.edu] I've found on readability indicate that there is no color scheme that significantly enhances readability -- I would think readability would only be part of the issue regarding the eye strain problem.

    So, what about making your own bias light for your monitor [lifehacker.com]? That will _definitely_ reduce eye strain.

  • Zenburn (Score:5, Informative)

    by DarkDust ( 239124 ) * <marc@darkdust.net> on Thursday July 03, 2008 @09:33AM (#24042623) Homepage

    I love Zenburn [vim.org]. I use it on all my machines now and at work.

    But there is one thing you should do in your .vimrc prior to setting :colorscheme zenburn, and that is forcing the use of 256 colors:

    :set t_Co=256

    Also I found that the search highlighting wasn't visible enough for my taste, so I tuned it. After :colorscheme zenburn I have:

    :hi search ctermbg=223 ctermfg=238
    :hi incsearch ctermbg=216 ctermfg=242

    And if you like to have a little more contrast, then insert the following before your :colorscheme zenburn:

    :let g:zenburn_high_Contrast = 1

    which together makes for this:

    :set t_Co=256
    :let g:zenburn_high_Contrast = 1
    :colorscheme zenburn
    :hi search ctermbg=223 ctermfg=238
    :hi incsearch ctermbg=216 ctermfg=242

  • by hansamurai ( 907719 ) <hansamurai@gmail.com> on Thursday July 03, 2008 @09:38AM (#24042703) Homepage Journal

    Great point, I have two LCDs at home, one is a six year old Envision monitor and then other is a three year old Samsung. The Samsung monitor looks worlds better and is much easier to look at for extended periods of time. It's one of those things I can't lay my finger on but it's definitely there.

  • by SQLGuru ( 980662 ) on Thursday July 03, 2008 @09:39AM (#24042727) Homepage Journal

    Also, environmental factors. For example, I've been in various cubes over the years and the ones where there was a light fixture visible from my chair as I looked at my monitor caused fatigue faster than when the fixture was not visible (this includes when the fixture was behind me....basically visible in any direction from a sitting position at my desk). Also, for a while, they allowed us to dim the fixtures (turn off/remove one bulb) which helped too (not completely dark, but more cavelike).

    Other things you can do is to make sure the brightness and contrast are appropriate. Most people keep them too high (myself included).

    And of course, frequent "look away" breaks. I had an old NEC 21" CRT (heavy beast) that actually had a built in timer that you could set that would remind / force you to look away (the screen would go black except for the message). Easy enough to implement in software if you are so inclined.

    There's some good articles here: http://www.sangrea.net/ohs_dbase/colour-color.htm [sangrea.net]
    They are mostly focused on designing web pages, but the information is just as relevant for any computer image that someone will be starting at for any length of time.

    And of course, a different Slashdot question on the same subject: http://ask.slashdot.org/article.pl?sid=01/09/14/1516207&mode=thread&tid=99 [slashdot.org]

    Layne

  • by Hognoxious ( 631665 ) on Thursday July 03, 2008 @09:44AM (#24042845) Homepage Journal

    you can scan through a _lot_ of schemes very quickly, and easily pick out the ones that look pretty

    Fixed that for you.

    For future reference, aesthetics (particularly in the short term) != usability.

  • by maexio ( 259664 ) on Thursday July 03, 2008 @09:58AM (#24043099)

    I think it was determined that Green On Black was the ideal method back in the day (When color monitors / technology was too $$$ / unavailable)

    Or it could have something to do with our eye's ability to see various wavelengths of color. For instance, the same 'intensity' green laser is 8x more visible than a red laser. This wiki link:

    http://en.wikipedia.org/wiki/Visible_light [wikipedia.org]

    shows the range of colours in wavelength form, while this one :

    http://en.wikipedia.org/wiki/Color_vision [wikipedia.org]

    shows the nm of light that each type of receptor can see. If you see, the Green wavelength appears to be near the middle, so although ianad (I Am Not A Doctor), the green theory seems to hold up.

    Also, i heard / read it somewhere a long time ago (ie, why all the crummy dumb terms seem to be green on black)

  • by pgallenga ( 624995 ) on Thursday July 03, 2008 @09:59AM (#24043117)
    Talking about "look aways" (forced/suggested by hardware/software), I've lately been enlightened by an article on FSM ( http://www.freesoftwaremagazine.com/columns/workrave_combating_rsi_free_software_way [freesoftwaremagazine.com] ) about WorkRave ( http://www.workrave.org/ [workrave.org] ), a tiny OSS utility that was created thinking of RSI, but can be configured for almost any need...

    I've installed it here in the company I work for, and now they all like it very much...

    Give it a try!
    P.
  • by Ihlosi ( 895663 ) on Thursday July 03, 2008 @09:59AM (#24043119)
    I never got a good explanation of why black on white is good (think original Apple Mac), vs. white on black is bad (original IBM CGA).

    You'll get it now: Depth of focus. Bright-on-dark results in a darker screen overall than dark-on-bright. This means that your pupils will open wider (to let more light in), which results in a smaller depth of focus (optics 101, ask anyone whose hobby is photography). And this, in turn, means that your eye has to re-focus more often.

  • by spec8472 ( 241410 ) on Thursday July 03, 2008 @10:02AM (#24043173) Homepage

    It's quite possible that the old LCD display is a 6 bit (256k colours) panel, which to display colours which didn't fit exactly onto that colour space, flickers between two on either 'side'. It's called 'temporal dithering'.

    http://en.wikipedia.org/wiki/Dither#Applications

    Theoretically you shouldn't be able to notice this, but it's the same with low refresh rates on CRTs - some people can notice it directly, others indirectly through eyestrain.

  • by Jasin Natael ( 14968 ) on Thursday July 03, 2008 @10:08AM (#24043285)

    The monitor does make a huge difference, and don't let anyone tell you otherwise. I've got a 24" iMac (early 2007, matte LCD) as my primary workstation, and the screen is beautiful. However, it is insanely bright. Even at the lowest brightness setting, it's still too bright for working with the blinds closed. I use a free program called Shades to cut the brightness in software.

    But the things you can do to get better coding performance are:

    • Calibrate your monitor as well as possible. This ensures that your whites and colors have (if not equal,) correlatable levels of percieved brightness.
    • Reduce the brightness. Put a sheet of super-bright white paper on a desk or table, so the room's light sources are all able to shine on it. White on your monitor shouldn't seem brighter than this.
    • Explore a Zenburn-like theme for your text editor. The theme I use is in a screenshot here [phammable.org]
  • by Skater ( 41976 ) on Thursday July 03, 2008 @10:16AM (#24043457) Homepage Journal

    I'll third this. I have a decent Dell monitor at work, and I had an old 17" Viewsonic CRT at home that was annoying because it was slightly unfocused in the middle of the screen. Having a decent display at work only made it worse because I knew how good the picture could be.

    I was happy with the Dell at work, so based on that and the recommendations of a couple friends, I bought a Dell Ultrasharp 22" widescreen earlier this year, and I've been much happier with my home PC since.

    My only gripe is that both Dell LCDs I use have one dead pixel each.

  • by guidryp ( 702488 ) on Thursday July 03, 2008 @10:22AM (#24043567)

    Matching brightness to ambient lighting is much more important than color scheme (unless you are going nuts with red on blue or something). I have been working as a coder for 12+ years now with a lot of 14 hour+ days...

    I never had much problem with CRTs. I prefer white backgrounds (standard VIM with syntax highlighting) with the brightness toned down to near paper levels for easy viewing.

    Most of the bigger LCDs I have tried lack the range of brightness control as they fight for supremacy in the specification wars. I have purchased LCDs of all three types (VA/TN/IPS) and in sizes ranging from 17" to 30".

    Eye comfort has correlated most strongly with how low you can modulate the brightness. On most big panels this modulation is quite poor when they aim for 400-500 cd/m2 which is insanely bright and hurt my eyes instantly regardless of color scheme (bright on dark or dark on bright both hurt). Even when these beasts are at ZERO brightness they are still often over 200cd/m2 which is completely nuts in a normal home lighting. You next have to resort to using the blocking characteristic of the LCD panel to lower it further which results in contrast going down the drain. Or set up more lighting which seems like a waste in terms of energy if nothing else.

    After all my purchases I have ended up with lower brightness cheap TN panels. These modulate to the dim end very nicely and tend to have fairly clear screen anti-glare coatings for nice clean text with a paper in light level brightness achievable.

    I recommend something like the Benq G2400W with it's nice 250cd/m2 max brightness (and therefore very good lower light performance).

    YMMV.

  • by penguin_dance ( 536599 ) on Thursday July 03, 2008 @10:25AM (#24043613)

    If you wear corrective lenses, make sure you get your eyes checked regularly for any changes. Also, I found it worth the price to get a pair of glasses suited for the distance I sit from the computer.

    You should also be taking breaks at least once an hour. And keep in mind that people blink less than normal when on the computer so make sure you are blinking. I find that a good quality, moisturizing eye drop can help.

    Also check the brightness and contrast settings on your monitor. You may need to dim things down if you work in an area that already has bright lighting.

    The Mayo clinic also has a good list of tips [mayoclinic.com].

  • by GrahamCox ( 741991 ) on Thursday July 03, 2008 @10:27AM (#24043681) Homepage
    their idea of text smoothing is to apply Gaussian blur to it and smudge it a bit. They do not use advanced manipulation like clear type does

    LOL!! Incorrect. The Mac uses subpixel anti-aliasing just as ClearType does, but it uses a slightly different hinting algorithm. Of the two, the Apple way is probably better subjectively for most people. More info here: Font smoothing, anti-aliasing, and sub-pixel rendering [joelonsoftware.com] and here: Texts Rasterization Exposures [antigrain.com]
  • by mdfst13 ( 664665 ) on Thursday July 03, 2008 @10:47AM (#24044063)

    I don't know too many people who move back and forth much when sitting at a computer coding...unless, like mentioned above, you're coding in a rave.

    Yes, but you look at different parts of the screen, which are different distances from your eyes. Incidentally, wikipedia suggests that the term should be "depth of field" [wikipedia.org] rather than "depth of focus" [wikipedia.org]. Depth of field refers to the amount of the image that is in focus without refocusing; depth of focus would be the distance between lens and retina.

  • Three rules (Score:5, Informative)

    by barracg8 ( 61682 ) on Thursday July 03, 2008 @10:54AM (#24044171)

    This comes up on /. every so often, and I'm summarizing here the advice from a few people who (to me at least) sounded knowledgeable about the topic last time it came up.

    1. Use a strongly contrasting color scheme - this is obvious, black on white is easier to read than orange on red.
    2. Match the background color to the environment - staring at a bright monitor in a dark room is like staring straight at a light bulb - and the reverse can be true too (you get a halo around the monitor burning into your retina). Green on black is probably a brilliant color scheme if you do all your coding in a basement only lit by the blinkenlights of a router, but in a well lit office may not be as good for your eyes.
    3. Limit color edges. Okay, this is where I'm going to paraphrase other people really badly, but here goes. Your eye has separate RGB color cones, and effectively has to match a set of separate red, green, and blue images together. For some people, you can start to see optical effects when there is a strong contract change in different channels - your eye doesn't line up the images correctly, causing a blurry shadow around objects. This is not necessarily visually all the pronounced, but causes eye strain.

    Based on this advice I've switched to blue on light beige (#0000C0 on #FFFFC0). It has a strong contrast in two channels, no change in the third, and suits my office (reasonably bright, but lit with non-natural light). So far, this is working well for me.

  • ClearType FTW (Score:3, Informative)

    by pragma_x ( 644215 ) on Thursday July 03, 2008 @10:58AM (#24044237) Journal

    I can't stress the "ClearType" sub-pixel rendering enough. At work i switched from a CRT to an LCD and got eyestrain almost immediately afterwords. Enabling that feature caused the problem to go away just as fast.

  • Re:Zenburn (Score:1, Informative)

    by Anonymous Coward on Thursday July 03, 2008 @11:07AM (#24044405)

    hmmm.. anonymous plagiary. Give a link next time buddy.

    http://brainstorm.ubuntu.com/idea/10468/ [ubuntu.com]

  • by johneee ( 626549 ) on Thursday July 03, 2008 @11:28AM (#24044821)

    Not appreciably, and not enough to make a difference when you're using a computer. Turn off an incandescent bulb and it dims slowly enough that you can see it going down as the filament cools. As the grandparent notes, it's not fast enough going down that it's going to flicker noticably when the AC goes from one side to the other and never actually goes completely black, only slightly dimmer in the middle.

    Fluorescents go dim when the phosphors stop being excited and it takes much less time for them to dim when full current is no longer going to them so there's noticable flicker sometimes when looking at them out of the corner of the eye or when interfering with the refresh on a monitor. But again, I don't think they go dark, just much dimmer.

    LEDs I think, because they dim so quickly when full power isn't applied to them, do end up flickering the worst when under AC power; for some people it's enough that they can notice it when looking at them directly, and pretty much everyone when seen out of peripheral vision.

  • by In hydraulis ( 1318473 ) on Thursday July 03, 2008 @11:45AM (#24045227)
    I'm going to go out on a limb here and suggest that being a diode, an LED hooked to AC is passing current during only half of the wave cycle.

    Provided the magnitude of the applied voltage doesn't invoke a reverse breakdown of the diode (which would destroy it), the diode is effectively off half of the time.
  • by bugg ( 65930 ) on Thursday July 03, 2008 @11:46AM (#24045261) Homepage

    Unless wikipedia and every site I've found on google is wrong, P4 phosphors are white. Sure you don't mean P1?

    http://en.wikipedia.org/wiki/Monochrome_monitor [wikipedia.org]

  • melatonin (Score:1, Informative)

    by Anonymous Coward on Thursday July 03, 2008 @12:01PM (#24045511)

    There have been some interesting studies of the effects of color on sleep (and cancer suppression). The results might adjust your choice of display colors. Here is an example report:
    http://www.sciencenews.org/view/generic/id/6084/title/Blue_light_keeps_night_owls_going

    It seems that the body's melatonin production is the important factor.

  • Re:ClearType FTW (Score:4, Informative)

    by Z34107 ( 925136 ) on Thursday July 03, 2008 @01:05PM (#24046719)

    Try this site [microsoft.com] if you're using XP.

    I didn't even know you could tune ClearType - but you can, and it makes ALL the DIFF uh rence... intheWORLD. Just like the right man in the wrong place...

  • by PeterBrett ( 780946 ) on Thursday July 03, 2008 @02:08PM (#24047941) Homepage

    Also, environmental factors. For example, I've been in various cubes over the years and the ones where there was a light fixture visible from my chair as I looked at my monitor caused fatigue faster than when the fixture was not visible (this includes when the fixture was behind me....basically visible in any direction from a sitting position at my desk). Also, for a while, they allowed us to dim the fixtures (turn off/remove one bulb) which helped too (not completely dark, but more cavelike).

    For those of you in the UK: if you are experiencing a problem like this in the UK and your employer refuses to fix it properly (providing decent lighting with diffusers, for instance), they are violating workplace health and safety regulations and can be liable to large fines. Don't put up with it -- get it fixed.

  • by e2d2 ( 115622 ) on Thursday July 03, 2008 @02:13PM (#24048033)

    Where is the "old world"?

    You sound pretty jaded by American culture but just keep in mind that like most things in life, we are deeper than we appear on the surface. Not everyone in the US is a greedy selfish low life. But those few that are seem to make the most impact on people. I would never sell a gift and I was raised to appreciate a gift no matter the value. But yet I was raised in America. I'm not an oddity, I'm a common person. IMO you ran into the oddity, she sold your gift.

  • Re:ClearType FTW (Score:3, Informative)

    by Z34107 ( 925136 ) on Thursday July 03, 2008 @02:44PM (#24048643)

    So is responding to flamebait - but here goes. ActiveX is the same as add-ons, except the code is sandboxed and not just allowed to run natively at browser privileges.

    But more importantly, you missed the big link at the top of the page for the PowerToy for XP. No browser needed.

    At least you clicked the link, though.

There are two ways to write error-free programs; only the third one works.

Working...