From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Lars Ingebrigtsen Newsgroups: gmane.emacs.bugs Subject: bug#5305: [patch] add defined-colors-with-face-attributes to faces.el Date: Sun, 28 Feb 2016 17:30:30 +1100 Message-ID: <87povhs5x5.fsf@gnus.org> References: <27784_1262552552_ZZg0O2405RUGf.00_1262552551.3761.1645.camel@localhost.localdomain> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1456641085 23808 80.91.229.3 (28 Feb 2016 06:31:25 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 28 Feb 2016 06:31:25 +0000 (UTC) Cc: 5305@debbugs.gnu.org To: Jan Moringen Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Feb 28 07:31:14 2016 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1aZuss-0005ce-3u for geb-bug-gnu-emacs@m.gmane.org; Sun, 28 Feb 2016 07:31:14 +0100 Original-Received: from localhost ([::1]:57710 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aZuso-0002E3-89 for geb-bug-gnu-emacs@m.gmane.org; Sun, 28 Feb 2016 01:31:10 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:59090) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aZusk-0002Dx-11 for bug-gnu-emacs@gnu.org; Sun, 28 Feb 2016 01:31:06 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aZusg-0008MI-R1 for bug-gnu-emacs@gnu.org; Sun, 28 Feb 2016 01:31:05 -0500 Original-Received: from debbugs.gnu.org ([208.118.235.43]:52299) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aZusg-0008MD-NY for bug-gnu-emacs@gnu.org; Sun, 28 Feb 2016 01:31:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84) (envelope-from ) id 1aZusg-0004sP-A4 for bug-gnu-emacs@gnu.org; Sun, 28 Feb 2016 01:31:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Lars Ingebrigtsen Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 28 Feb 2016 06:31:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 5305 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 5305-submit@debbugs.gnu.org id=B5305.145664106118698 (code B ref 5305); Sun, 28 Feb 2016 06:31:02 +0000 Original-Received: (at 5305) by debbugs.gnu.org; 28 Feb 2016 06:31:01 +0000 Original-Received: from localhost ([127.0.0.1]:49426 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84) (envelope-from ) id 1aZusf-0004rG-12 for submit@debbugs.gnu.org; Sun, 28 Feb 2016 01:31:01 -0500 Original-Received: from hermes.netfonds.no ([80.91.224.195]:35702) by debbugs.gnu.org with esmtp (Exim 4.84) (envelope-from ) id 1aZuse-0004q8-2X for 5305@debbugs.gnu.org; Sun, 28 Feb 2016 01:31:00 -0500 Original-Received: from cpe-60-225-211-161.nsw.bigpond.net.au ([60.225.211.161] helo=mouse) by hermes.netfonds.no with esmtpsa (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.72) (envelope-from ) id 1aZusF-0004as-9z; Sun, 28 Feb 2016 07:30:35 +0100 In-Reply-To: <27784_1262552552_ZZg0O2405RUGf.00_1262552551.3761.1645.camel@localhost.localdomain> (Jan Moringen's message of "Sun, 03 Jan 2010 22:02:31 +0100") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1.50 (gnu/linux) X-MailScanner-ID: 1aZusF-0004as-9z MailScanner-NULL-Check: 1457245837.29934@6HYI27UiAOAUSh04aqycLw X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.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:114021 Archived-At: Jan Moringen writes: > in an application I wrote, the user is prompted for a color using > `read-color'. The completion table used there presents color names. > However, based on color names alone, I often found it hard to choose a > color. Therefore I wrote `defined-colors-with-face-attributes' which > is > like `defined-colors' but adds text properties to the color names that > make them render with the color they name as background. I also > changed > `read-color' to call the new function when a color display is > available. > > I have tested the new behavior on X displays and TTYs and it seems to > work. However, I could not test windows or other terminal types and/or > other color depths. I like it a lot, so I've applied it to the Emacs trunk. All the colour combinations were legible on my screen, but perhaps some people have screens where they may be less so, but I guess we'll find out. -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no