14 Sep
2001
14 Sep
'01
07:56
Somewhere or other, quite a while ago, I saw a program that does the same thing as xcolors, only better and more conveniently, i.e., it shows you the color associated with each name in the X rgb color map. Can anyone point me to it? I tried to locate it via both freshmeat and google but failed.
You could use a Tcl/Tk script to do it. Put the code below in an executable file, run it, then double click on the colour names in the list box. Drag with the middle mouse button to scroll the list. #!/usr/bin/wish pack [listbox .colours] set h [open /usr/lib/X11/rgb.txt] while {[gets $h l] >= 0} { .colours insert end [lrange $l 3 end]} close $h bind .colours <Double-Button-1> { .colours configure -background [selection get] }