From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: buffer-face-set changes the fringe, is it a bug? Date: Sun, 05 Jul 2020 13:50:11 +0300 Message-ID: <2E75863E-82E2-4D61-AD34-0282362C6E99@gnu.org> References: Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="7039"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: K-9 Mail for Android To: Gregory Heytings , "Gregory Heytings via Emacs development discussions." , emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sun Jul 05 12:50:53 2020 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1js2EX-0001jd-9V for ged-emacs-devel@m.gmane-mx.org; Sun, 05 Jul 2020 12:50:53 +0200 Original-Received: from localhost ([::1]:43036 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1js2EW-0000mU-5m for ged-emacs-devel@m.gmane-mx.org; Sun, 05 Jul 2020 06:50:52 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:53182) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1js2Dx-0000Kz-CP for emacs-devel@gnu.org; Sun, 05 Jul 2020 06:50:17 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:60002) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1js2Dv-0005hR-Pn; Sun, 05 Jul 2020 06:50:15 -0400 Original-Received: from [176.12.156.255] (port=55579 helo=[10.161.21.0]) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_128_CBC_SHA1:128) (Exim 4.82) (envelope-from ) id 1js2Du-0007sb-Tk; Sun, 05 Jul 2020 06:50:15 -0400 In-Reply-To: X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 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-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:252692 Archived-At: On July 5, 2020 11:56:00 AM GMT+03:00, "Gregory Heytings via Emacs developm= ent discussions=2E" wrote: >=20 > Hi list, >=20 > Is the following behavior expected, or is it a bug? >=20 > (set-face-attribute 'fringe nil :background "red") > (let ((o (make-overlay 0 1)) (s "_")) > (put-text-property 0 1 'display '(left-fringe question-mark) s) > (overlay-put o 'after-string s)) >=20 > This puts a question mark in the left fringe=2E At least on Emacs 26=2E= 3=20 > (started with emacs -Q), after: >=20 > (buffer-face-set '(:background "yellow")) >=20 > the background of the buffer *and* the question mark in the fringe > become=20 > yellow=2E I would have expected that the background of the question > mark=20 > would still be red=2E >=20 > Gregory You are assuming that 'display' property that draws on the fringe automati= cally uses the 'fringe' face? But that's not how this property works: it u= ses the 'default' face (and thus is subject to face remapping)=2E To use a= nother face, you need to specify it in the 'left-fringe' form, see the ELis= p manual for the details=2E IOW, this is not a bug=2E