From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Ian Zimmerman Newsgroups: gmane.emacs.help Subject: Re: Emacs-21.3 is ignoring my X-resources colors setting Date: 11 Jul 2004 08:08:08 -0700 Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Message-ID: <87iscueg4n.fsf@buug.org> References: NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1089558779 14316 80.91.224.253 (11 Jul 2004 15:12:59 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Sun, 11 Jul 2004 15:12:59 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sun Jul 11 17:12:52 2004 Return-path: Original-Received: from lists.gnu.org ([199.232.76.165]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1Bjg0a-0001mu-00 for ; Sun, 11 Jul 2004 17:12:52 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1Bjg2q-000058-VB for geh-help-gnu-emacs@m.gmane.org; Sun, 11 Jul 2004 11:15:12 -0400 Original-Path: shelby.stanford.edu!newsfeed.stanford.edu!headwall.stanford.edu!fu-berlin.de!uni-berlin.de!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 29 Original-X-Trace: news.uni-berlin.de XP7U6dXTl91IQEqT2UP9rAmdgrtpFc+1d1hnU3Q3I7yc8w30Ri User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3 Original-Xref: shelby.stanford.edu gnu.emacs.help:124244 Original-To: help-gnu-emacs@gnu.org X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: main.gmane.org gmane.emacs.help:19577 X-Report-Spam: http://spam.gmane.org/gmane.emacs.help:19577 Harry> Does anyone know where there is a handy dandy reference chart Harry> that shows equivalent meaning of color notations like these in Harry> plain english? Harry> nedit*statsLine.background: #e6e6e6 Harry> nedit*statsLine.foreground: #000000 Harry> nedit*text.background: #ffffff Harry> nedit*text.cursorForeground: #000000 Harry> nedit*text.foreground: #000000 Harry> nedit*text.selectBackground: #4c59a6 Harry> nedit*text.selectForeground: #ffffff Do you mean lookup the color name based on the RGB value? In general this is ill-defined because there are only about 1000 colors defined in rgb.txt but there are 256^6 possible RGB combinations, assuming 16 bit depth. What you can do is program a best approximation in some sense, for example, least-square approximation. The classic program for that is xcolorsel; I have recently written a gtk 2.x act-alike called gcolorsel: http://primate.net/~itz/gcolorsel_1.9.1.orig.tar.gz (the .orig. is because it is part of a Debian source package, together with the .dsc and .diff.gz files at the same location) -- "It's not true or not." A reality show producer (real quote)