help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Emacs Themes


From: Pankaj Jangid
Subject: Re: Emacs Themes
Date: Fri, 20 Nov 2020 11:57:59 +0530
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (darwin)

Jean Louis <bugs@gnu.support> writes:

> * Jamie Beardslee <jdb@jamzattack.xyz> [2020-11-20 06:23]:
>> Christopher Dimech <dimech@gmx.com> writes:
>> > Have two themes and would like to cycle between the two using
>> > a keybinding.  How can I do it?
>> 
>> Here's how I'd do it:
>> 
>> (defun toggle-light-or-dark-theme ()
>>   (interactive)
>>   (if (member 'modus-operandi custom-enabled-themes)
>>       (progn
>>      (disable-theme 'modus-operandi)
>>      (load-theme 'modus-vivendi t))
>>     (disable-theme 'modus-vivendi)
>>     (load-theme 'modus-operandi t)))
>> 
>> And then of course you can bind it to a key with `global-set-key'.
>
> Nice and simple, I will use it for my favorite themes.

This snippet is from the documentation of modus themes. Nice
documentation as well. There are other useful snippets as well.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]