Live data from Hacker News

Building your color palette

refactoringui.com

81–90 of 118 posts

Re: Building your color palette

#81
post #66
post #54

Earlier quoted context omitted.

Can you point me to any resources where I can learn more?

More than you ever wanted to know, in one well-illustrated blog post: http://jamie-wong.com/post/color/

That's awesome. It makes me think, though, that we could do a lot better than RGB given accurate values for actual human cone sensitivity and better subpixel colors. We should be able to get a digital gamut that fully spans the visible spectrum.

Re: Building your color palette

#83
post #12

Take this one step further and build the color palette into your stylesheets. If you're using Sass you can setup something like: $palettes: ( blue: ( lightest: hsl(201, 75%, 66%), lighter: hsl(201, 75%, 61%), light: hsl(201, 75%, 56%), base: hsl(201, 75%, 51%), dark: hsl(201, 75%, 46%), darker: hsl(201, 75%, 41%), darkest: hsl(201, 75%, 36%) ), red: (...), gray: (...) ) @function palette($palette, $tone: 'base') { @r…

By the way, you can also generate CSS using e.g. Python. No need for yet another domain specific language.

Re: Building your color palette

#85

Earlier quoted context omitted.

I'm happy to give them the benefit of the doubt, and I think many colour pickers wanted to do the right thing. HSL or HSV was a step up from RGB, so it made sense to use it to derive other colours quickly. Because if you're an underpaid freelance developer, the primary colour is usually set by the client, but they usually son't have a full colour scheme. Using a colour wheel based tool gave good enough results fast.…

> If you need them to "look good", well that's art, not science. I'm not so much interested in "look good" but in "look pleasing or harmonious together" and I think that's a question science might have an answer to. It's no coincidence that the palette generators borrow musical jargon. In music the definitions of minor second and perfect octave are completely uncontroversial. That these two intervals have different m…

>I wonder if that is just my impression because it's not my field, or if maybe color science really is just not developed enough to tackle these kind of questions.

I have wondered the same thing ( https://ask.metafilter.com/245014/Help-me-understand-color-t... ) and haven't found anything.

I've had some subsequent thoughts. We know that there is a characteristic of the human perception of scenes called "color constancy". That is that our visual perceptual abilities are surprisingly robust to changes in the character of light sources. We may be aware of the light source color, but we easily "factor it out" of what we see of the objects in the scene. It is as if color constancy takes the distribution of colors and applies some transformation to standardize that distribution.

My guess is that the mechanisms underlying color constancy contribute to the aesthetic feel of the scene. If a scene's colors lie along a single line (e.g. a grayscale image), there is a sort of cramped or confined feeling (at least, I experience this), as if the color constancy mechanism is attempting to make a gaussian sphere* out of the colors but there's not enough variance to make it work.

At the same time, if you make a palette out of the corners of the RGB cube, there's an unusually high amount of variance. The image might be very vivid but it gives me an impression of excessive busy-ness or energy. The sphere has spikes now!

Maybe harmonious color schemes are those in which the color constancy mechanism doesn't have to do too much work to make the color distribution into a standard shape... maybe. I don't have any evidence or anything.

I don't think the "standard" distribution of colors that would feel neutral is actually going to be a sphere, but it's not going to be perfectly flat and it's not going to be a straight line. It is possible to visualize the color histograms of images as 3d point clouds to get some sense of what feeling is evoked by different color distributions (e.g. http://opensource.graphics/visualizing-the-3d-point-cloud-of... )

Re: Building your color palette

#86

> There's no real science > It's not a science I preach and preach that to people on certain other forums who insist you need one of those palette generators or palette samplers, and everyone praises them, but it's ART not SCIENCE or MATH! It's why there are artists who design the look of things and not scientists or engineers.

I think a big thing but underrated thing is iteration. Giving things time to "simmer", looking at things with fresh eyes often, i.e. having multiple shorter sessions instead of few long ones, and simply playing around with and comparing various ways how things could look, can get you quite a long way.

Otherwise, you end up with "coder colors".

http://www.pouet.net/prod.php?which=53631

Re: Building your color palette

#87

No mention of color blindness or a11y, which seem like important factors in color selection.

This simulates the effects of various types of color blindness on any webpage:

https://www.toptal.com/designers/colorfilter

Something like that could even be part of automated testing for graphical applications and websites -- why not?

Re: Building your color palette

#88
It's a bunch of variables, so expose them to the users, and let them create and share color schemes. Pick some of those for the off-the-shelf selection, and it'll be better than any single color scheme.

Even better would be a standard way for websites and browsers to negotiate color schemes, and for users to be able to set specific themes for sites, a theme for all sites, themes depending on the URL, enforce legibility with color blindness, and so on. It's 2018, yet we don't even trust people with selecting user stylesheets in the GUI anymore.

To me, how to make neat colors is a discussion normal users should have, that it's so much in the hand of web designers is a failure in and of itself.

Re: Building your color palette

#90

After reading this, I created a theme color picker in a single HTML file with no libraries. It's only tested in the latest Chrome. https://gist.github.com/steve-taylor/40f54b400785258b80d4792...

Tested and working well with the latest Firefox (v63). Nice work, this is handy!
Post reply on HN