From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: "Eli Zaretskii" Newsgroups: gmane.emacs.pretest.bugs,gmane.emacs.devel Subject: Re: Font-lock.el uses strange value for min-colors (Was x-display-color-cells returns wrong number) Date: Mon, 01 Mar 2004 08:07:10 +0200 Sender: emacs-pretest-bug-bounces+gebp-emacs-pretest-bug=gmane.org@gnu.org Message-ID: <8011-Mon01Mar2004080710+0200-eliz@elta.co.il> References: <14AB9AB8-6A0E-11D8-99DB-00039363E640@swipnet.se> <2914-Sun29Feb2004201424+0200-eliz@elta.co.il> <60951CF7-6AED-11D8-8672-00039363E640@swipnet.se> <2719-Sun29Feb2004232501+0200-eliz@elta.co.il> Reply-To: Eli Zaretskii NNTP-Posting-Host: deer.gmane.org X-Trace: sea.gmane.org 1078121782 32680 80.91.224.253 (1 Mar 2004 06:16:22 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Mon, 1 Mar 2004 06:16:22 +0000 (UTC) Cc: harder@ifa.au.dk, emacs-pretest-bug@gnu.org, emacs-devel@gnu.org Original-X-From: emacs-pretest-bug-bounces+gebp-emacs-pretest-bug=gmane.org@gnu.org Mon Mar 01 07:16:15 2004 Return-path: Original-Received: from monty-python.gnu.org ([199.232.76.173]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1Axgit-0002oY-00 for ; Mon, 01 Mar 2004 07:16:15 +0100 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.30) id 1Axgg4-0006TN-64 for gebp-emacs-pretest-bug@gmane.org; Mon, 01 Mar 2004 01:13:20 -0500 Original-Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.30) id 1Axgfv-0006SQ-27 for emacs-pretest-bug@gnu.org; Mon, 01 Mar 2004 01:13:11 -0500 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.30) id 1Axgci-0005xr-Sz for emacs-pretest-bug@gnu.org; Mon, 01 Mar 2004 01:10:24 -0500 Original-Received: from [192.114.186.18] (helo=bilbo.inter.net.il) by monty-python.gnu.org with esmtp (Exim 4.30) id 1Axgb2-0005bX-LM; Mon, 01 Mar 2004 01:08:08 -0500 Original-Received: from zaretski (pns03-195-232.inter.net.il [80.230.195.232]) by bilbo.inter.net.il (MOS 3.4.4-GR) with ESMTP id CNM92987; Mon, 1 Mar 2004 08:08:01 +0200 (IST) Original-To: Jason Rumney X-Mailer: emacs 21.3.50 (via feedmail 8 I) and Blat ver 1.8.9 In-reply-to: (message from Jason Rumney on 29 Feb 2004 22:39:21 +0000) X-BeenThere: emacs-pretest-bug@gnu.org X-Mailman-Version: 2.1.2 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-pretest-bug-bounces+gebp-emacs-pretest-bug=gmane.org@gnu.org Xref: main.gmane.org gmane.emacs.pretest.bugs:2262 gmane.emacs.devel:20213 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:20213 > From: Jason Rumney > Date: 29 Feb 2004 22:39:21 +0000 > > "Eli Zaretskii" writes: > > > It sounds like display-color-cells does that on every platform > > except X > > Since color-cells is originally an X concept, I think those other > platforms only do that because of a lack of understanding about what X > really means by color-cells. It does seem like display-planes is more > reliable at least on X and W32 (where it was fixed to mean the same as > X some time ago, since W32 has a different idea of planes), so how > about changing the calculation of min-colors in faces.el to > > (>= (expt 2.0 (display-planes frame)) (car options)) I'd rather not do this. display-color-cells was written to return the number of supported colors, period. (The fact that the name says color-cells is a bow to the X-specific function that was supposed to return the same value on X, and otherwise has no other meaning. The names of all display-* functions were reviewed and approved by Richard at least, so it's not only my own misunderstanding of X that went into the design and the name.) So I'd rather modify the definition of display-color-cells on X along the lines suggested by Jan to bring that function up to what its docs advertise. > 2.0 seems to be required (as opposed to 2) to force floating point in > case of 32 bit displays, this might be a bug in Emacs It's a feature, see the function's code on floatfns.c.