With the release of version 2.2 of Substance look-and-feel
scheduled for this Monday, i have started to work on the next version (2.3 code-named Firenze).
One of the things i wanted to improve are color themes, and a lot of work has already been done
in this area. For now, i want to introduce the concept of "mixed" themes.
Substance comes with eighteen core
and twenty one plugin themes. The total
is thirty-nine. By the end of the article you will see how after a few hours of coding this has
been increased by 630 additional themes. Here is a sample screenshot of mixed themes and how
they look like on buttons:
The mixed theme is composed of two base themes. When some mixed theme is used, the resulting
image is composed from these two based themes. The first 30% is the first theme, the last 30%
is the second theme and the middle 40% is the blending between the two. Now,
Chet has
mentioned the concept of color distance. In the simplest computation, it's the Euclidean
distance between the color components (red, green, blue). For the human perception, it's
better to use hue-saturation-value scale or assign different coefficients to red-green-blue
(as when RGB is translated to gray-scale). The examples above showcase some of the best matches
distance-wise. They are not too close (so the two distinct themes are visible) and not too far
(so the themes are not dissonant). The entries above are: