From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Jonas Damm Newsgroups: gmane.emacs.help Subject: Re: Advice for changing-theme-function for GNU/Linux system Date: Mon, 18 Jul 2022 11:05:56 +0200 Message-ID: <87tu7ebx67.fsf@jonas-damm.de> References: <87o7xnd545.fsf@jonas-damm.de> 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="37901"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: mu4e 1.8.3; emacs 28.1.90 Cc: help-gnu-emacs@gnu.org To: Yuri Khan Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Mon Jul 18 11:14:32 2022 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 1oDMpk-0009g8-4a for geh-help-gnu-emacs@m.gmane-mx.org; Mon, 18 Jul 2022 11:14:32 +0200 Original-Received: from localhost ([::1]:43104 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oDMph-0002qs-3W for geh-help-gnu-emacs@m.gmane-mx.org; Mon, 18 Jul 2022 05:14:29 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:36934) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oDMpE-0002qc-6N for help-gnu-emacs@gnu.org; Mon, 18 Jul 2022 05:14:00 -0400 Original-Received: from dd15330.kasserver.com ([85.13.136.159]:42110) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oDMpC-0005iH-5T for help-gnu-emacs@gnu.org; Mon, 18 Jul 2022 05:13:59 -0400 Original-Received: from x220t (unknown [185.220.70.69]) by dd15330.kasserver.com (Postfix) with ESMTPSA id 91B6875002BA; Mon, 18 Jul 2022 11:13:53 +0200 (CEST) In-reply-to: X-Spamd-Bar: --- Received-SPF: none client-ip=85.13.136.159; envelope-from=emails@jonas-damm.de; helo=dd15330.kasserver.com X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_NONE=0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.29 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:138517 Archived-At: Thank you, that put me in the right direction. I am having a little trouble though. I can successfully change the Firefox-Theme, without restarting the application, which is awesome. However my GTK applications like Evince do not change their theme. Not even by restarting them. I am running the xfsettingsd with the --sm-client-disable option and then change the theme with this command: xfconf-query -c xsettings -p /Net/ThemeName -s "Adwaita-dark"=20 Any Idea why that is? Maybe I need the gnome-settings-daemon? But this one seems to have been split into many small daemons, and i can't find documentation on how to use them.. Thanks, Jonas Yuri Khan writes: > On Mon, 18 Jul 2022 at 00:27, Jonas Damm wrote: > >> I wish to create my own function in emacs to switch my whole system from >> dark to light mode. >> >> I want to use the modus themes included in emacs, so i can toggle with >> modus-themes-toggle. >> >> However, I also want to change my systems GTK theme for other >> applications like Evince. So i have to change the file >> ~/.config/gtk-3.0/settings.ini and replace "Adwaita" with "Adwaita-dark" >> or the other way round. > > And restart every running application, and hope they preserve their > state, because themes set via gtk-3.0/settings.ini only take effect on > application startup. > > Alternatively, keep a settings daemon running. With one of these, you > can apply themes on the fly. If you=E2=80=99re using a desktop environment > such as GNOME, KDE or Xfce, you already have one. If not, Xfce=E2=80=99s > xfsettingsd is lightweight enough and can run without the whole DE. > (Start it on your session startup with an --sm-client-disable option.) > There is also something called Xsettingsd which is purportedly even > more lightweight.