bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#9722: list-colors-duplicates does not exclude enough colors on Windo


From: Eli Zaretskii
Subject: bug#9722: list-colors-duplicates does not exclude enough colors on Windows
Date: Tue, 11 Oct 2011 21:39:29 +0200

> From: Juanma Barranquero <address@hidden>
> Date: Tue, 11 Oct 2011 13:24:04 +0200
> Cc: address@hidden
> 
> On Tue, Oct 11, 2011 at 08:01, Eli Zaretskii <address@hidden> wrote:
> 
> > However, there's something I'm missing here: why doesn't
> > list-colors-duplicates recognize grayNN and greyNN as duplicates?
> > We don't have them in the list that w32-default-color-map returns.
> 
> That's why. The System* colors aren't either. What the current code
> does on Windows is, basically, to detect duplicates when this
> 
>   (and (facemenu-color-equal COLOR1 COLOR2)
>        (assoc COLOR1 (w32-default-color-map)))
> 
> is true. I.e., COLOR1 is only checked if present in the default color
> list

What is the purpose of checking w32-default-color-map?  Is it solely
for detecting the System* colors?  That sounds an odd method of doing
so.  It is also fragile: it means any color not in
w32-default-color-map will pass the duplicate test.

> > As for duplicates such as "Dark Slate Gray" and "Dark Slate Grey",
> > which are not filtered out because they _are_ in
> > w32-default-color-map
> 
> I'm not sure I understand. The dark*slate*gr?y colors are in the list,
> and so they are detected as duplicates.

No, they aren't.  Don't you see the lines below?

  dark slate gray       dark slate gray,dark slate 
grey,DarkSlateGray,DarkSlateGrey  #2f4f4f
  dim gray              dim gray,dim grey,DimGray,DimGrey  #696969
  slate gray            slate gray,slate grey,SlateGray,SlateGrey  #708090
  light slate gray      light slate gray,light slate 
grey,LightSlateGray,LightSlateGrey  #778899
  light gray            light gray,light grey,LightGray,LightGrey  #d3d3d3





reply via email to

[Prev in Thread] Current Thread [Next in Thread]