From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Drew Adams" Newsgroups: gmane.emacs.devel Subject: RE: Simplification of faces Date: Sun, 30 Sep 2007 16:53:56 -0700 Message-ID: References: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-15" Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1191196436 30354 80.91.229.12 (30 Sep 2007 23:53:56 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Sun, 30 Sep 2007 23:53:56 +0000 (UTC) To: , Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Oct 01 01:53:49 2007 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 1Ic8bc-0004o1-4o for ged-emacs-devel@m.gmane.org; Mon, 01 Oct 2007 01:53:48 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Ic8bY-0003MI-BL for ged-emacs-devel@m.gmane.org; Sun, 30 Sep 2007 19:53:44 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Ic8bV-0003M9-Vq for emacs-devel@gnu.org; Sun, 30 Sep 2007 19:53:42 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Ic8bV-0003Lt-Lb for emacs-devel@gnu.org; Sun, 30 Sep 2007 19:53:41 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Ic8bV-0003Lj-90 for emacs-devel@gnu.org; Sun, 30 Sep 2007 19:53:41 -0400 Original-Received: from agminet01.oracle.com ([141.146.126.228]) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1Ic8bQ-0005HS-Ou; Sun, 30 Sep 2007 19:53:37 -0400 Original-Received: from agmgw2.us.oracle.com (agmgw2.us.oracle.com [152.68.180.213]) by agminet01.oracle.com (Switch-3.2.4/Switch-3.1.7) with ESMTP id l8UNrY2U011576; Sun, 30 Sep 2007 18:53:34 -0500 Original-Received: from acsmt351.oracle.com (acsmt351.oracle.com [141.146.40.151]) by agmgw2.us.oracle.com (Switch-3.2.0/Switch-3.2.0) with ESMTP id l8UNhRri028628; Sun, 30 Sep 2007 17:53:33 -0600 Original-Received: from dhcp-amer-csvpn-gw1-141-144-64-133.vpn.oracle.com by acsmt350.oracle.com with ESMTP id 3255987521191196412; Sun, 30 Sep 2007 16:53:32 -0700 X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook IMO, Build 9.0.6604 (9.0.2911.0) Importance: Normal X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.3138 In-Reply-To: X-Brightmail-Tracker: AAAAAQAAAAI= X-Brightmail-Tracker: AAAAAQAAAAI= X-Whitelist: TRUE X-Whitelist: TRUE X-Detected-Kernel: Linux 2.4-2.6 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:80070 Archived-At: > I am thinking of essentially eliminating the face attributes as a way > to control what a face looks like. Programs would use only `defface' > and `face-spec-set'. What about `modify-face'? > In addition, a spec given in `face-spec-set' would totally replace > whatever spec was previously given for the same face using the > `defface' or `face-spec-set'. Thus, the appearance information for a > face would consist of a single Lisp datum, plus X resources. > (Inheritance from other faces would still occur.) I'm not too clear on `face-spec-set'. Is what it does now is replace only those attributes that are included in its SPEC arg, leaving the others alone? Its code and doc are a bit confusing to me - it seems to say that it first "resets all attributes of FACE on FRAME to unspecified" (face-spec-reset-face). That makes me think that it does what you propose to do: totally replace the existing spec. Please help me a little to understand the issue. > I've checked all the uses of `face-spec-set' outside of custom and > faces.el. It seems they would not need to be changed. > > However, this would require rewriting the code that calls > `set-face-attribute' and the older functions such as > `set-face-foreground' that set single attributes. There are only > about 8 packages in Emacs which do so, so it would not be a big job. > However, there may be some other programs that users use which still > rely on this feature. Rely on which feature? Sorry, but it's not clear to me what feature you would be taking away or changing. If you can clarify, I'll check my code to see how it might be impacted. I do quite a lot of face attribute changing in different ways. I hope that I will at least be able to still use `modify-face'. > What do people think? I don't understand the difference in this regard between `face-spec-set' and `set-face-attribute'. Could you summarize the problem that you want to fix for the latter?