From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.help Subject: Re: Overriding inherited face attributes Date: Thu, 29 Nov 2018 09:14:52 +0200 Message-ID: <83ftvke4nn.fsf@gnu.org> References: <87pnuqfboc.fsf@gmx.net> <83sgzlg1w7.fsf@gnu.org> <87in0h1jak.fsf@rub.de> <8336rlfj1y.fsf@gnu.org> <87efb51h18.fsf@rub.de> <831s75fa5q.fsf@gnu.org> <87a7lt0y5b.fsf@rub.de> <83in0hdjo4.fsf@gnu.org> <875zwg28ek.fsf@rub.de> NNTP-Posting-Host: blaine.gmane.org X-Trace: blaine.gmane.org 1543476661 32706 195.159.176.226 (29 Nov 2018 07:31:01 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Thu, 29 Nov 2018 07:31:01 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Thu Nov 29 08:30:57 2018 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gSGmn-0008Ma-B2 for geh-help-gnu-emacs@m.gmane.org; Thu, 29 Nov 2018 08:30:57 +0100 Original-Received: from localhost ([::1]:52648 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gSGot-0000ap-IE for geh-help-gnu-emacs@m.gmane.org; Thu, 29 Nov 2018 02:33:07 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:54357) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gSGkI-0004db-KL for help-gnu-emacs@gnu.org; Thu, 29 Nov 2018 02:28:26 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gSGX2-0000tM-RT for help-gnu-emacs@gnu.org; Thu, 29 Nov 2018 02:14:43 -0500 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:43986) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gSGX2-0000sq-KD for help-gnu-emacs@gnu.org; Thu, 29 Nov 2018 02:14:40 -0500 Original-Received: from [176.228.60.248] (port=2089 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1gSGX2-0001hE-6F for help-gnu-emacs@gnu.org; Thu, 29 Nov 2018 02:14:40 -0500 In-reply-to: <875zwg28ek.fsf@rub.de> (message from Stephen Berman on Wed, 28 Nov 2018 22:34:43 +0100) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.21 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" Xref: news.gmane.org gmane.emacs.help:118804 Archived-At: > From: Stephen Berman > Cc: help-gnu-emacs@gnu.org > Date: Wed, 28 Nov 2018 22:34:43 +0100 > > > So this is only about what propertize does? And only when some of the > > later properties override earlier ones? > > Well, it's at least about what propertize does, since that was the OP's > example (the first form above), which lead to my observation of the > difference with the second form. My reading of the code is that later face attributes override the earlier once, i.e. the attributes are processed in order, and :inherit doesn't have any precedence in this case. Which seems like a sensible thing, but I'm not sure we want to document this implementation detail. In general, having conflicting face attributes in the face definition is not a good idea anyway; the only sensible use case is when you want to change (i.e. override) some attribute of an existing face, and for that, putting the overriding attribute at the end is the natural thing to do. IOW, Emacs seems to do what users should expect.