From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: steve-humphreys@gmx.com Newsgroups: gmane.emacs.help Subject: Re: typeface for keyword Date: Mon, 15 Feb 2021 18:17:38 +0100 Message-ID: References: <87sg5xiav3.fsf@zoho.eu> 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="39476"; mail-complaints-to="usenet@ciao.gmane.io" Cc: help-gnu-emacs@gnu.org To: moasenwood@zoho.eu Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Mon Feb 15 18:18:35 2021 Return-path: Envelope-to: geh-help-gnu-emacs@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 1lBhW7-000A8f-5z for geh-help-gnu-emacs@m.gmane-mx.org; Mon, 15 Feb 2021 18:18:35 +0100 Original-Received: from localhost ([::1]:43686 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lBhW6-000731-6n for geh-help-gnu-emacs@m.gmane-mx.org; Mon, 15 Feb 2021 12:18:34 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:33590) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lBhVI-00072i-IQ for help-gnu-emacs@gnu.org; Mon, 15 Feb 2021 12:17:44 -0500 Original-Received: from mout.gmx.net ([212.227.15.15]:55181) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lBhVE-0008QB-Vo for help-gnu-emacs@gnu.org; Mon, 15 Feb 2021 12:17:44 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1613409458; bh=3nU2WX6VWUlSo/Pt5XvN/9yBvVnxdS61rUkc2lc/II4=; h=X-UI-Sender-Class:From:To:Cc:Subject:Date:In-Reply-To:References; b=TMgDw1d0AUYPQ+ZzQ4iEkhcU9tnnM5tdQBz5QXdub3LTRbjLXn+WV8r1KdVpV7JDx fKWAUkJGa6bCCBEZ9anzb+hFqwGmkujVeUB9zi4SDZuuW7kvNMTJGWCCv2YOJFEMuJ l0ke6caN+TGbBZquhxDUwudPXqQ9E6bXQs95ienc= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Original-Received: from [213.165.168.94] ([213.165.168.94]) by web-mail.gmx.net (3c-app-mailcom-bs12.server.lan [172.19.170.180]) (via HTTP); Mon, 15 Feb 2021 18:17:38 +0100 Importance: normal Sensitivity: Normal In-Reply-To: <87sg5xiav3.fsf@zoho.eu> X-UI-Message-Type: mail X-Priority: 3 X-Provags-ID: V03:K1:wZX8MBfeVVCXsVlFKySA3m7pjfB7tZjjGFOGAnifSMEvgrV2ap9/ncGQzAmlH5R+Kc2Mu g0WTs8+34/DfD7Gid78eHfJZyfVh4ahC4nO8GtLfa06pWOwkB0caPm2HDpNHWxsH1EObrBiG1wCW S7NaFWVVdg0qHbpBot4JamoJRXDCeCVJTzsJrB2P8lgpNeQ0ntyYfx5BPagHBq0axmo7iR2DVlAx sQ+pbcPcBCzBHE6Xs8IsZ5LikM9OTDhCoyXZRGFxh+dPD/0pRvkchPkZw2xonInM+GFeuXC6dPUk Kk= X-UI-Out-Filterresults: notjunk:1;V03:K0:RerHmSY5vwI=:xIGTFqTN95MeEGwjmdLrDY bG+JCOp0W2UMucACtwb5v1oVsK7RdQlWWUQRpeK0R4LECVjPSliX10qy7ZPEmUbmQD2O8VOCE CkDz4LUMgJPW15DLvUSqRc8xgqLOCSZqHeyNYZJ5TKUwqFQAQbWCAotsnNgn/ZT68HL0HOzVj aIacQjBSlV8cxh5QgcOMQC9PP0UxL/YgfJXsYhm/ko956y24G7yWIoA6jUliI/HaCCwk5n8Fo ge3vFz7FuXRxarDPsdSfjvz+ygWC+Et7upM+Kp1KKg8+AcTzcRZU3KNfgHpxpTuuhZm1TcvOJ wqAQpMqlubswSrmuSzW0HtvGUx3pH4j8Ih2FlRagecrksIrlbbmPbf8IShVnXebJmDYLxJAUE EXAoQCJ00EfBLzVpthLk3VbPb9BLfftR+mac58+g20Os+DLl3Q2dUEnVvveQv7PEv5gBALSKg dvNmXautUiXmT0fGvG41shOPuVtk57bgXuu4CckHStZKtsiIq3RN5bgq7PZCZUO2trHd0JRmd lzeW04WXePGUAMhpDGY4w9L+76OiIP+5SgspaLbNhMq26lYMrNgEsvUChRI42GRhDGTTyEGvn H8CO6BkBKx+yc= Received-SPF: pass client-ip=212.227.15.15; envelope-from=steve-humphreys@gmx.com; helo=mout.gmx.net X-Spam_score_int: -25 X-Spam_score: -2.6 X-Spam_bar: -- X-Spam_report: (-2.6 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.23 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-mx.org@gnu.org Original-Sender: "help-gnu-emacs" Xref: news.gmane.io gmane.emacs.help:128085 Archived-At: It is a very useful utility. It was "font-lock-keyword-face". Am trying to define a face that I can change, so that the face is updated at multiple locations, by simply changing the font lock face. But this makes emacs complain. (defface tface '(:inherit font-lock-keyword-face) "Colour typeface to use.") > Sent: Tuesday, February 16, 2021 at 3:55 AM > From: "Emanuel Berg via Users list for the GNU Emacs text editor" > To: help-gnu-emacs@gnu.org > Subject: Re: typeface for keyword > > steve-humphreys wrote: > > > I am using the following typeface, but want to change so > > that the face is the same as the typeface for keywords used > > in the major mode that is loaded after opening the file > > (e.g. texinfo, tex). > > > > (defface tfcdye > > '( (default :inherit bold) > > ( ((class color) (min-colors 88) (background light)) > > :foreground "#FF0000" ) > > ( ((class color) (min-colors 88) (background dark)) > > :foreground "#FF0000" ) > > (t :inherit font-lock-builtin-face) ) > > "Colour typeface for tex commands.") > > It is easier to do it the other way around. > > First find out what face you want to change. > > Move point to the place where you see the face. Then use use > this function: > > (defun what-face (pos) > (interactive "d") > (let ((face (or (get-char-property pos 'face) > (get-char-property pos 'read-cf-name) ))) > (message "face: %s" (or face "no face")) )) > > After that, set the face to whatever you like. > > https://dataswamp.org/~incal/emacs-init/face.el > > -- > underground experts united > http://user.it.uu.se/~embe8573 > https://dataswamp.org/~incal > > >