Subject: Re: bug#17808: 24.4.50; vc-annotate colors

From: Juri Linkov <[email-masked]>
Date: Tue, 08 Jul 2014 11:51:43 +0300

Version: 24.4.50

> To reduce saturation from 75% to 20% it was helpful to use
> the function `color-hsv-to-rgb' that I found in the list archives.

Installed in the trunk.

PS: this code shows how `color-hsv-to-rgb' could be used
to reduce saturation:

(pp
 (mapcar
  (lambda (pair)
    (cons
     (car pair)
     (let ((hsv (apply 'color-rgb-to-hsv
                       (color-name-to-rgb
                        (cdr pair)))))
       (apply 'color-rgb-to-hex
              (color-hsv-to-rgb
               (nth 0 hsv) 0.20 (nth 2 hsv))))))
  '(( 20. . "#FF3F3F")
    ( 40. . "#FF6C3F")
    ( 60. . "#FF993F")
    ( 80. . "#FFC63F")
    (100. . "#FFF33F")
    (120. . "#DDFF3F")
    (140. . "#B0FF3F")
    (160. . "#83FF3F")
    (180. . "#56FF3F")
    (200. . "#3FFF56")
    (220. . "#3FFF83")
    (240. . "#3FFFB0")
    (260. . "#3FFFDD")
    (280. . "#3FF3FF")
    (300. . "#3FC6FF")
    (320. . "#3F99FF")
    (340. . "#3F6CFF")
    (360. . "#3F3FFF"))))