From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Richard Cobbe Newsgroups: gmane.emacs.help Subject: How to set minibuffer-prompt face foreground conditionally? Date: Sun, 12 Feb 2012 12:32:00 -0500 Message-ID: <20120212173200.GA430@weatherwax.local> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: dough.gmane.org 1329075913 23062 80.91.229.3 (12 Feb 2012 19:45:13 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Sun, 12 Feb 2012 19:45:13 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sun Feb 12 20:45:12 2012 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1RwfMA-0001ft-Dz for geh-help-gnu-emacs@m.gmane.org; Sun, 12 Feb 2012 20:45:06 +0100 Original-Received: from localhost ([::1]:56094 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RwfM8-0004s1-Td for geh-help-gnu-emacs@m.gmane.org; Sun, 12 Feb 2012 14:45:04 -0500 Original-Received: from eggs.gnu.org ([140.186.70.92]:44526) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RwdHi-0002Q9-Lv for help-gnu-emacs@gnu.org; Sun, 12 Feb 2012 12:32:23 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RwdHh-0003tp-Ie for help-gnu-emacs@gnu.org; Sun, 12 Feb 2012 12:32:22 -0500 Original-Received: from amber.ccs.neu.edu ([129.10.116.51]:48780) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RwdHh-0003tc-H0 for help-gnu-emacs@gnu.org; Sun, 12 Feb 2012 12:32:21 -0500 Original-Received: from zimbra.ccs.neu.edu ([129.10.116.59]) by amber.ccs.neu.edu with esmtp (Exim 4.69) (envelope-from ) id 1RwdHg-00071G-EI for help-gnu-emacs@gnu.org; Sun, 12 Feb 2012 12:32:20 -0500 Original-Received: from localhost (localhost [127.0.0.1]) by zimbra.ccs.neu.edu (Postfix) with ESMTP id 62487F64003; Sun, 12 Feb 2012 12:32:20 -0500 (EST) X-Virus-Scanned: amavisd-new at zimbra.ccs.neu.edu Original-Received: from zimbra.ccs.neu.edu ([127.0.0.1]) by localhost (zimbra.ccs.neu.edu [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id JUk5Mm7YQNfJ; Sun, 12 Feb 2012 12:32:14 -0500 (EST) Original-Received: from localhost (unknown [65.206.93.100]) by zimbra.ccs.neu.edu (Postfix) with ESMTP id 03B86F64006; Sun, 12 Feb 2012 12:32:11 -0500 (EST) Content-Disposition: inline User-Agent: Mutt/1.5.21 (2010-09-15) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-Received-From: 129.10.116.51 X-Mailman-Approved-At: Sun, 12 Feb 2012 14:45:00 -0500 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 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 Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:83717 Archived-At: I'm using GNU Emacs 23.3.1 on MacOS 10.6, although I've observed the same behavior with 23.1.1 on Ubuntu 10.10. I'm having trouble setting the foreground color of minibuffer-prompt in my .emacs file. If I evaluate (set-face-foreground 'minibuffer-prompt "cyan") either with M-x eval-expression or in the scratch buffer, then the face changes color. But if I put the same thing into .emacs and restart, it has no effect at all. Customizing the font works, but this isn't sufficient for what I'm trying to do; see below. Context: I want to change the foreground color of the minibuffer-prompt face, but only when window-system is nil. Normally (when window-system is one of 'mac 'ns or 'x) the minibuffer prompt is readable, but when I run emacs in a terminal, the minibuffer prompt shows up as dark blue on the only-slightly-different dark blue that I use for my xterm background. I do have '(background-mode . dark) in default-frame-alist for all window-systems. Is there a way to do this that I'm overlooking? Thanks, Richard