From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Drew Adams Newsgroups: gmane.emacs.help Subject: RE: Add a hook for color-theme switching Date: Fri, 1 Dec 2017 08:14:35 -0800 (PST) Message-ID: <2f961f6a-6279-445e-80de-d2eabdd43276@default> References: NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Trace: blaine.gmane.org 1512150020 17315 195.159.176.226 (1 Dec 2017 17:40:20 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Fri, 1 Dec 2017 17:40:20 +0000 (UTC) To: stardiviner , emacs-help Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Fri Dec 01 18:40:15 2017 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 1eKpIG-0003tm-AM for geh-help-gnu-emacs@m.gmane.org; Fri, 01 Dec 2017 18:40:08 +0100 Original-Received: from localhost ([::1]:59071 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eKpIN-0003b3-L5 for geh-help-gnu-emacs@m.gmane.org; Fri, 01 Dec 2017 12:40:15 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:58153) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eKnyi-0001xp-2s for help-gnu-emacs@gnu.org; Fri, 01 Dec 2017 11:16:58 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eKnxc-0005NE-U1 for help-gnu-emacs@gnu.org; Fri, 01 Dec 2017 11:15:51 -0500 Original-Received: from userp1040.oracle.com ([156.151.31.81]:45910) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1eKnxb-0005KU-Ul for help-gnu-emacs@gnu.org; Fri, 01 Dec 2017 11:14:44 -0500 Original-Received: from aserv0022.oracle.com (aserv0022.oracle.com [141.146.126.234]) by userp1040.oracle.com (Sentrion-MTA-4.3.2/Sentrion-MTA-4.3.2) with ESMTP id vB1GEbQG015427 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Fri, 1 Dec 2017 16:14:39 GMT Original-Received: from aserv0122.oracle.com (aserv0122.oracle.com [141.146.126.236]) by aserv0022.oracle.com (8.14.4/8.14.4) with ESMTP id vB1GEbnP016173 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Fri, 1 Dec 2017 16:14:37 GMT Original-Received: from abhmp0010.oracle.com (abhmp0010.oracle.com [141.146.116.16]) by aserv0122.oracle.com (8.14.4/8.14.4) with ESMTP id vB1GEaHI009582; Fri, 1 Dec 2017 16:14:37 GMT In-Reply-To: X-Priority: 3 X-Mailer: Oracle Beehive Extensions for Outlook 2.0.1.9.1 (1003210) [OL 16.0.4615.0 (x86)] X-Source-IP: aserv0022.oracle.com [141.146.126.234] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic] [fuzzy] X-Received-From: 156.151.31.81 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:115152 Archived-At: > When I start Emacs, the face ~hl-sexp-face~ is been set > by the Emacs initialized color-theme. Vanilla Emacs doesn't use color themes. It uses custom themes - the user theme by default. Color themes are available through library `color-theme.el'. Color themes: https://www.emacswiki.org/emacs/ColorThemes Custom themes: https://www.emacswiki.org/emacs/CustomThemes > Then I use package =3Dcircadian=3D to auto switch color-theme > or manually switch color-theme with command `disable-theme' > and `load-theme'. But this face `hl-sexp-face' is defined > already, usually not good for another switched color-theme. I don't understand the problem. Are you saying that when you switch to another theme (presumably a custom theme) the appearance of face `hl-sexp-face' changes? > So I hope there is a hook for switching color-theme like > `color-theme-switch-hook' etc. Do you mean that after you switch to another theme you want to invoke some code? What code would you invoke? Is the idea just to make face `hl-sexp-face' have or keep the appearance you want?