From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: Native line numbers, final testing Date: Sat, 29 Jul 2017 10:01:24 +0300 Message-ID: <83y3r73ewr.fsf@gnu.org> References: <83y3s9pm2a.fsf@gnu.org> <878tk1rmjx.fsf@lylat> <83a84gn4z9.fsf@gnu.org> <837ezkmwfg.fsf@gnu.org> <874lumps82.fsf@lylat> <8337a5ja4p.fsf@gnu.org> <83van0i5wl.fsf@gnu.org> <87iniy7ksy.fsf@lylat> <83pod6idqp.fsf@gnu.org> <87zical61u.fsf@lylat> <83mv89ivms.fsf@gnu.org> <87zic9a7tg.fsf@lylat> <8360exijpe.fsf@gnu.org> <87r2xla0e4.fsf@lylat> <8337a1hxhb.fsf@gnu.org> <87d1959dsv.fsf@lylat> <83y3rsgwkk.fsf@gnu.org> <87vamfg8kc.fsf@lylat> <83mv7r5kfn.fsf@gnu.org> <87k22r3h5x.fsf@lylat> Reply-To: Eli Zaretskii NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Trace: blaine.gmane.org 1501311774 11989 195.159.176.226 (29 Jul 2017 07:02:54 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sat, 29 Jul 2017 07:02:54 +0000 (UTC) Cc: emacs-devel@gnu.org To: Alex Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat Jul 29 09:02:50 2017 Return-path: Envelope-to: ged-emacs-devel@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 1dbLlq-0002U3-PQ for ged-emacs-devel@m.gmane.org; Sat, 29 Jul 2017 09:02:42 +0200 Original-Received: from localhost ([::1]:51362 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dbLlw-0001kk-I3 for ged-emacs-devel@m.gmane.org; Sat, 29 Jul 2017 03:02:48 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:37380) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dbLkn-0001j7-KY for emacs-devel@gnu.org; Sat, 29 Jul 2017 03:01:38 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dbLkk-0008G0-F3 for emacs-devel@gnu.org; Sat, 29 Jul 2017 03:01:37 -0400 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:48034) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dbLkk-0008Fw-Cm; Sat, 29 Jul 2017 03:01:34 -0400 Original-Received: from 84.94.185.246.cable.012.net.il ([84.94.185.246]:4127 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1dbLkj-0004VK-Gl; Sat, 29 Jul 2017 03:01:34 -0400 In-reply-to: <87k22r3h5x.fsf@lylat> (message from Alex on Sat, 29 Jul 2017 00:12:42 -0600) 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: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:217118 Archived-At: > From: Alex > Cc: emacs-devel@gnu.org > Date: Sat, 29 Jul 2017 00:12:42 -0600 > > >> That makes sense, but I still don't understand why explicitly inheriting > >> from default makes a difference for face remapping. Is it just a > >> hardcoded workaround? > > > > The inheriting face references its parent, so when the parent is > > remapped, that affects the inheriting face through the attributes that > > are inherited. > > > > What is "hardcoded" here is that text-scale-adjust affects the > > 'default' face, so faces unrelated to it will not be affected. > > Right, but it's not clear to me why explicitly inheriting from default > is treated differently from an :inherit value of 'unspecified. From the > manual: > > An ‘unspecified’ attribute tells Emacs to refer instead to a parent > face That doesn't cover inheriting from 'unspecified'. And it really cannot cover it, because what is a "parent" face when the attribute is ':inherit'? A comment in xfaces.c:merge_face_vectors says it all: static void merge_face_vectors (struct frame *f, Lisp_Object *from, Lisp_Object *to, struct named_merge_point *named_merge_points) { int i; Lisp_Object font = Qnil; /* If FROM inherits from some other faces, merge their attributes into TO before merging FROM's direct attributes. Note that an :inherit attribute of `unspecified' is the same as one of nil; we never merge :inherit attributes, so nil is more correct, but lots of other code uses `unspecified' as a generic value for face attributes. */ I've now added this caveat to the manual. > I don't think the ability to customize it should go away, but the system > in place that allows for the customization just seems odd to me. IMO it isn't odd, it just didn't mean to affect any face but 'default' or its direct descendants. > Instead of using an ostensibly redundant :inherit value, why not > make a customizable list of faces that face remapping also affects? > > Perhaps it's too much work for too little gain. At this point, it certainly looks like that.