> From: Richard Copley <rcopley@gmail.com>
> Date: Wed, 21 Mar 2018 13:22:37 +0000
> Cc: John Wiegley <johnw@gnu.org>, Tom Tromey <tom@tromey.com>,
> Emacs Development <emacs-devel@gnu.org>
>
> We do something very similar in frame-set-background-mode and in
> tty-color-approximate.
>
> I don't see it. You're talking about this?
>
> ((>= (apply '+ (color-values bg-color frame))
> ;; Just looking at the screen, colors whose
> ;; values add up to .6 of the white total
> ;; still look dark to me.
> (* (apply '+ (color-values "white" frame)) .6))
That's the first example, yes.
> It's this particular way of using color-distance that we appear to
> have invented.
Not according to the article from which the implementation of
color-distance was taken.
> If we didn't then we took it from
> somewhere else, and someone (Tom?) should know where.
The comments in the sources of color-distance tell where we took it
from.
> I don't believe the concept of a sphere centred on black is a useful one in this context, or that allowing the
> user to vary its radius makes it any better.
I suggest to read the original article mentioned above.