From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Steve Purcell Newsgroups: gmane.emacs.bugs Subject: bug#8402: Acknowledgement (24.0.50; Hex colors are not rendered correctly on OS X (Cocoa)) Date: Wed, 4 May 2011 13:52:30 +0100 Message-ID: <06419A7F-B281-4D8E-9E4B-D1C137F1ECFE@sanityinc.com> References: <684839CF-AD6D-43E0-8659-F419C17DD5A2@sanityinc.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 (Apple Message framework v1084) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable X-Trace: dough.gmane.org 1304514431 12998 80.91.229.12 (4 May 2011 13:07:11 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Wed, 4 May 2011 13:07:11 +0000 (UTC) To: 8402@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Wed May 04 15:07:06 2011 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1QHbnD-0006IB-Rl for geb-bug-gnu-emacs@m.gmane.org; Wed, 04 May 2011 15:07:03 +0200 Original-Received: from localhost ([::1]:43746 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QHbnD-0007pS-BC for geb-bug-gnu-emacs@m.gmane.org; Wed, 04 May 2011 09:07:03 -0400 Original-Received: from eggs.gnu.org ([140.186.70.92]:46550) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QHbn9-0007os-3U for bug-gnu-emacs@gnu.org; Wed, 04 May 2011 09:07:01 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QHbn5-0001QB-5P for bug-gnu-emacs@gnu.org; Wed, 04 May 2011 09:06:59 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:56756) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QHbn5-0001Q7-3t for bug-gnu-emacs@gnu.org; Wed, 04 May 2011 09:06:55 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.69) (envelope-from ) id 1QHbZd-0002el-Sf; Wed, 04 May 2011 08:53:01 -0400 X-Loop: help-debbugs@gnu.org In-Reply-To: <684839CF-AD6D-43E0-8659-F419C17DD5A2@sanityinc.com> Resent-From: Steve Purcell Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 04 May 2011 12:53:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 8402 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 8402-submit@debbugs.gnu.org id=B8402.130451356110172 (code B ref 8402); Wed, 04 May 2011 12:53:01 +0000 Original-Received: (at 8402) by debbugs.gnu.org; 4 May 2011 12:52:41 +0000 Original-Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QHbZJ-0002e0-4W for submit@debbugs.gnu.org; Wed, 04 May 2011 08:52:41 -0400 Original-Received: from h1189701.stratoserver.net ([85.214.32.38]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QHbZG-0002dm-7I for 8402@debbugs.gnu.org; Wed, 04 May 2011 08:52:39 -0400 Original-Received: from mandala.home (host86-151-32-155.range86-151.btcentralplus.com [86.151.32.155]) by h1189701.stratoserver.net (Postfix) with ESMTPA id 775EDECD779 for <8402@debbugs.gnu.org>; Wed, 4 May 2011 14:52:31 +0200 (CEST) X-Mailer: Apple Mail (2.1084) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list Resent-Date: Wed, 04 May 2011 08:53:01 -0400 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:46198 Archived-At: Chong Yidong wrote: > On X, we just pass color names to Xlib functions like XParseColor as > simple RGB, i.e. not specifying any particular color space, letting = that > be chosen by X. I don't know how this choice is made; the Xlib docs > simply say that the color space is device-dependent. In general, I > think we use whatever color space happens to be the system default. >=20 > I am not familiar with the code in question, but from what I can tell > the NS code always uses NSCalibratedRGBColorSpace, which indicates = that > using colorWithCalibratedRed to specify RGB components ought to do the > right thing. I don't know why it doesn't. Thinking about this, if XParseColor interprets the RGB value as a = device-dependent color, then it seems Erik is right that the correct NS = function to use would be colorWithDeviceRed, not colorWithCalibratedRed. It feels right to me that when the user sees a color on his display and = enters its hex code in his Emacs config, the same color should get = displayed. Switching to colorWithDeviceRed would seem to be the way to = achieve this on NS, and under X11 the current behavior appears = undefined. -Steve=