From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.bugs Subject: bug#9402: list-colors-display Date: Tue, 30 Aug 2011 12:10:51 +0300 Organization: JURTA Message-ID: <87hb4zp8mc.fsf@mail.jurta.org> References: <87obz83v0x.fsf@mail.jurta.org> <838vqcf086.fsf@gnu.org> <8739gjzzm1.fsf@mail.jurta.org> <4E5C77CE.3000203@swipnet.se> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1314696849 9899 80.91.229.12 (30 Aug 2011 09:34:09 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Tue, 30 Aug 2011 09:34:09 +0000 (UTC) Cc: 9402@debbugs.gnu.org To: "Jan D." Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Tue Aug 30 11:34:04 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 1QyKhn-0004mE-Qz for geb-bug-gnu-emacs@m.gmane.org; Tue, 30 Aug 2011 11:34:03 +0200 Original-Received: from localhost ([::1]:38063 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QyKhk-0001ib-Lb for geb-bug-gnu-emacs@m.gmane.org; Tue, 30 Aug 2011 05:34:00 -0400 Original-Received: from eggs.gnu.org ([140.186.70.92]:33898) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QyKhh-0001iL-Fs for bug-gnu-emacs@gnu.org; Tue, 30 Aug 2011 05:33:58 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QyKhg-0007nm-KY for bug-gnu-emacs@gnu.org; Tue, 30 Aug 2011 05:33:57 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:38262) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QyKhg-0007nT-Cv for bug-gnu-emacs@gnu.org; Tue, 30 Aug 2011 05:33:56 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.69) (envelope-from ) id 1QyKkf-0007jP-Pw; Tue, 30 Aug 2011 05:37:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Juri Linkov Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 30 Aug 2011 09:37:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 9402 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 9402-submit@debbugs.gnu.org id=B9402.131469701529704 (code B ref 9402); Tue, 30 Aug 2011 09:37:01 +0000 Original-Received: (at 9402) by debbugs.gnu.org; 30 Aug 2011 09:36:55 +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 1QyKkY-0007j2-8N for submit@debbugs.gnu.org; Tue, 30 Aug 2011 05:36:54 -0400 Original-Received: from smarty.dreamhost.com ([208.113.175.8]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QyKkV-0007iu-3E for 9402@debbugs.gnu.org; Tue, 30 Aug 2011 05:36:52 -0400 Original-Received: from ps18281.dreamhostps.com (ps18281.dreamhost.com [69.163.218.105]) by smarty.dreamhost.com (Postfix) with ESMTP id 145BE6E805E; Tue, 30 Aug 2011 02:33:44 -0700 (PDT) Original-Received: from localhost (ps18281.dreamhostps.com [69.163.218.105]) by ps18281.dreamhostps.com (Postfix) with ESMTP id 0BDD9451C3C4; Tue, 30 Aug 2011 02:33:42 -0700 (PDT) In-Reply-To: <4E5C77CE.3000203@swipnet.se> (Jan D.'s message of "Tue, 30 Aug 2011 07:40:30 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (x86_64-pc-linux-gnu) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list Resent-Date: Tue, 30 Aug 2011 05:37:01 -0400 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 1) 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:50428 Archived-At: > That is on purpose. Say a user customizes a face to use > gtk_selection_fg_color and saves it. He then starts an Emacs compiled > without Gtk+. What color shall Emacs use then? Exactly the same problem exists for all other conditional face customizations. What if a user customizes a face on X for min-colors 88 and starts Emacs on a tty with 8 colors? Or customizes a face to "color-255" on xterm-256color and starts Emacs on X? Or customizes a face for light background and starts Emacs on dark background? Or customizes a face for bold and starts Emacs where bold is not supported? And so on. Of course, graceful degradation to some closer colors could help, but the result would not be what the user has customized. To avoid these problems, customize-face should retain the conditional part of the face definition when saving the modified face. So e.g. after customizing `region' to some other colors: (((class color) (min-colors 88) (background light) (type gtk)) :foreground "white" :background "black") And after restoring the original default colors the condition will remain intact in `custom-set-faces': (((class color) (min-colors 88) (background light) (type gtk)) :foreground "gtk_selection_fg_color" :background "gtk_selection_bg_color")