From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: Faces applies to new frames Date: Fri, 27 Jun 2008 02:18:04 -0400 Message-ID: References: <87k5gbx12n.fsf@stupidchicken.com> <87prq3k37j.fsf@stupidchicken.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1214547500 12375 80.91.229.12 (27 Jun 2008 06:18:20 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 27 Jun 2008 06:18:20 +0000 (UTC) Cc: emacs-devel@gnu.org To: Chong Yidong Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Jun 27 08:19:05 2008 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1KC7IX-0005Xi-8G for ged-emacs-devel@m.gmane.org; Fri, 27 Jun 2008 08:19:05 +0200 Original-Received: from localhost ([127.0.0.1]:38849 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KC7Hh-0002qy-FQ for ged-emacs-devel@m.gmane.org; Fri, 27 Jun 2008 02:18:13 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1KC7Hd-0002qj-Bj for emacs-devel@gnu.org; Fri, 27 Jun 2008 02:18:09 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1KC7Ha-0002qX-VE for emacs-devel@gnu.org; Fri, 27 Jun 2008 02:18:08 -0400 Original-Received: from [199.232.76.173] (port=49090 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KC7Ha-0002qU-Oa for emacs-devel@gnu.org; Fri, 27 Jun 2008 02:18:06 -0400 Original-Received: from mx20.gnu.org ([199.232.41.8]:53555) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1KC7Ha-0007Lq-3g for emacs-devel@gnu.org; Fri, 27 Jun 2008 02:18:06 -0400 Original-Received: from ironport2-out.pppoe.ca ([206.248.154.182] helo=ironport2-out.teksavvy.com) by mx20.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1KC7HZ-0007Fu-B7 for emacs-devel@gnu.org; Fri, 27 Jun 2008 02:18:05 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AqUFAJUiZEhFxIdG/2dsb2JhbACBW7EbgXM X-IronPort-AV: E=Sophos;i="4.27,714,1204520400"; d="scan'208";a="23305819" Original-Received: from 69-196-135-70.dsl.teksavvy.com (HELO pastel.home) ([69.196.135.70]) by ironport2-out.teksavvy.com with ESMTP; 27 Jun 2008 02:18:04 -0400 Original-Received: by pastel.home (Postfix, from userid 20848) id 0CE7A801D; Fri, 27 Jun 2008 02:18:04 -0400 (EDT) In-Reply-To: <87prq3k37j.fsf@stupidchicken.com> (Chong Yidong's message of "Thu, 26 Jun 2008 22:43:12 -0400") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux) X-detected-kernel: by mx20.gnu.org: Genre and OS details not recognized. X-detected-kernel: by monty-python.gnu.org: Linux 2.6, seldom 2.4 (older, 4) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:99998 Archived-At: >>> AFAICT, the problem is that the default face is controlled by the `font' >>> frame parameter, but this is not saved to default-frame-alist by >>> internal-set-lisp-face-attribute. In comparison, the foreground-color >> >> I'm not convinced this is the root of the problem. For one, by default >> there is no `font' parameter in default-frame-alist, so as long as we >> leave it that way, it should not affect face settings. The code in >> face-set-after-frame-default should apply the defface-spec to every >> new frame, so we shouldn't need any entry in default-frame-alist for it >> to apply to new frames. The face-set-after-frame-default used to skip >> `default', so that was an important reason for the bug#47. I've fixed >> this part, but there are other weird things going on (I have some other >> weird problems here where X resources are obeyed even after I remove >> the calls to `make-face-x-resource-internal'). > Maybe there's more than one bug here. When set-face-attribute is called > with a nil FRAME argument, that changes the face for all frames, and > this is done via frame parameters and not by changing the defface spec. > I don't think face-set-after-frame-default is even relevant to this > case. Indeed, there's also the distinction between face changes made via customize and those made by direct calls to set-face-attribute. The more I look at it, the mor it seems obvious that we cannot fix it by looking at individual events, but we need to first figure out it currently (fails to) work overall, and then design a way to make it work in an overall consistent way. Stefan