Update Modus themes to version 4.1.0
* doc/misc/modus-themes.org: Update the manual. * etc/themes/modus-operandi-deuteranopia-theme.el: * etc/themes/modus-operandi-theme.el: * etc/themes/modus-operandi-tinted-theme.el: * etc/themes/modus-vivendi-deuteranopia-theme.el: * etc/themes/modus-vivendi-theme.el: * etc/themes/modus-vivendi-tinted-theme.el: Update theme files. * etc/themes/modus-themes.el: Update main file to the latest version. Detailed release notes here: <https://protesilaos.com/codelog/2023-02-22-modus-themes-4-1-0/>.
This commit is contained in:
parent
170b419df0
commit
48cc5c0604
8 changed files with 756 additions and 308 deletions
|
@ -4,9 +4,9 @@
|
|||
#+language: en
|
||||
#+options: ':t toc:nil author:t email:t num:t
|
||||
#+startup: content
|
||||
#+macro: stable-version 4.0.0
|
||||
#+macro: release-date 2023-01-01
|
||||
#+macro: development-version 4.1.0-dev
|
||||
#+macro: stable-version 4.1.0
|
||||
#+macro: release-date 2023-02-22
|
||||
#+macro: development-version 4.2.0-dev
|
||||
#+macro: file @@texinfo:@file{@@$1@@texinfo:}@@
|
||||
#+macro: space @@texinfo:@: @@
|
||||
#+macro: kbd @@texinfo:@kbd{@@$1@@texinfo:}@@
|
||||
|
@ -155,8 +155,8 @@ Emacs and of the themes across the years.
|
|||
:end:
|
||||
|
||||
In the following example, we are assuming that your Emacs files are
|
||||
stored in =~/.emacs.d= and that you want to place the Modus themes in
|
||||
=~/.emacs.d/modus-themes=.
|
||||
stored in {{{file(~/.emacs.d)}}} and that you want to place the Modus
|
||||
themes in {{{file(~/.emacs.d/modus-themes)}}}.
|
||||
|
||||
1. Get the source and store it in the desired path by running the
|
||||
following in the command line shell:
|
||||
|
@ -230,17 +230,17 @@ They are now ready to be used: [[#h:3f3c3728-1b34-437d-9d0c-b110f5b161a9][Enable
|
|||
:custom_id: h:e6268471-e847-4c9d-998f-49a83257b7f1
|
||||
:end:
|
||||
|
||||
From time to time, we receive bug reports pertaining to errors with byte
|
||||
compilation. These seldom have to do with faulty code in the themes: it
|
||||
might be a shortcoming of =package.el=, some regression in the current
|
||||
development target of Emacs, a misconfiguration in an otherwise exotic
|
||||
setup, and the like.
|
||||
From time to time, we receive bug reports pertaining to errors with
|
||||
byte compilation. These seldom have to do with faulty code in the
|
||||
themes: it might be a shortcoming of {{{file(package.el)}}}, some
|
||||
regression in the current development target of Emacs, a
|
||||
misconfiguration in an otherwise exotic setup, and the like.
|
||||
|
||||
The common solution with a stable version of Emacs is to:
|
||||
|
||||
1. Delete the =modus-themes= package.
|
||||
1. Delete the ~modus-themes~ package.
|
||||
2. Close the current Emacs session.
|
||||
3. Install the =modus-themes= again.
|
||||
3. Install the ~modus-themes~ again.
|
||||
|
||||
For those building Emacs directly from source, the solution may involve
|
||||
reverting to an earlier commit in emacs.git.
|
||||
|
@ -265,7 +265,7 @@ wrong.
|
|||
NOTE that Emacs can load multiple themes, which typically produces
|
||||
undesirable results and undoes the work of the designer. Use the
|
||||
~disable-theme~ command if you are trying other themes beside the
|
||||
Modus collection.
|
||||
Modus collection ([[#h:adb0c49a-f1f9-4690-868b-013a080eed68][Option for disabling other themes while loading Modus]]).
|
||||
|
||||
Users of the built-in themes cannot ~require~ the package as usual
|
||||
because there is no package to speak of. Instead, things are simpler
|
||||
|
@ -292,17 +292,18 @@ One can activate a theme with something like the following expression,
|
|||
replacing ~modus-operandi~ with their preferred Modus theme:
|
||||
|
||||
#+begin_src emacs-lisp
|
||||
(load-theme 'modus-operandi :no-confim)
|
||||
(load-theme 'modus-operandi :no-confirm)
|
||||
#+end_src
|
||||
|
||||
Changes to the available customization options must always be evaluated
|
||||
before loading a theme ([[#h:bf1c82f2-46c7-4eb2-ad00-dd11fdd8b53f][Customization Options]]). Reload a theme for
|
||||
new changes to take effect.
|
||||
|
||||
This is how a basic setup could look like:
|
||||
This is how a basic setup could look like ([[#h:b66b128d-54a4-4265-b59f-4d1ea2feb073][The require-theme for built-in Emacs themes]]):
|
||||
|
||||
#+begin_src emacs-lisp
|
||||
;;; For the built-in themes which cannot use `require'.
|
||||
(require-theme 'modus-themes)
|
||||
|
||||
;; Add all your customizations prior to loading the themes.
|
||||
(setq modus-themes-italic-constructs t
|
||||
|
@ -326,13 +327,41 @@ This is how a basic setup could look like:
|
|||
modus-themes-bold-constructs nil)
|
||||
|
||||
;; Load the theme of your choice.
|
||||
(load-theme 'modus-operandi :no-confim)
|
||||
(load-theme 'modus-operandi :no-confirm)
|
||||
|
||||
(define-key global-map (kbd "<f5>") #'modus-themes-toggle)
|
||||
#+end_src
|
||||
|
||||
[[#h:e979734c-a9e1-4373-9365-0f2cd36107b8][Sample configuration with and without use-package]].
|
||||
|
||||
** The ~require-theme~ for built-in Emacs themes
|
||||
:PROPERTIES:
|
||||
:CUSTOM_ID: h:b66b128d-54a4-4265-b59f-4d1ea2feb073
|
||||
:END:
|
||||
|
||||
The version of the Modus themes that is included in Emacs CANNOT use
|
||||
the standard ~require~. This is because the built-in themes are not
|
||||
included in the ~load-path~ (not my decision). The ~require-theme~
|
||||
function must be used in this case as a replacement. For example:
|
||||
|
||||
#+begin_src emacs-lisp
|
||||
(require-theme 'modus-themes)
|
||||
|
||||
;; All customizations here
|
||||
(setq modus-themes-bold-constructs t
|
||||
modus-themes-italic-constructs t)
|
||||
|
||||
;; Maybe define some palette overrides, such as by using our presets
|
||||
(setq modus-themes-common-palette-overrides
|
||||
modus-themes-preset-overrides-intense)
|
||||
|
||||
;; Load the theme of choice (built-in themes are always "safe" so they
|
||||
;; do not need the `no-require' argument of `load-theme').
|
||||
(load-theme 'modus-operandi)
|
||||
|
||||
(define-key global-map (kbd "<f5>") #'modus-themes-toggle)
|
||||
#+end_src
|
||||
|
||||
** Sample configuration with and without use-package
|
||||
:properties:
|
||||
:custom_id: h:e979734c-a9e1-4373-9365-0f2cd36107b8
|
||||
|
@ -349,54 +378,57 @@ package configurations in their setup. We use this as an example:
|
|||
#+begin_src emacs-lisp
|
||||
;;; For the built-in themes which cannot use `require'.
|
||||
(use-package emacs
|
||||
:init
|
||||
:config
|
||||
(require-theme 'modus-themes) ; `require-theme' is ONLY for the built-in Modus themes
|
||||
|
||||
;; Add all your customizations prior to loading the themes
|
||||
(setq modus-themes-italic-constructs t
|
||||
modus-themes-bold-constructs nil)
|
||||
:config
|
||||
|
||||
;; Maybe define some palette overrides, such as by using our presets
|
||||
(setq modus-themes-common-palette-overrides
|
||||
modus-themes-preset-overrides-intense)
|
||||
|
||||
;; Load the theme of your choice.
|
||||
(load-theme 'modus-operandi)
|
||||
:bind ("<f5>" . modus-themes-toggle))
|
||||
|
||||
(define-key global-map (kbd "<f5>") #'modus-themes-toggle))
|
||||
|
||||
|
||||
|
||||
;;; For packaged versions which must use `require'.
|
||||
(use-package modus-themes
|
||||
:ensure
|
||||
:init
|
||||
:ensure t
|
||||
:config
|
||||
;; Add all your customizations prior to loading the themes
|
||||
(setq modus-themes-italic-constructs t
|
||||
modus-themes-bold-constructs nil)
|
||||
:config
|
||||
|
||||
;; Maybe define some palette overrides, such as by using our presets
|
||||
(setq modus-themes-common-palette-overrides
|
||||
modus-themes-preset-overrides-intense)
|
||||
|
||||
;; Load the theme of your choice.
|
||||
(load-theme 'modus-operandi :no-confim)
|
||||
:bind ("<f5>" . modus-themes-toggle))
|
||||
(load-theme 'modus-operandi)
|
||||
|
||||
(define-key global-map (kbd "<f5>") #'modus-themes-toggle))
|
||||
#+end_src
|
||||
|
||||
The same without ~use-package~:
|
||||
|
||||
#+begin_src emacs-lisp
|
||||
;;; For the built-in themes which cannot use `require':
|
||||
;; Add all your customizations prior to loading the themes
|
||||
(setq modus-themes-italic-constructs t
|
||||
modus-themes-bold-constructs nil)
|
||||
|
||||
;; Load the theme of your choice:
|
||||
(load-theme 'modus-operandi) ;; OR (load-theme 'modus-vivendi)
|
||||
|
||||
(define-key global-map (kbd "<f5>") #'modus-themes-toggle)
|
||||
|
||||
|
||||
|
||||
;;; For packaged versions which must use `require':
|
||||
(require 'modus-themes)
|
||||
(require 'modus-themes) ; OR for the built-in themes: (require-theme 'modus-themes)
|
||||
|
||||
;; Add all your customizations prior to loading the themes
|
||||
(setq modus-themes-italic-constructs t
|
||||
modus-themes-bold-constructs nil)
|
||||
|
||||
;; Maybe define some palette overrides, such as by using our presets
|
||||
(setq modus-themes-common-palette-overrides
|
||||
modus-themes-preset-overrides-intense)
|
||||
|
||||
;; Load the theme of your choice:
|
||||
(load-theme 'modus-operandi :no-confim) ;; OR (load-theme 'modus-vivendi :no-confim)
|
||||
(load-theme 'modus-operandi :no-confirm)
|
||||
|
||||
(define-key global-map (kbd "<f5>") #'modus-themes-toggle)
|
||||
#+end_src
|
||||
|
@ -482,6 +514,7 @@ reloaded for changes to take effect.
|
|||
modus-themes-mixed-fonts t
|
||||
modus-themes-variable-pitch-ui nil
|
||||
modus-themes-custom-auto-reload t
|
||||
modus-themes-disable-other-themes t
|
||||
|
||||
;; Options for `modus-themes-prompts' are either nil (the
|
||||
;; default), or a list of properties that may include any of those
|
||||
|
@ -545,6 +578,38 @@ UI or related functions such as ~customize-set-variable~ and ~setopt~
|
|||
With a nil value, changes to user options have no further consequences:
|
||||
the user must manually reload the theme ([[#h:3f3c3728-1b34-437d-9d0c-b110f5b161a9][Enable and load]]).
|
||||
|
||||
** Option for disabling other themes while loading Modus
|
||||
:properties:
|
||||
:alt_title: Disable other themes
|
||||
:description: Determine whether loading a Modus themes disables all others
|
||||
:custom_id: h:adb0c49a-f1f9-4690-868b-013a080eed68
|
||||
:end:
|
||||
#+vindex: modus-themes-disable-other-themes
|
||||
|
||||
Brief: Disable all other themes when loading a Modus theme.
|
||||
|
||||
Symbol: ~modus-themes-disable-other-themes~ (=boolean= type)
|
||||
|
||||
Possible values:
|
||||
|
||||
1. ~nil~
|
||||
2. ~t~ (default)
|
||||
|
||||
When the value is non-nil, the commands ~modus-themes-toggle~ and
|
||||
~modus-themes-select~, as well as the ~modus-themes-load-theme~
|
||||
function, will disable all other themes while loading the specified
|
||||
Modus theme. This is done to ensure that Emacs does not blend two or
|
||||
more themes: such blends lead to awkward results that undermine the
|
||||
work of the designer.
|
||||
|
||||
When the value is nil, the aforementioned commands and function will
|
||||
only disable other themes within the Modus collection.
|
||||
|
||||
This option is provided because Emacs themes are not necessarily
|
||||
limited to colors/faces: they can consist of an arbitrary set of
|
||||
customizations. Users who use such customization bundles must set
|
||||
this variable to a nil value.
|
||||
|
||||
** Option for more bold constructs
|
||||
:properties:
|
||||
:alt_title: Bold constructs
|
||||
|
@ -707,14 +772,14 @@ Brief: Set the overall style of completion framework interfaces.
|
|||
Symbol: ~modus-themes-completions~ (=alist= type properties)
|
||||
|
||||
This affects Company, Corfu, Flx, Icomplete/Fido, Ido, Ivy, Orderless,
|
||||
Vertico. The value is an alist of expressions, each of which takes
|
||||
the form of =(KEY . LIST-OF-PROPERTIES)=. =KEY= is a symbol, while
|
||||
=PROPERTIES= is a list. Here is a sample, followed by a description
|
||||
of the particularities:
|
||||
Vertico, and the standard =*Completions*= buffer. The value is an
|
||||
alist of expressions, each of which takes the form of =(KEY . LIST-OF-PROPERTIES)=.
|
||||
=KEY= is a symbol, while =PROPERTIES= is a list. Here is a sample,
|
||||
followed by a description of the particularities:
|
||||
|
||||
#+begin_src emacs-lisp
|
||||
(setq modus-themes-completions
|
||||
'((matches . (extrabold background))
|
||||
'((matches . (extrabold underline))
|
||||
(selection . (semibold italic))))
|
||||
#+end_src
|
||||
|
||||
|
@ -984,8 +1049,6 @@ values and semantic color mappings:
|
|||
given named color from the palette, like =(heading-2 yellow-faint)=.
|
||||
Both elements of the list are symbols, though the ~cadr~ (value) can
|
||||
be a string that specifies a color, such as =(heading-2 "#354fcf")=.
|
||||
Semantic color mappings cannot be recursive: their value must be
|
||||
either a named color or a hexadecimal RGB value.
|
||||
|
||||
#+vindex: modus-themes-common-palette-overrides
|
||||
Both of those subsets can be overridden, thus refashioning the theme.
|
||||
|
@ -1186,9 +1249,18 @@ set their color to that of the underlying background.
|
|||
;; common overrides are best used for changes to semantic color
|
||||
;; mappings, as we show below.
|
||||
|
||||
;; Remove the border
|
||||
(setq modus-themes-common-palette-overrides
|
||||
'((border-mode-line-active unspecified)
|
||||
(border-mode-line-inactive unspecified)))
|
||||
|
||||
;; Keep the border but make it the same color as the background of the
|
||||
;; mode line (thus appearing borderless). The difference with the
|
||||
;; above is that this version is a bit thicker because the border are
|
||||
;; still there.
|
||||
(setq modus-themes-common-palette-overrides
|
||||
'((border-mode-line-active bg-mode-line-active)
|
||||
(border-mode-line-inactive bg-mode-line-inactive)))
|
||||
#+end_src
|
||||
|
||||
**** Make the active mode line colorful
|
||||
|
@ -1218,7 +1290,7 @@ have a blue mode line for ~modus-operandi~ and a red one for
|
|||
|
||||
;; Blue background, neutral foreground, intense blue border
|
||||
(setq modus-themes-common-palette-overrides
|
||||
'((bg-mode-line-active bg-blue)
|
||||
'((bg-mode-line-active bg-blue-intense)
|
||||
(fg-mode-line-active fg-main)
|
||||
(border-mode-line-active blue-intense)))
|
||||
|
||||
|
@ -1235,6 +1307,58 @@ have a blue mode line for ~modus-operandi~ and a red one for
|
|||
(border-mode-line-active bg-red-subtle)))
|
||||
#+end_src
|
||||
|
||||
**** Make the tab bar more or less colorful
|
||||
:PROPERTIES:
|
||||
:CUSTOM_ID: h:096658d7-a0bd-4a99-b6dc-9b20a20cda37
|
||||
:END:
|
||||
|
||||
This is one of our practical examples to override the semantic colors
|
||||
of the Modus themes ([[#h:df1199d8-eaba-47db-805d-6b568a577bf3][Stylistic variants using palette overrides]]).
|
||||
Here we show how to affect the colors of the built-in ~tab-bar-mode~
|
||||
and ~tab-line-mode~.
|
||||
|
||||
For consistent theme-wide results, consider changing the mode line,
|
||||
fringes, and line numbers. These are shown in other sections of this
|
||||
manual.
|
||||
|
||||
#+begin_src emacs-lisp
|
||||
;; These overrides are common to all Modus themes. We also provide
|
||||
;; theme-specific options, such as `modus-operandi-palette-overrides'.
|
||||
;;
|
||||
;; In general, the theme-specific overrides are better for overriding
|
||||
;; color values, such as redefining what `blue-faint' looks like. The
|
||||
;; common overrides are best used for changes to semantic color
|
||||
;; mappings, as we show below.
|
||||
|
||||
|
||||
;; Make the `tab-bar-mode' mode subtle while keepings its original
|
||||
;; gray aesthetic.
|
||||
(setq modus-themes-common-palette-overrides
|
||||
'((bg-tab-bar bg-main)
|
||||
(bg-tab-current bg-active)
|
||||
(bg-tab-other bg-dim)))
|
||||
|
||||
;; Like the above, but the current tab has a colorful background and
|
||||
;; the inactive tabs have a slightly more noticeable gray background.
|
||||
(setq modus-themes-common-palette-overrides
|
||||
'((bg-tab-bar bg-main)
|
||||
(bg-tab-current bg-cyan-intense)
|
||||
(bg-tab-other bg-inactive)))
|
||||
|
||||
;; Make the tabs colorful, using a monochromatic pattern (e.g. shades
|
||||
;; of cyan).
|
||||
(setq modus-themes-common-palette-overrides
|
||||
'((bg-tab-bar bg-cyan-nuanced)
|
||||
(bg-tab-current bg-cyan-intense)
|
||||
(bg-tab-other bg-cyan-subtle)))
|
||||
|
||||
;; Like the above, but with a dichromatic pattern (cyan and magenta).
|
||||
(setq modus-themes-common-palette-overrides
|
||||
'((bg-tab-bar bg-cyan-nuanced)
|
||||
(bg-tab-current bg-magenta-intense)
|
||||
(bg-tab-other bg-cyan-subtle)))
|
||||
#+end_src
|
||||
|
||||
**** Make the fringe invisible or another color
|
||||
:PROPERTIES:
|
||||
:CUSTOM_ID: h:c312dcac-36b6-4a1f-b1f5-ab1c9abe27b0
|
||||
|
@ -1352,7 +1476,8 @@ three different degrees of intensity.
|
|||
;; mappings, as we show below.
|
||||
|
||||
;; Add a nuanced background color to completion matches, while keeping
|
||||
;; their foreground intact.
|
||||
;; their foreground intact (foregrounds do not need to be specified in
|
||||
;; this case, but we do it for didactic purposes).
|
||||
(setq modus-themes-common-palette-overrides
|
||||
'((fg-completion-match-0 blue)
|
||||
(fg-completion-match-1 magenta-warmer)
|
||||
|
@ -1893,9 +2018,8 @@ do not show every possible permutation.
|
|||
(prose-todo red)
|
||||
(prose-verbatim magenta-warmer)))
|
||||
|
||||
;; Make code block delimiters use a shade of red, tone down
|
||||
;; =verbatim=, ~code~, and {{{macro}}}, and amplify the style of
|
||||
;; property drawers
|
||||
;; Make code block delimiters use a shade of red, tone down verbatim,
|
||||
;; code, and macro, and amplify the style of property drawers
|
||||
(setq modus-themes-common-palette-overrides
|
||||
'((prose-block red-faint)
|
||||
(prose-code fg-dim)
|
||||
|
@ -1995,6 +2119,8 @@ Here we show how to make the region respect the underlying text colors
|
|||
or how to make the background more/less intense while combining it
|
||||
with an appropriate foreground value.
|
||||
|
||||
[[#h:a5140c9c-18b2-45db-8021-38d0b5074116][Do not extend the region background]].
|
||||
|
||||
#+begin_src emacs-lisp
|
||||
;; These overrides are common to all Modus themes. We also provide
|
||||
;; theme-specific options, such as `modus-operandi-palette-overrides'.
|
||||
|
@ -2126,6 +2252,121 @@ this section we show how to affect the ~display-line-numbers-mode~.
|
|||
(bg-line-number-active bg-cyan-intense)))
|
||||
#+end_src
|
||||
|
||||
**** Make diffs use only a foreground
|
||||
:PROPERTIES:
|
||||
:CUSTOM_ID: h:b3761482-bcbf-4990-a41e-4866fb9dad15
|
||||
:END:
|
||||
|
||||
This is one of our practical examples to override the semantic colors
|
||||
of the Modus themes ([[#h:df1199d8-eaba-47db-805d-6b568a577bf3][Stylistic variants using palette overrides]]). In
|
||||
this section we show how to change diff buffers (e.g. in ~magit~) to
|
||||
only use color-coded text without any added background. What we
|
||||
basically do is to disable the applicable backgrounds and then
|
||||
intensify the foregrounds. Since the deuteranopia-optimized themes do
|
||||
not use the red-green color coding, we make an extra set of
|
||||
adjustments for them by overriding their palettes directly instead of
|
||||
just using the "common" overrides.
|
||||
|
||||
#+begin_src emacs-lisp
|
||||
;; Diffs with only foreground colours. Word-wise ("refined") diffs
|
||||
;; have a gray background to draw attention to themselves.
|
||||
(setq modus-themes-common-palette-overrides
|
||||
'((bg-added unspecified)
|
||||
(bg-added-faint unspecified)
|
||||
(bg-added-refine bg-inactive)
|
||||
(fg-added green)
|
||||
(fg-added-intense green-intense)
|
||||
|
||||
(bg-changed unspecified)
|
||||
(bg-changed-faint unspecified)
|
||||
(bg-changed-refine bg-inactive)
|
||||
(fg-changed yellow)
|
||||
(fg-changed-intense yellow-intense)
|
||||
|
||||
(bg-removed unspecified)
|
||||
(bg-removed-faint unspecified)
|
||||
(bg-removed-refine bg-inactive)
|
||||
(fg-removed red)
|
||||
(fg-removed-intense red-intense)
|
||||
|
||||
(bg-diff-context unspecified)))
|
||||
|
||||
;; Because deuteranopia cannot use the typical red-yellow-green
|
||||
;; combination, we need to arrange for a yellow-purple-blue sequence.
|
||||
;; Notice that the above covers the "common" overrides, so we do not
|
||||
;; need to reproduce the whole list of them.
|
||||
(setq modus-operandi-deuteranopia-palette-overrides
|
||||
'((fg-added blue)
|
||||
(fg-added-intense blue-intense)
|
||||
|
||||
(fg-changed magenta-cooler)
|
||||
(fg-changed-intense magenta-intense)
|
||||
|
||||
(fg-removed yellow-warmer)
|
||||
(fg-removed-intense yellow-intense)))
|
||||
|
||||
(setq modus-vivendi-deuteranopia-palette-overrides
|
||||
'((fg-added blue)
|
||||
(fg-added-intense blue-intense)
|
||||
|
||||
(fg-changed magenta-cooler)
|
||||
(fg-changed-intense magenta-intense)
|
||||
|
||||
(fg-removed yellow)
|
||||
(fg-removed-intense yellow-intense)))
|
||||
#+end_src
|
||||
|
||||
**** Make deuteranopia diffs red and blue instead of yellow and blue
|
||||
:PROPERTIES:
|
||||
:CUSTOM_ID: h:16389ea1-4cb6-4b18-9409-384324113541
|
||||
:END:
|
||||
|
||||
This is one of our practical examples to override the semantic colors
|
||||
of the Modus themes ([[#h:df1199d8-eaba-47db-805d-6b568a577bf3][Stylistic variants using palette overrides]]). In
|
||||
this section we show how to implement a red+blue color coding for
|
||||
diffs in the themes ~modus-operandi-deuteranopia~ and
|
||||
~modus-vivendi-deuteranopia~. As those themes are optimized for users
|
||||
with red-green color deficiency, they do not use the typical red+green
|
||||
color coding for diffs, defaulting instead to yellow+blue which are
|
||||
discernible. Users with deuteranomaly or, generally, those who like a
|
||||
different aesthetic, can use the following to make diffs use the
|
||||
red+yellow+blue color coding for removed, changed, and added lines
|
||||
respectively. This is achieved by overriding the "changed" and
|
||||
"removed" entries to use the colors of regular ~modus-operandi~ and
|
||||
~modus-vivendi~.
|
||||
|
||||
#+begin_src emacs-lisp
|
||||
(setq modus-operandi-deuteranopia-palette-overrides
|
||||
'((bg-changed "#ffdfa9")
|
||||
(bg-changed-faint "#ffefbf")
|
||||
(bg-changed-refine "#fac090")
|
||||
(bg-changed-fringe "#d7c20a")
|
||||
(fg-changed "#553d00")
|
||||
(fg-changed-intense "#655000")
|
||||
|
||||
(bg-removed "#ffd8d5")
|
||||
(bg-removed-faint "#ffe9e9")
|
||||
(bg-removed-refine "#f3b5af")
|
||||
(bg-removed-fringe "#d84a4f")
|
||||
(fg-removed "#8f1313")
|
||||
(fg-removed-intense "#aa2222")))
|
||||
|
||||
(setq modus-vivendi-deuteranopia-palette-overrides
|
||||
'((bg-changed "#363300")
|
||||
(bg-changed-faint "#2a1f00")
|
||||
(bg-changed-refine "#4a4a00")
|
||||
(bg-changed-fringe "#8a7a00")
|
||||
(fg-changed "#efef80")
|
||||
(fg-changed-intense "#c0b05f")
|
||||
|
||||
(bg-removed "#4f1119")
|
||||
(bg-removed-faint "#380a0f")
|
||||
(bg-removed-refine "#781a1f")
|
||||
(bg-removed-fringe "#b81a1f")
|
||||
(fg-removed "#ffbfbf")
|
||||
(fg-removed-intense "#ff9095")))
|
||||
#+end_src
|
||||
|
||||
* Advanced customization
|
||||
:properties:
|
||||
:custom_id: h:f4651d55-8c07-46aa-b52b-bed1e53463bb
|
||||
|
@ -2248,22 +2489,25 @@ xterm*color15: #ffffff
|
|||
#+cindex: Preview named colors or semantic color mappings
|
||||
|
||||
#+findex: modus-themes-list-colors
|
||||
The command ~modus-themes-list-colors~ uses minibuffer completion to
|
||||
select an item from the Modus themes and then produces a buffer with
|
||||
previews of its color palette entries. The buffer has a naming scheme
|
||||
that reflects the given choice, like =modus-operandi-list-colors= for
|
||||
the ~modus-operandi~ theme.
|
||||
|
||||
#+findex: modus-themes-list-colors-current
|
||||
The command ~modus-themes-list-colors~ prompts for a choice between
|
||||
=modus-operandi= and =modus-vivendi= to produce a help buffer that
|
||||
shows a preview of the named colors in the given theme's palette. The
|
||||
command ~modus-themes-list-colors-current~ skips the prompt, using the
|
||||
current Modus theme.
|
||||
The command ~modus-themes-list-colors-current~ skips the minibuffer
|
||||
selection process and just produces a preview for the current Modus
|
||||
theme.
|
||||
|
||||
When called with a prefix argument (=C-u= with the default key
|
||||
bindings), these commands will show a preview of the palette's
|
||||
semantic color mappings instead of the named colors.
|
||||
|
||||
In this context, "named colors" are entries that associate a symbol to
|
||||
a string color value, such as =(blue-warmer "#354fcf")=. Whereas
|
||||
"semantic color mappings" associate a named color to a symbol, like
|
||||
=(string blue-warmer)=, thus making the theme render all string
|
||||
constructs in the =blue-warmer= color value ([[#h:34c7a691-19bb-4037-8d2f-67a07edab150][Option for palette overrides]]).
|
||||
semantic color mappings instead of the named colors. In this context,
|
||||
"named colors" are entries that associate a symbol to a string color
|
||||
value, such as =(blue-warmer "#354fcf")=. Whereas "semantic color
|
||||
mappings" associate a named color to a symbol, like =(string
|
||||
blue-warmer)=, thus making the theme render all string constructs in
|
||||
the =blue-warmer= color value ([[#h:34c7a691-19bb-4037-8d2f-67a07edab150][Option for palette overrides]]).
|
||||
|
||||
#+findex: modus-themes-preview-colors
|
||||
#+findex: modus-themes-preview-colors-current
|
||||
|
@ -2314,12 +2558,70 @@ equivalent the themes provide.
|
|||
For a more elaborate design, it is better to inspect the source code of
|
||||
~modus-themes-toggle~ and relevant functions.
|
||||
|
||||
** Get a single color from the palette
|
||||
:PROPERTIES:
|
||||
:CUSTOM_ID: h:1cc552c1-5f5f-4a56-ae78-7b69e8512c4e
|
||||
:END:
|
||||
|
||||
[[#h:51ba3547-b8c8-40d6-ba5a-4586477fd4ae][Use theme colors in code with modus-themes-with-colors]].
|
||||
|
||||
#+findex: modus-themes-get-color-value
|
||||
The fuction ~modus-themes-get-color-value~ can be called from Lisp to
|
||||
return the value of a color from the active Modus theme palette. It
|
||||
takea a =COLOR= argument and an optional =OVERRIDES=.
|
||||
|
||||
=COLOR= is a symbol that represents a named color entry in the
|
||||
palette.
|
||||
|
||||
[[#h:f4d4b71b-2ca5-4c3d-b0b4-9bfd7aa7fb4d][Preview theme colors]].
|
||||
|
||||
If the value is the name of another color entry in the palette (so a
|
||||
mapping), this function recurs until it finds the underlying color
|
||||
value.
|
||||
|
||||
With an optional =OVERRIDES= argument as a non-nil value, it accounts
|
||||
for palette overrides. Else it reads only the default palette.
|
||||
|
||||
[[#h:34c7a691-19bb-4037-8d2f-67a07edab150][Option for palette overrides]].
|
||||
|
||||
With optional =THEME= as a symbol among ~modus-themes-items~, use the
|
||||
palette of that item. Else use the current Modus theme.
|
||||
|
||||
If =COLOR= is not present in the palette, this function returns the
|
||||
~unspecified~ symbol, which is safe when used as a face attribute's
|
||||
value.
|
||||
|
||||
An example with ~modus-operandi~ to show how this function behaves
|
||||
with/without overrides and when recursive mappings are introduced.
|
||||
|
||||
#+begin_src emacs-lisp
|
||||
;; Here we show the recursion of palette mappings. In general, it is
|
||||
;; better for the user to specify named colors to avoid possible
|
||||
;; confusion with their configuration, though those still work as
|
||||
;; expected.
|
||||
(setq modus-themes-common-palette-overrides
|
||||
'((cursor red)
|
||||
(fg-mode-line-active cursor)
|
||||
(border-mode-line-active fg-mode-line-active)))
|
||||
|
||||
;; Ignore the overrides and get the original value.
|
||||
(modus-themes-get-color-value 'border-mode-line-active)
|
||||
;; => "#5a5a5a"
|
||||
|
||||
;; Read from the overrides and deal with any recursion to find the
|
||||
;; underlying value.
|
||||
(modus-themes-get-color-value 'border-mode-line-active :overrides)
|
||||
;; => "#a60000"
|
||||
#+end_src
|
||||
|
||||
** Use theme colors in code with modus-themes-with-colors
|
||||
:properties:
|
||||
:custom_id: h:51ba3547-b8c8-40d6-ba5a-4586477fd4ae
|
||||
:end:
|
||||
#+cindex: Use colors from the palette anywhere
|
||||
|
||||
[[#h:1cc552c1-5f5f-4a56-ae78-7b69e8512c4e][Get a single color from the palette]].
|
||||
|
||||
Note that users most probably do not need the following. Just rely on
|
||||
the comprehensive overrides we provide ([[#h:34c7a691-19bb-4037-8d2f-67a07edab150][Option for palette overrides]]).
|
||||
|
||||
|
@ -2354,6 +2656,32 @@ We provide commands to inspect those ([[#h:f4d4b71b-2ca5-4c3d-b0b4-9bfd7aa7fb4d]
|
|||
Others sections in this manual show how to use the aforementioned
|
||||
macro ([[#h:f4651d55-8c07-46aa-b52b-bed1e53463bb][Advanced customization]]).
|
||||
|
||||
Because the ~modus-themes-with-colors~ will most likely be used to
|
||||
customize faces, note that any function that calls it must be run at
|
||||
startup after the theme loads. The same function must also be
|
||||
assigned to the ~modus-themes-after-load-theme-hook~ for its effects
|
||||
to persist and be updated when switching between Modus themes (e.g. to
|
||||
update the exact value of =blue-warmer= when toggling between
|
||||
~modus-operandi~ to ~modus-vivendi~.
|
||||
|
||||
** Do not extend the region background
|
||||
:PROPERTIES:
|
||||
:CUSTOM_ID: h:a5140c9c-18b2-45db-8021-38d0b5074116
|
||||
:END:
|
||||
|
||||
By the default, the background of the ~region~ face extends from the
|
||||
end of the line to the edge of the window. To limit it to the end of
|
||||
the line, we need to override the face's =:extend= attribute. Adding
|
||||
this to the Emacs configuration file will suffice:
|
||||
|
||||
#+begin_src emacs-lisp
|
||||
;; Do not extend `region' background past the end of the line.
|
||||
(custom-set-faces
|
||||
'(region ((t :extend nil))))
|
||||
#+end_src
|
||||
|
||||
[[#h:c8605d37-66e1-42aa-986e-d7514c3af6fe][Make the region preserve text colors, plus other styles]].
|
||||
|
||||
** Add padding to mode line
|
||||
:PROPERTIES:
|
||||
:CUSTOM_ID: h:5a0c58cc-f97f-429c-be08-927b9fbb0a9c
|
||||
|
@ -2981,9 +3309,9 @@ While we do provide ~modus-themes-toggle~ to manually switch between the
|
|||
themes, users may also set up their system to perform such a task
|
||||
automatically at sunrise and sunset.
|
||||
|
||||
This can be accomplished by specifying the coordinates of one's location
|
||||
using the built-in {{{file(solar.el)}}} and then configuring the =circadian=
|
||||
package:
|
||||
This can be accomplished by specifying the coordinates of one's
|
||||
location using the built-in {{{file(solar.el)}}} and then configuring
|
||||
the ~circadian~ package:
|
||||
|
||||
#+begin_src emacs-lisp
|
||||
(use-package solar ; built-in
|
||||
|
@ -2992,7 +3320,7 @@ package:
|
|||
calendar-longitude 33.36))
|
||||
|
||||
(use-package circadian ; you need to install this
|
||||
:ensure
|
||||
:ensure t
|
||||
:after solar
|
||||
:config
|
||||
(setq circadian-themes '((:sunrise . modus-operandi)
|
||||
|
@ -3022,9 +3350,10 @@ To remap the buffer's backdrop, we start with a function like this one:
|
|||
|
||||
#+begin_src emacs-lisp
|
||||
(defun my-pdf-tools-backdrop ()
|
||||
(face-remap-add-relative
|
||||
'default
|
||||
`(:background ,(modus-themes-color 'bg-alt))))
|
||||
(modus-themes-with-colors
|
||||
(face-remap-add-relative
|
||||
'default
|
||||
`(:background ,bg-dim))))
|
||||
|
||||
(add-hook 'pdf-tools-enabled-hook #'my-pdf-tools-backdrop)
|
||||
#+end_src
|
||||
|
@ -3043,9 +3372,10 @@ at something like the following, which builds on the above example:
|
|||
|
||||
#+begin_src emacs-lisp
|
||||
(defun my-pdf-tools-backdrop ()
|
||||
(face-remap-add-relative
|
||||
'default
|
||||
`(:background ,(modus-themes-color 'bg-alt))))
|
||||
(modus-themes-with-colors
|
||||
(face-remap-add-relative
|
||||
'default
|
||||
`(:background ,bg-dim))))
|
||||
|
||||
(defun my-pdf-tools-midnight-mode-toggle ()
|
||||
(when (derived-mode-p 'pdf-view-mode)
|
||||
|
@ -3154,11 +3484,12 @@ need to (provided they understand the implications).
|
|||
:CUSTOM_ID: h:2ef83a21-2f0a-441e-9634-473feb940743
|
||||
:END:
|
||||
|
||||
The =hl-todo= package provides the user option ~hl-todo-keyword-faces~:
|
||||
it specifies a pair of keyword and corresponding color value. The Modus
|
||||
themes configure that option in the interest of legibility. While this
|
||||
works for our purposes, users may still prefer to apply their custom
|
||||
values, in which case the following approach is necessary:
|
||||
The ~hl-todo~ package provides the user option
|
||||
~hl-todo-keyword-faces~: it specifies a pair of keyword and
|
||||
corresponding color value. The Modus themes configure that option in
|
||||
the interest of legibility. While this works for our purposes, users
|
||||
may still prefer to apply their custom values, in which case the
|
||||
following approach is necessary:
|
||||
|
||||
#+begin_src emacs-lisp
|
||||
(defun my-modus-themes-hl-todo-faces ()
|
||||
|
@ -3192,7 +3523,7 @@ otherwise the defaults are not always legible.
|
|||
:CUSTOM_ID: h:439c9e46-52e2-46be-b1dc-85841dd99671
|
||||
:END:
|
||||
|
||||
The =solaire-mode= package dims the background of what it considers
|
||||
The ~solaire-mode~ package dims the background of what it considers
|
||||
ancillary "UI" buffers, such as the minibuffer and Dired buffers. The
|
||||
Modus themes used to support Solaire on the premise that the user was
|
||||
(i) opting in to it, (ii) understood why certain buffers were more gray,
|
||||
|
@ -3222,7 +3553,7 @@ arrangement that compromises on our accessibility standards and/or
|
|||
hinders our efforts to provide the best possible experience while using
|
||||
the Modus themes.
|
||||
|
||||
As such, =solaire-mode= is not---and will not be---supported by the
|
||||
As such, ~solaire-mode~ is not---and will not be---supported by the
|
||||
Modus themes (or any other of my themes, for that matter). Users who
|
||||
want it must style the faces manually. Below is some sample code, based
|
||||
on what we cover at length elsewhere in this manual:
|
||||
|
@ -3305,6 +3636,7 @@ have lots of extensions, so the "full support" may not be 100% true…
|
|||
+ csv-mode
|
||||
+ ctrlf
|
||||
+ custom (what you get with {{{kbd(M-x customize)}}})
|
||||
- dashboard
|
||||
+ deadgrep
|
||||
+ deft
|
||||
+ devdocs
|
||||
|
@ -3612,11 +3944,12 @@ anew.
|
|||
:CUSTOM_ID: h:a195e37c-e58c-4148-b254-8ba1ed8a731a
|
||||
:END:
|
||||
|
||||
The =git-gutter= and =git-gutter-fr= packages default to drawing bitmaps
|
||||
for the indicators they display (e.g. bitmap of a plus sign for added
|
||||
lines). In Doom Emacs, these bitmaps are replaced with contiguous lines
|
||||
which may look nicer, but require a change to the foreground of the
|
||||
relevant faces to yield the desired color combinations.
|
||||
The ~git-gutter~ and ~git-gutter-fr~ packages default to drawing
|
||||
bitmaps for the indicators they display (e.g. bitmap of a plus sign
|
||||
for added lines). In Doom Emacs, these bitmaps are replaced with
|
||||
contiguous lines which may look nicer, but require a change to the
|
||||
foreground of the relevant faces to yield the desired color
|
||||
combinations.
|
||||
|
||||
Since this is Doom-specific, we urge users to apply changes in their
|
||||
local setup. Below is some sample code, based on what we cover at
|
||||
|
@ -3668,7 +4001,7 @@ If the above does not work, try this instead:
|
|||
:END:
|
||||
|
||||
Depending on your build of Emacs and/or the environment it runs in,
|
||||
multiline comments in PHP with the =php-mode= package use the
|
||||
multiline comments in PHP with the ~php-mode~ package use the
|
||||
~font-lock-doc-face~ instead of ~font-lock-comment-face~.
|
||||
|
||||
This seems to make all comments use the appropriate face:
|
||||
|
@ -3797,10 +4130,10 @@ For example:
|
|||
:CUSTOM_ID: h:24bab397-dcb2-421d-aa6e-ec5bd622b913
|
||||
:END:
|
||||
|
||||
The =highlight-parentheses= package provides contextual coloration of
|
||||
The ~highlight-parentheses~ package provides contextual coloration of
|
||||
surrounding parentheses, highlighting only those which are around the
|
||||
point. The package expects users to customize the applicable colors on
|
||||
their own by configuring certain variables.
|
||||
point. The package expects users to customize the applicable colors
|
||||
on their own by configuring certain variables.
|
||||
|
||||
To make the Modus themes work as expected with this, we need to use some
|
||||
of the techniques that are discussed at length in the various
|
||||
|
@ -3984,10 +4317,11 @@ implements an alternative to the typical coloration of code. Instead of
|
|||
highlighting the syntactic constructs, it applies color to different
|
||||
levels of depth in the code structure.
|
||||
|
||||
As =prism.el= offers a broad range of customizations, we cannot style
|
||||
it directly at the theme level: that would run contrary to the spirit
|
||||
of the package. Instead, we may offer preset color schemes. Those
|
||||
should offer a starting point for users to adapt to their needs.
|
||||
As {{{file(prism.el)}}} offers a broad range of customizations, we
|
||||
cannot style it directly at the theme level: that would run contrary
|
||||
to the spirit of the package. Instead, we may offer preset color
|
||||
schemes. Those should offer a starting point for users to adapt to
|
||||
their needs.
|
||||
|
||||
In the following code snippets, we employ the ~modus-themes-with-colors~
|
||||
macro: [[#h:51ba3547-b8c8-40d6-ba5a-4586477fd4ae][Use theme colors in code with modus-themes-with-colors]].
|
||||
|
@ -4146,10 +4480,10 @@ Consult the doc string of ~shr-use-colors~.
|
|||
:end:
|
||||
#+cindex: Fonts in EWW, Elfeed, Ement, and SHR
|
||||
|
||||
By default, packages that build on top of the Simple HTML Remember (=shr=)
|
||||
use proportionately spaced fonts. This is controlled by the user option
|
||||
~shr-use-fonts~, which is set to non-~nil~ by default. To use the standard
|
||||
font instead, set that variable to nil.
|
||||
By default, packages that build on top of the Simple HTML Remember
|
||||
(~shr~) use proportionately spaced fonts. This is controlled by the
|
||||
user option ~shr-use-fonts~, which is set to non-~nil~ by default. To
|
||||
use the standard font instead, set that variable to nil.
|
||||
|
||||
[[#h:defcf4fc-8fa8-4c29-b12e-7119582cc929][Font configurations for Org and others]].
|
||||
|
||||
|
@ -4166,9 +4500,10 @@ This is a non-exhaustive list.
|
|||
:custom_id: h:8e636056-356c-4ca7-bc78-ebe61031f585
|
||||
:end:
|
||||
|
||||
The =ement.el= library by Adam Porter (also known as "alphapapa") defaults
|
||||
to a method of colorizing usernames in a rainbow style. This is
|
||||
controlled by the user option ~ement-room-prism~ and can be disabled with:
|
||||
The {{{file(ement.el)}}} library by Adam Porter (also known as
|
||||
"alphapapa") defaults to a method of colorizing usernames in a rainbow
|
||||
style. This is controlled by the user option ~ement-room-prism~ and
|
||||
can be disabled with:
|
||||
|
||||
#+begin_src emacs-lisp
|
||||
(setq ement-room-prism nil)
|
||||
|
@ -4182,7 +4517,7 @@ slightly below our nominal target. Try this instead:
|
|||
(setq ement-room-prism-minimum-contrast 7)
|
||||
#+end_src
|
||||
|
||||
With regard to fonts, Ement depends on =shr= ([[#h:e6c5451f-6763-4be7-8fdb-b4706a422a4c][Note on SHR fonts]]).
|
||||
With regard to fonts, Ement depends on ~shr~ ([[#h:e6c5451f-6763-4be7-8fdb-b4706a422a4c][Note on SHR fonts]]).
|
||||
|
||||
Since we are here, here is an excerpt from Ement's source code:
|
||||
|
||||
|
@ -4271,7 +4606,7 @@ those buttons. Disabling the logo fixes the problem:
|
|||
|
||||
The built-in ~goto-address-mode~ uses heuristics to identify URLs and
|
||||
email addresses in the current buffer. It then applies a face to them
|
||||
to change their style. Some packages, such as =notmuch=, use this
|
||||
to change their style. Some packages, such as ~notmuch~, use this
|
||||
minor-mode automatically.
|
||||
|
||||
The faces are not declared with ~defface~, meaning that it is better
|
||||
|
@ -4768,41 +5103,43 @@ The Modus themes are a collective effort. Every bit of work matters.
|
|||
Le Gouguec, Koen van Greevenbroek, Kostadin Ninev, Madhavan
|
||||
Krishnan, Manuel Giraud, Markus Beppler, Matthew Stevenson, Mauro
|
||||
Aranda, Nicolas De Jaeghere, Paul David, Philip Kaludercic, Pierre
|
||||
Téchoueyres, Rudolf Adamkovič, Stephen Gildea, Shreyas Ragavan,
|
||||
Stefan Kangas, Utkarsh Singh, Vincent Murphy, Xinglu Chen, Yuanchen
|
||||
Xie, okamsn.
|
||||
Téchoueyres, Rudolf Adamkovič, Sergey Nichiporchik, Stephen Gildea,
|
||||
Shreyas Ragavan, Stefan Kangas, Utkarsh Singh, Vincent Murphy,
|
||||
Xinglu Chen, Yuanchen Xie, okamsn.
|
||||
|
||||
+ Ideas and user feedback :: Aaron Jensen, Adam Porter, Adam Spiers,
|
||||
Adrian Manea, Aleksei Pirogov, Alex Griffin, Alex Koen, Alex
|
||||
Peitsinis, Alexey Shmalko, Alok Singh, Anders Johansson, André
|
||||
Alexandre Gomes, Andrew Tropin, Antonio Hernández Blas, Arif Rezai,
|
||||
Augusto Stoffel, Basil L.{{{space()}}} Contovounesios, Burgess
|
||||
Chang, Charlotte Van Petegem, Christian Tietze, Christopher Dimech,
|
||||
Christopher League, Damien Cassou, Daniel Mendler, Dario
|
||||
Gjorgjevski, David Edmondson, Davor Rotim, Divan Santana, Eliraz
|
||||
Kedmi, Emanuele Michele Alberto Monterosso, Farasha Euker, Feng Shu,
|
||||
Gautier Ponsinet, Gerry Agbobada, Gianluca Recchia, Gonçalo Marrafa,
|
||||
Guilherme Semente, Gustavo Barros, Hörmetjan Yiltiz, Ilja Kocken,
|
||||
Iris Garcia, Ivan Popovych, James Ferguson, Jeremy Friesen, Jerry
|
||||
Zhang, Johannes Grødem, John Haman, Jonas Collberg, Jorge Morais,
|
||||
Joshua O'Connor, Julio C. Villasante, Kenta Usami, Kevin Fleming,
|
||||
Kévin Le Gouguec, Kevin Kainan Li, Kostadin Ninev, Laith Bahodi, Len
|
||||
Trigg, Lennart C. Karssen, Luis Miguel Castañeda, Magne Hov, Manuel
|
||||
Uberti, Mark Bestley, Mark Burton, Mark Simpson, Markus Beppler,
|
||||
Augusto Stoffel, Basil L.{{{space()}}} Contovounesios, Bernd
|
||||
Rellermeyer, Burgess Chang, Charlotte Van Petegem, Christian Tietze,
|
||||
Christopher Dimech, Christopher League, Damien Cassou, Daniel
|
||||
Mendler, Dario Gjorgjevski, David Edmondson, Davor Rotim, Divan
|
||||
Santana, Eliraz Kedmi, Emanuele Michele Alberto Monterosso, Farasha
|
||||
Euker, Feng Shu, Gautier Ponsinet, Gerry Agbobada, Gianluca Recchia,
|
||||
Gonçalo Marrafa, Guilherme Semente, Gustavo Barros, Hörmetjan
|
||||
Yiltiz, Ilja Kocken, Imran Khan, Iris Garcia, Ivan Popovych, James
|
||||
Ferguson, Jeremy Friesen, Jerry Zhang, Johannes Grødem, John Haman,
|
||||
Jonas Collberg, Jorge Morais, Joshua O'Connor, Julio C. Villasante,
|
||||
Kenta Usami, Kevin Fleming, Kévin Le Gouguec, Kevin Kainan Li,
|
||||
Kostadin Ninev, Laith Bahodi, Len Trigg, Lennart C. Karssen, Luis
|
||||
Miguel Castañeda, Magne Hov, Manuel Giraud, Manuel Uberti, Mark
|
||||
Bestley, Mark Burton, Mark Simpson, Marko Kocic, Markus Beppler,
|
||||
Matt Armstrong, Matthias Fuchs, Mattias Engdegård, Mauro Aranda,
|
||||
Maxime Tréca, Michael Goldenberg, Morgan Smith, Morgan Willcock,
|
||||
Murilo Pereira, Nicky van Foreest, Nicolas De Jaeghere, Pablo
|
||||
Stafforini, Paul Poloskov, Pengji Zhang, Pete Kazmier, Peter Wu,
|
||||
Philip Kaludercic, Pierre Téchoueyres, Przemysław Kryger, Robert
|
||||
Hepple, Roman Rudakov, Ryan Phillips, Rytis Paškauskas, Rudolf
|
||||
Adamkovič, Sam Kleinman, Samuel Culpepper, Saša Janiška, Shreyas
|
||||
Ragavan, Simon Pugnet, Tassilo Horn, Thibaut Verron, Thomas
|
||||
Heartman, Togan Muftuoglu, Tony Zorman, Trey Merkley, Tomasz
|
||||
Hołubowicz, Toon Claes, Uri Sharf, Utkarsh Singh, Vincent Foley. As
|
||||
well as users: Ben, CsBigDataHub1, Emacs Contrib, Eugene, Fourchaux,
|
||||
Fredrik, Moesasji, Nick, Summer Emacs, TheBlob42, Trey, bepolymathe,
|
||||
bit9tream, derek-upham, doolio, fleimgruber, gitrj95, iSeeU, jixiuf,
|
||||
okamsn, pRot0ta1p, soaringbird, tumashu, wakamenod.
|
||||
Hepple, Roman Rudakov, Russell Sim, Ryan Phillips, Rytis Paškauskas,
|
||||
Rudolf Adamkovič, Sam Kleinman, Samuel Culpepper, Saša Janiška,
|
||||
Shreyas Ragavan, Simon Pugnet, Tassilo Horn, Thanos Apollo, Thibaut
|
||||
Verron, Thomas Heartman, Togan Muftuoglu, Tony Zorman, Trey Merkley,
|
||||
Tomasz Hołubowicz, Toon Claes, Uri Sharf, Utkarsh Singh, Vincent
|
||||
Foley, Zoltan Kiraly. As well as users: Ben, CsBigDataHub1, Emacs
|
||||
Contrib, Eugene, Fourchaux, Fredrik, Moesasji, Nick, Summer Emacs,
|
||||
TheBlob42, TitusMu, Trey, bepolymathe, bit9tream, bangedorrunt,
|
||||
derek-upham, doolio, fleimgruber, gitrj95, iSeeU, jixiuf, okamsn,
|
||||
pRot0ta1p, soaringbird, tumashu, wakamenod.
|
||||
|
||||
+ Packaging :: Basil L.{{{space()}}} Contovounesios, Eli Zaretskii,
|
||||
Glenn Morris, Mauro Aranda, Richard Stallman, Stefan Kangas (core
|
||||
|
|
|
@ -83,7 +83,7 @@ standard).")
|
|||
(yellow-faint "#624416")
|
||||
(yellow-intense "#808000")
|
||||
(blue "#0031a9")
|
||||
(blue-warmer "#354fcf")
|
||||
(blue-warmer "#3548cf")
|
||||
(blue-cooler "#0000b0")
|
||||
(blue-faint "#003497")
|
||||
(blue-intense "#0000ff")
|
||||
|
@ -157,7 +157,7 @@ standard).")
|
|||
(bg-completion "#c0deff")
|
||||
(bg-hover "#97dfed")
|
||||
(bg-hover-secondary "#f5d0a0")
|
||||
(bg-hl-line "#d0d6ec")
|
||||
(bg-hl-line "#dae5ec")
|
||||
(bg-region "#bdbdbd")
|
||||
(fg-region "#000000")
|
||||
|
||||
|
@ -182,26 +182,28 @@ standard).")
|
|||
|
||||
;;; Diffs
|
||||
|
||||
(bg-added "#d5d5ff")
|
||||
(bg-added "#d5d7ff")
|
||||
(bg-added-faint "#e6e6ff")
|
||||
(bg-added-refine "#b5b5ef")
|
||||
(bg-added-intense "#579acc")
|
||||
(fg-added "#333399")
|
||||
(fg-added-intense "#3333cc")
|
||||
(bg-added-refine "#babcef")
|
||||
(bg-added-fringe "#275acc")
|
||||
(fg-added "#303099")
|
||||
(fg-added-intense "#0303cc")
|
||||
|
||||
(bg-changed "#eecfdf")
|
||||
(bg-changed-faint "#f0dde5")
|
||||
(bg-changed-refine "#e0b0d0")
|
||||
(bg-changed-intense "#9f7abf")
|
||||
(bg-changed-fringe "#9f6ab0")
|
||||
(fg-changed "#6f1343")
|
||||
(fg-changed-intense "#7f1f5f")
|
||||
(fg-changed-intense "#7f0f9f")
|
||||
|
||||
(bg-removed "#fff585")
|
||||
(bg-removed-faint "#f2f2bb")
|
||||
(bg-removed-refine "#f0e068")
|
||||
(bg-removed-intense "#d7c20a")
|
||||
(bg-removed "#f4f099")
|
||||
(bg-removed-faint "#f6f6b7")
|
||||
(bg-removed-refine "#f0e56f")
|
||||
(bg-removed-fringe "#c0b200")
|
||||
(fg-removed "#553d00")
|
||||
(fg-removed-intense "#655000")
|
||||
(fg-removed-intense "#7f6f00")
|
||||
|
||||
(bg-diff-context "#f3f3f3")
|
||||
|
||||
;;; Paren match
|
||||
|
||||
|
@ -380,10 +382,7 @@ as a symbol and the latter as a string.
|
|||
|
||||
Semantic color mappings have the form (MAPPING-NAME COLOR-NAME)
|
||||
with both as symbols. The latter is a named color that already
|
||||
exists in the palette and is associated with a HEX-VALUE.
|
||||
|
||||
Semantic color mappings cannot be recursive: their value must be
|
||||
either COLOR-NAME or HEX-VALUE.")
|
||||
exists in the palette and is associated with a HEX-VALUE.")
|
||||
|
||||
(defcustom modus-operandi-deuteranopia-palette-overrides nil
|
||||
"Overrides for `modus-operandi-deuteranopia-palette'.
|
||||
|
|
|
@ -81,7 +81,7 @@ which corresponds to a minimum contrast in relative luminance of
|
|||
(yellow-faint "#624416")
|
||||
(yellow-intense "#808000")
|
||||
(blue "#0031a9")
|
||||
(blue-warmer "#354fcf")
|
||||
(blue-warmer "#3548cf")
|
||||
(blue-cooler "#0000b0")
|
||||
(blue-faint "#003497")
|
||||
(blue-intense "#0000ff")
|
||||
|
@ -155,7 +155,7 @@ which corresponds to a minimum contrast in relative luminance of
|
|||
(bg-completion "#c0deff")
|
||||
(bg-hover "#94d4ff")
|
||||
(bg-hover-secondary "#f5d0a0")
|
||||
(bg-hl-line "#d0d6ec")
|
||||
(bg-hl-line "#dae5ec")
|
||||
(bg-region "#bdbdbd")
|
||||
(fg-region "#000000")
|
||||
|
||||
|
@ -183,24 +183,26 @@ which corresponds to a minimum contrast in relative luminance of
|
|||
(bg-added "#c1f2d1")
|
||||
(bg-added-faint "#d8f8e1")
|
||||
(bg-added-refine "#aee5be")
|
||||
(bg-added-intense "#8cca8c")
|
||||
(bg-added-fringe "#6cc06c")
|
||||
(fg-added "#005000")
|
||||
(fg-added-intense "#006700")
|
||||
|
||||
(bg-changed "#ffdfa9")
|
||||
(bg-changed-faint "#ffefbf")
|
||||
(bg-changed-refine "#fac090")
|
||||
(bg-changed-intense "#d7c20a")
|
||||
(bg-changed-fringe "#d7c20a")
|
||||
(fg-changed "#553d00")
|
||||
(fg-changed-intense "#655000")
|
||||
|
||||
(bg-removed "#ffd8d5")
|
||||
(bg-removed-faint "#ffe9e9")
|
||||
(bg-removed-refine "#f3b5af")
|
||||
(bg-removed-intense "#d84a4f")
|
||||
(bg-removed-fringe "#d84a4f")
|
||||
(fg-removed "#8f1313")
|
||||
(fg-removed-intense "#aa2222")
|
||||
|
||||
(bg-diff-context "#f3f3f3")
|
||||
|
||||
;;; Paren match
|
||||
|
||||
(bg-paren-match "#5fcfff")
|
||||
|
@ -378,10 +380,7 @@ as a symbol and the latter as a string.
|
|||
|
||||
Semantic color mappings have the form (MAPPING-NAME COLOR-NAME)
|
||||
with both as symbols. The latter is a named color that already
|
||||
exists in the palette and is associated with a HEX-VALUE.
|
||||
|
||||
Semantic color mappings cannot be recursive: their value must be
|
||||
either COLOR-NAME or HEX-VALUE.")
|
||||
exists in the palette and is associated with a HEX-VALUE.")
|
||||
|
||||
(defcustom modus-operandi-palette-overrides nil
|
||||
"Overrides for `modus-operandi-palette'.
|
||||
|
|
|
@ -80,7 +80,7 @@ which corresponds to a minimum contrast in relative luminance of
|
|||
(yellow-faint "#624416")
|
||||
(yellow-intense "#808000")
|
||||
(blue "#0031a9")
|
||||
(blue-warmer "#354fcf")
|
||||
(blue-warmer "#3548cf")
|
||||
(blue-cooler "#0000b0")
|
||||
(blue-faint "#003497")
|
||||
(blue-intense "#0000ff")
|
||||
|
@ -121,12 +121,12 @@ which corresponds to a minimum contrast in relative luminance of
|
|||
(bg-magenta-subtle "#ffddff")
|
||||
(bg-cyan-subtle "#bfefff")
|
||||
|
||||
(bg-red-nuanced "#fff1f0")
|
||||
(bg-green-nuanced "#ecf7ed")
|
||||
(bg-yellow-nuanced "#fff3da")
|
||||
(bg-blue-nuanced "#f3f3ff")
|
||||
(bg-magenta-nuanced "#fdf0ff")
|
||||
(bg-cyan-nuanced "#ebf6fa")
|
||||
(bg-red-nuanced "#ffe8f0")
|
||||
(bg-green-nuanced "#e0f5e0")
|
||||
(bg-yellow-nuanced "#f9ead0")
|
||||
(bg-blue-nuanced "#ebebff")
|
||||
(bg-magenta-nuanced "#f6e7ff")
|
||||
(bg-cyan-nuanced "#e1f3fc")
|
||||
|
||||
;;; Uncommon accent backgrounds
|
||||
|
||||
|
@ -182,24 +182,26 @@ which corresponds to a minimum contrast in relative luminance of
|
|||
(bg-added "#c3ebc1")
|
||||
(bg-added-faint "#dcf8d1")
|
||||
(bg-added-refine "#acd6a5")
|
||||
(bg-added-intense "#8cca8c")
|
||||
(bg-added-fringe "#6cc06c")
|
||||
(fg-added "#005000")
|
||||
(fg-added-intense "#006700")
|
||||
|
||||
(bg-changed "#ffdfa9")
|
||||
(bg-changed-faint "#ffefbf")
|
||||
(bg-changed-refine "#fac090")
|
||||
(bg-changed-intense "#d7c20a")
|
||||
(bg-changed-fringe "#c0b200")
|
||||
(fg-changed "#553d00")
|
||||
(fg-changed-intense "#655000")
|
||||
|
||||
(bg-removed "#f4d0cf")
|
||||
(bg-removed-faint "#ffe9e5")
|
||||
(bg-removed-refine "#f3b5a7")
|
||||
(bg-removed-intense "#d84a4f")
|
||||
(bg-removed-fringe "#d84a4f")
|
||||
(fg-removed "#8f1313")
|
||||
(fg-removed-intense "#aa2222")
|
||||
|
||||
(bg-diff-context "#efe9df")
|
||||
|
||||
;;; Paren match
|
||||
|
||||
(bg-paren-match "#7fdfcf")
|
||||
|
@ -377,10 +379,7 @@ as a symbol and the latter as a string.
|
|||
|
||||
Semantic color mappings have the form (MAPPING-NAME COLOR-NAME)
|
||||
with both as symbols. The latter is a named color that already
|
||||
exists in the palette and is associated with a HEX-VALUE.
|
||||
|
||||
Semantic color mappings cannot be recursive: their value must be
|
||||
either COLOR-NAME or HEX-VALUE.")
|
||||
exists in the palette and is associated with a HEX-VALUE.")
|
||||
|
||||
(defcustom modus-operandi-tinted-palette-overrides nil
|
||||
"Overrides for `modus-operandi-tinted-palette'.
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
;; Maintainer: Modus-Themes Development <~protesilaos/modus-themes@lists.sr.ht>
|
||||
;; URL: https://git.sr.ht/~protesilaos/modus-themes
|
||||
;; Mailing-List: https://lists.sr.ht/~protesilaos/modus-themes
|
||||
;; Version: 4.0.1
|
||||
;; Version: 4.1.0
|
||||
;; Package-Requires: ((emacs "27.1"))
|
||||
;; Keywords: faces, theme, accessibility
|
||||
|
||||
|
@ -88,6 +88,14 @@ cover the blue-cyan-magenta side of the spectrum."
|
|||
:version "30.1"
|
||||
:group 'modus-themes-faces))
|
||||
|
||||
(dolist (color '(red green yellow blue magenta cyan))
|
||||
(custom-declare-face
|
||||
(intern (format "modus-themes-nuanced-%s" color))
|
||||
nil (format "Nuanced %s background." color)
|
||||
:package-version '(modus-themes . "4.1.0")
|
||||
:version "30.1"
|
||||
:group 'modus-themes-faces))
|
||||
|
||||
(dolist (color '(red green yellow blue magenta cyan))
|
||||
(custom-declare-face
|
||||
(intern (format "modus-themes-subtle-%s" color))
|
||||
|
@ -329,6 +337,29 @@ Will set SYM to VAL, and reload the current theme, unless
|
|||
(theme (modus-themes--current-theme)))
|
||||
(modus-themes-load-theme theme))))
|
||||
|
||||
(defcustom modus-themes-disable-other-themes t
|
||||
"Disable all other themes when loading a Modus theme.
|
||||
|
||||
When the value is non-nil, the commands `modus-themes-toggle' and
|
||||
`modus-themes-select', as well as the `modus-themes-load-theme'
|
||||
function, will disable all other themes while loading the
|
||||
specified Modus theme. This is done to ensure that Emacs does
|
||||
not blend two or more themes: such blends lead to awkward results
|
||||
that undermine the work of the designer.
|
||||
|
||||
When the value is nil, the aforementioned commands and function
|
||||
will only disable other themes within the Modus collection.
|
||||
|
||||
This option is provided because Emacs themes are not necessarily
|
||||
limited to colors/faces: they can consist of an arbitrary set of
|
||||
customizations. Users who use such customization bundles must
|
||||
set this variable to a nil value."
|
||||
:group 'modus-themes
|
||||
:package-version '(modus-themes . "4.1.0")
|
||||
:version "30.1"
|
||||
:type 'boolean
|
||||
:link '(info-link "(modus-themes) Disable other themes"))
|
||||
|
||||
(defconst modus-themes-items
|
||||
'( modus-operandi modus-vivendi
|
||||
modus-operandi-tinted modus-vivendi-tinted
|
||||
|
@ -615,13 +646,14 @@ is non-nil. While quote/verse blocks require setting
|
|||
"Control the style of completion user interfaces.
|
||||
|
||||
This affects Company, Corfu, Flx, Icomplete/Fido, Ido, Ivy,
|
||||
Orderless, Vertico. The value is an alist of expressions, each
|
||||
of which takes the form of (KEY . LIST-OF-PROPERTIES). KEY is a
|
||||
symbol, while PROPERTIES is a list. Here is a sample, followed
|
||||
by a description of the particularities:
|
||||
Orderless, Vertico, and the standard *Completions* buffer. The
|
||||
value is an alist of expressions, each of which takes the form
|
||||
of (KEY . LIST-OF-PROPERTIES). KEY is a symbol, while PROPERTIES
|
||||
is a list. Here is a sample, followed by a description of the
|
||||
particularities:
|
||||
|
||||
(setq modus-themes-completions
|
||||
(quote ((matches . (extrabold background))
|
||||
(quote ((matches . (extrabold underline))
|
||||
(selection . (semibold italic)))))
|
||||
|
||||
The `matches' key refers to the highlighted characters that
|
||||
|
@ -682,6 +714,12 @@ Is the same as:
|
|||
(cons :tag "Selection"
|
||||
(const selection)
|
||||
(set :tag "Style of selection" :greedy t
|
||||
,modus-themes--weight-widget
|
||||
(const :tag "Italic font (oblique or slanted forms)" italic)
|
||||
(const :tag "Underline" underline)))
|
||||
(cons :tag "Fallback for both matches and selection"
|
||||
(const t)
|
||||
(set :tag "Style of both matches and selection" :greedy t
|
||||
,modus-themes--weight-widget
|
||||
(const :tag "Italic font (oblique or slanted forms)" italic)
|
||||
(const :tag "Underline" underline))))
|
||||
|
@ -759,7 +797,25 @@ represents."
|
|||
:group 'modus-themes
|
||||
:package-version '(modus-themes . "4.0.0")
|
||||
:version "30.1"
|
||||
:type '(repeat (list symbol (choice symbol string))) ; TODO 2022-12-18: Refine overrides' :type
|
||||
:type '(repeat (list symbol (choice symbol string)))
|
||||
;; ;; NOTE 2023-01-07: The following is a functioning version of the
|
||||
;; ;; intended :type. However, I think the Custom UI is really
|
||||
;; ;; awkward for this specific case. Maybe the generic type I have
|
||||
;; ;; above is better, as it encourages the user to write out the
|
||||
;; ;; code and read the manual. Counter-arguments are welcome.
|
||||
;;
|
||||
;; :type `(repeat (list (radio :tag "Palette key to override"
|
||||
;; ,@(mapcar (lambda (x)
|
||||
;; (list 'const x))
|
||||
;; (mapcar #'car (modus-themes--current-theme-palette))))
|
||||
;; (choice :tag "Value to assign" :value unspecified
|
||||
;; (const :tag "`unspecified' (remove the original color)" unspecified)
|
||||
;; (string :tag "String with color name (e.g. \"gray50\") or hex RGB (e.g. \"#123456\")"
|
||||
;; :match-inline (color-supported-p val))
|
||||
;; (radio :tag "Palette key to map to"
|
||||
;; ,@(mapcar (lambda (x)
|
||||
;; (list 'const x))
|
||||
;; (mapcar #'car (modus-themes--current-theme-palette)))))))
|
||||
:set #'modus-themes--set-option
|
||||
:initialize #'custom-initialize-default
|
||||
:link '(info-link "(modus-themes) Palette overrides"))
|
||||
|
@ -1020,7 +1076,8 @@ C1 and C2 are color values written in hexadecimal RGB."
|
|||
|
||||
(defun modus-themes--current-theme ()
|
||||
"Return first enabled Modus theme."
|
||||
(car (modus-themes--list-enabled-themes)))
|
||||
(car (or (modus-themes--list-enabled-themes)
|
||||
(modus-themes--list-known-themes))))
|
||||
|
||||
(defun modus-themes--palette-symbol (theme &optional overrides)
|
||||
"Return THEME palette as a symbol.
|
||||
|
@ -1052,13 +1109,71 @@ overrides."
|
|||
(modus-themes--palette-value theme))
|
||||
(user-error "No enabled Modus theme could be found")))
|
||||
|
||||
(defun modus-themes--disable-themes ()
|
||||
"Disable themes per `modus-themes-disable-other-themes'."
|
||||
(mapc #'disable-theme
|
||||
(if modus-themes-disable-other-themes
|
||||
custom-enabled-themes
|
||||
(modus-themes--list-known-themes))))
|
||||
|
||||
(defun modus-themes-load-theme (theme)
|
||||
"Load THEME while disabling other Modus themes.
|
||||
Run `modus-themes-after-load-theme-hook'."
|
||||
(mapc #'disable-theme (modus-themes--list-known-themes))
|
||||
"Load THEME while disabling other themes.
|
||||
|
||||
Which themes are disabled is determined by the user option
|
||||
`modus-themes-disable-other-themes'.
|
||||
|
||||
Run the `modus-themes-after-load-theme-hook' as the final step
|
||||
after loading the THEME."
|
||||
(modus-themes--disable-themes)
|
||||
(load-theme theme :no-confirm)
|
||||
(run-hooks 'modus-themes-after-load-theme-hook))
|
||||
|
||||
(defun modus-themes--retrieve-palette-value (color palette)
|
||||
"Return COLOR from PALETTE.
|
||||
Use recursion until COLOR is retrieved as a string. Refrain from
|
||||
doing so if the value of COLOR is not a key in the PALETTE.
|
||||
|
||||
Return `unspecified' if the value of COLOR cannot be determined.
|
||||
This symbol is accepted by faces and is thus harmless.
|
||||
|
||||
This function is used in the macros `modus-themes-theme',
|
||||
`modus-themes-with-colors'."
|
||||
(let ((value (car (alist-get color palette))))
|
||||
(cond
|
||||
((or (stringp value)
|
||||
(eq value 'unspecified))
|
||||
value)
|
||||
((and (symbolp value)
|
||||
(memq value (mapcar #'car palette)))
|
||||
(modus-themes--retrieve-palette-value value palette))
|
||||
(t
|
||||
'unspecified))))
|
||||
|
||||
(defun modus-themes-get-color-value (color &optional overrides theme)
|
||||
"Return color value of named COLOR for current Modus theme.
|
||||
|
||||
COLOR is a symbol that represents a named color entry in the
|
||||
palette.
|
||||
|
||||
If the value is the name of another color entry in the
|
||||
palette (so a mapping), recur until you find the underlying color
|
||||
value.
|
||||
|
||||
With optional OVERRIDES as a non-nil value, account for palette
|
||||
overrides. Else use the default palette.
|
||||
|
||||
With optional THEME as a symbol among `modus-themes-items', use
|
||||
the palette of that item. Else use the current Modus theme.
|
||||
|
||||
If COLOR is not present in the palette, return the `unspecified'
|
||||
symbol, which is safe when used as a face attribute's value."
|
||||
(if-let* ((palette (if theme
|
||||
(modus-themes--palette-value theme overrides)
|
||||
(modus-themes--current-theme-palette overrides)))
|
||||
(value (modus-themes--retrieve-palette-value color palette)))
|
||||
value
|
||||
'unspecified))
|
||||
|
||||
;;;; Commands
|
||||
|
||||
(make-obsolete 'modus-themes-load-themes nil "4.0.0")
|
||||
|
@ -1080,7 +1195,8 @@ Run `modus-themes-after-load-theme-hook'."
|
|||
;;;###autoload
|
||||
(defun modus-themes-select (theme)
|
||||
"Load a Modus THEME using minibuffer completion.
|
||||
Run `modus-themes-after-load-theme-hook' after loading the theme."
|
||||
Run `modus-themes-after-load-theme-hook' after loading the theme.
|
||||
Disable other themes per `modus-themes-disable-other-themes'."
|
||||
(interactive (list (modus-themes--select-prompt)))
|
||||
(modus-themes-load-theme theme))
|
||||
|
||||
|
@ -1100,7 +1216,8 @@ If `modus-themes-to-toggle' does not specify two Modus themes,
|
|||
prompt with completion for a theme among our collection (this is
|
||||
practically the same as the `modus-themes-select' command).
|
||||
|
||||
Run `modus-themes-after-load-theme-hook' after loading the theme."
|
||||
Run `modus-themes-after-load-theme-hook' after loading the theme.
|
||||
Disable other themes per `modus-themes-disable-other-themes'."
|
||||
(interactive)
|
||||
(if-let* ((themes (modus-themes--toggle-theme-p))
|
||||
(one (car themes))
|
||||
|
@ -1114,15 +1231,12 @@ Run `modus-themes-after-load-theme-hook' after loading the theme."
|
|||
"Render colors in BUFFER from THEME for `modus-themes-list-colors'.
|
||||
Optional MAPPINGS changes the output to only list the semantic
|
||||
color mappings of the palette, instead of its named colors."
|
||||
(let* ((current (modus-themes--palette-value theme :overrides))
|
||||
(let* ((current-palette (modus-themes--palette-value theme mappings))
|
||||
(palette (if mappings
|
||||
(seq-remove (lambda (cell)
|
||||
(or (stringp (cadr cell))
|
||||
(eq (cadr cell) 'unspecified)))
|
||||
current)
|
||||
(seq-remove (lambda (cell)
|
||||
(symbolp (cadr cell)))
|
||||
current)))
|
||||
(stringp (cadr cell)))
|
||||
current-palette)
|
||||
current-palette))
|
||||
(current-buffer buffer)
|
||||
(current-theme theme))
|
||||
(with-help-window buffer
|
||||
|
@ -1136,28 +1250,27 @@ color mappings of the palette, instead of its named colors."
|
|||
(insert " ")
|
||||
(dolist (cell palette)
|
||||
(let* ((name (car cell))
|
||||
(color (cadr cell))
|
||||
(mapping (if mappings
|
||||
(cadr (seq-find (lambda (c)
|
||||
(eq (car c) color))
|
||||
current))
|
||||
color))
|
||||
(fg (readable-foreground-color mapping))
|
||||
(pad (make-string 5 ?\s)))
|
||||
(color (modus-themes-get-color-value name mappings theme))
|
||||
(pad (make-string 10 ?\s))
|
||||
(fg (if (eq color 'unspecified)
|
||||
(progn
|
||||
(readable-foreground-color (modus-themes-get-color-value 'bg-main nil theme))
|
||||
(setq pad (make-string 6 ?\s)))
|
||||
(readable-foreground-color color))))
|
||||
(let ((old-point (point)))
|
||||
(insert (format "%s %s" mapping pad))
|
||||
(put-text-property old-point (point) 'face `( :foreground ,mapping)))
|
||||
(insert (format "%s %s" color pad))
|
||||
(put-text-property old-point (point) 'face `( :foreground ,color)))
|
||||
(let ((old-point (point)))
|
||||
(insert (format " %s %s %s\n" mapping pad name))
|
||||
(insert (format " %s %s %s\n" color pad name))
|
||||
(put-text-property old-point (point)
|
||||
'face `( :background ,mapping
|
||||
'face `( :background ,color
|
||||
:foreground ,fg
|
||||
:extend t)))
|
||||
;; We need this to properly render the last line.
|
||||
(insert " ")))
|
||||
(setq-local revert-buffer-function
|
||||
(lambda (_ignore-auto _noconfirm)
|
||||
(modus-themes--list-colors-render current-buffer current-theme)))))))
|
||||
(modus-themes--list-colors-render current-buffer current-theme mappings)))))))
|
||||
|
||||
(defvar modus-themes--list-colors-prompt-history '()
|
||||
"Minibuffer history for `modus-themes--list-colors-prompt'.")
|
||||
|
@ -1319,7 +1432,7 @@ Optional OL is the color of an overline."
|
|||
(eq modus-themes-org-blocks 'greyscale))))
|
||||
(list :inherit 'modus-themes-fixed-pitch
|
||||
:background (if gray bg 'unspecified)
|
||||
:foreground fg
|
||||
:foreground (if gray 'unspecified fg)
|
||||
:extend (if gray t 'unspecified))))
|
||||
|
||||
(defun modus-themes--completion-line (bg)
|
||||
|
@ -1408,6 +1521,13 @@ FG and BG are the main colors."
|
|||
`(modus-themes-fg-cyan-cooler ((,c :foreground ,cyan-cooler)))
|
||||
`(modus-themes-fg-cyan-faint ((,c :foreground ,cyan-faint)))
|
||||
`(modus-themes-fg-cyan-intense ((,c :foreground ,cyan-intense)))
|
||||
;;;;; nuanced colored backgrounds
|
||||
`(modus-themes-nuanced-red ((,c :background ,bg-red-nuanced :extend t)))
|
||||
`(modus-themes-nuanced-green ((,c :background ,bg-green-nuanced :extend t)))
|
||||
`(modus-themes-nuanced-yellow ((,c :background ,bg-yellow-nuanced :extend t)))
|
||||
`(modus-themes-nuanced-blue ((,c :background ,bg-blue-nuanced :extend t)))
|
||||
`(modus-themes-nuanced-magenta ((,c :background ,bg-magenta-nuanced :extend t)))
|
||||
`(modus-themes-nuanced-cyan ((,c :background ,bg-cyan-nuanced :extend t)))
|
||||
;;;;; subtle colored backgrounds
|
||||
`(modus-themes-subtle-red ((,c :background ,bg-red-subtle :foreground ,fg-main)))
|
||||
`(modus-themes-subtle-green ((,c :background ,bg-green-subtle :foreground ,fg-main)))
|
||||
|
@ -1494,6 +1614,7 @@ FG and BG are the main colors."
|
|||
`(header-line-highlight ((,c :inherit highlight)))
|
||||
`(help-argument-name ((,c :inherit modus-themes-slant :foreground ,variable)))
|
||||
`(help-key-binding ((,c :inherit modus-themes-key-binding)))
|
||||
`(highlight ((,c :background ,bg-hover :foreground ,fg-main)))
|
||||
`(homoglyph ((,c :foreground ,warning)))
|
||||
`(ibuffer-locked-buffer ((,c :foreground ,warning)))
|
||||
`(icon-button ((,c :inherit modus-themes-button)))
|
||||
|
@ -1509,7 +1630,7 @@ FG and BG are the main colors."
|
|||
`(read-multiple-choice-face ((,c :inherit (bold modus-themes-mark-alt))))
|
||||
`(rectangle-preview ((,c :inherit secondary-selection)))
|
||||
`(region ((,c :background ,bg-region :foreground ,fg-region)))
|
||||
`(secondary-selection ((,c :background ,bg-hover-secondary)))
|
||||
`(secondary-selection ((,c :background ,bg-hover-secondary :foreground ,fg-main)))
|
||||
`(separator-line ((,c :underline ,bg-active)))
|
||||
`(shadow ((,c :foreground ,fg-dim)))
|
||||
`(success ((,c :inherit bold :foreground ,info)))
|
||||
|
@ -1519,7 +1640,7 @@ FG and BG are the main colors."
|
|||
`(button ((,c :background ,bg-link :foreground ,fg-link :underline ,underline-link)))
|
||||
`(link ((,c :inherit button)))
|
||||
`(link-visited ((,c :background ,bg-link-visited :foreground ,fg-link-visited :underline ,underline-link-visited)))
|
||||
`(tooltip ((,c :background ,bg-active)))
|
||||
`(tooltip ((,c :background ,bg-active :foreground ,fg-main)))
|
||||
;;;;; agda2-mode
|
||||
`(agda2-highlight-bound-variable-face ((,c :inherit font-lock-variable-name-face)))
|
||||
`(agda2-highlight-catchall-clause-face ((,c :background ,bg-inactive)))
|
||||
|
@ -1778,7 +1899,7 @@ FG and BG are the main colors."
|
|||
`(company-scrollbar-bg ((,c :background ,bg-active)))
|
||||
`(company-scrollbar-fg ((,c :background ,fg-main)))
|
||||
`(company-template-field ((,c :background ,bg-active)))
|
||||
`(company-tooltip ((,c :background ,bg-inactive)))
|
||||
`(company-tooltip ((,c :background ,bg-dim)))
|
||||
`(company-tooltip-annotation ((,c :inherit completions-annotations)))
|
||||
`(company-tooltip-common ((,c :inherit company-echo-common)))
|
||||
`(company-tooltip-deprecated ((,c :inherit company-tooltip :strike-through t)))
|
||||
|
@ -1796,16 +1917,18 @@ FG and BG are the main colors."
|
|||
`(compilation-mode-line-exit ((,c :inherit bold)))
|
||||
`(compilation-mode-line-fail ((,c :inherit bold :foreground ,modeline-err)))
|
||||
`(compilation-mode-line-run ((,c :inherit bold :foreground ,modeline-warning)))
|
||||
`(compilation-warning ((,c :inherit warning)))
|
||||
`(compilation-warning ((,c :inherit modus-themes-bold :foreground ,warning)))
|
||||
;;;;; completions
|
||||
`(completions-annotations ((,c :inherit modus-themes-slant :foreground ,docstring)))
|
||||
`(completions-common-part ((,c :inherit modus-themes-completion-match-0)))
|
||||
`(completions-first-difference ((,c :inherit modus-themes-completion-match-1)))
|
||||
;;;;; consult
|
||||
`(consult-async-split ((,c :inherit error)))
|
||||
`(consult-file ((,c :inherit modus-themes-bold :foreground ,info)))
|
||||
`(consult-key ((,c :inherit modus-themes-key-binding)))
|
||||
`(consult-imenu-prefix ((,c :inherit shadow)))
|
||||
`(consult-line-number ((,c :inherit shadow)))
|
||||
`(consult-line-number-prefix ((,c :inherit shadow)))
|
||||
;;;;; corfu
|
||||
`(corfu-current ((,c :inherit modus-themes-completion-selected)))
|
||||
`(corfu-bar ((,c :background ,fg-dim)))
|
||||
|
@ -1838,7 +1961,7 @@ FG and BG are the main colors."
|
|||
`(csv-separator-face ((,c :foreground ,red-intense)))
|
||||
;;;;; ctrlf
|
||||
`(ctrlf-highlight-active ((,c :inherit modus-themes-search-current)))
|
||||
`(ctrlf-highlight-line ((,c :inherit highlight)))
|
||||
`(ctrlf-highlight-line ((,c :background ,bg-hl-line :extend t)))
|
||||
`(ctrlf-highlight-passive ((,c :inherit modus-themes-search-lazy)))
|
||||
;;;;; custom (M-x customize)
|
||||
`(custom-button ((,c :inherit modus-themes-button)))
|
||||
|
@ -1858,6 +1981,9 @@ FG and BG are the main colors."
|
|||
`(custom-group-tag ((,c :inherit bold :foreground ,builtin)))
|
||||
`(custom-group-tag-1 ((,c :inherit bold :foreground ,constant)))
|
||||
`(custom-variable-tag ((,c :inherit bold :foreground ,variable)))
|
||||
;;;;; dashboard
|
||||
`(dashboard-heading ((,c :foreground ,name)))
|
||||
`(dashboard-items-face (( ))) ; use the underlying style of all-the-icons
|
||||
;;;;; deadgrep
|
||||
`(deadgrep-filename-face ((,c :inherit bold :foreground ,name)))
|
||||
`(deadgrep-match-face ((,c :inherit match)))
|
||||
|
@ -1879,18 +2005,18 @@ FG and BG are the main colors."
|
|||
`(dictionary-word-definition-face (( )))
|
||||
`(dictionary-word-entry-face ((,c :inherit font-lock-comment-face)))
|
||||
;;;;; diff-hl
|
||||
`(diff-hl-change ((,c :background ,bg-changed-intense)))
|
||||
`(diff-hl-delete ((,c :background ,bg-removed-intense)))
|
||||
`(diff-hl-insert ((,c :background ,bg-added-intense)))
|
||||
`(diff-hl-change ((,c :background ,bg-changed-fringe)))
|
||||
`(diff-hl-delete ((,c :background ,bg-removed-fringe)))
|
||||
`(diff-hl-insert ((,c :background ,bg-added-fringe)))
|
||||
`(diff-hl-reverted-hunk-highlight ((,c :background ,fg-main :foreground ,bg-main)))
|
||||
;;;;; diff-mode
|
||||
`(diff-added ((,c :background ,bg-added)))
|
||||
`(diff-changed ((,c :background ,bg-changed :extend t)))
|
||||
`(diff-added ((,c :background ,bg-added :foreground ,fg-added)))
|
||||
`(diff-changed ((,c :background ,bg-changed :foreground ,fg-changed :extend t)))
|
||||
`(diff-changed-unspecified ((,c :inherit diff-changed)))
|
||||
`(diff-removed ((,c :background ,bg-removed)))
|
||||
`(diff-refine-added ((,c :background ,bg-added-refine)))
|
||||
`(diff-refine-changed ((,c :background ,bg-changed-refine)))
|
||||
`(diff-refine-removed ((,c :background ,bg-removed-refine)))
|
||||
`(diff-removed ((,c :background ,bg-removed :foreground ,fg-removed)))
|
||||
`(diff-refine-added ((,c :background ,bg-added-refine :foreground ,fg-added)))
|
||||
`(diff-refine-changed ((,c :background ,bg-changed-refine :foreground ,fg-changed)))
|
||||
`(diff-refine-removed ((,c :background ,bg-removed-refine :foreground ,fg-removed)))
|
||||
`(diff-indicator-added ((,c :inherit diff-added :foreground ,fg-added-intense)))
|
||||
`(diff-indicator-changed ((,c :inherit diff-changed :foreground ,fg-changed-intense)))
|
||||
`(diff-indicator-removed ((,c :inherit diff-removed :foreground ,fg-removed-intense)))
|
||||
|
@ -2001,18 +2127,18 @@ FG and BG are the main colors."
|
|||
`(doom-modeline-urgent ((,c :inherit bold-italic :foreground ,modeline-err)))
|
||||
`(doom-modeline-warning ((,c :inherit warning)))
|
||||
;;;;; ediff
|
||||
`(ediff-current-diff-A ((,c :inherit diff-removed)))
|
||||
`(ediff-current-diff-A ((,c :background ,bg-removed :foreground ,fg-removed)))
|
||||
`(ediff-current-diff-Ancestor ((,c :background ,bg-region))) ; TODO 2022-11-29: Needs review
|
||||
`(ediff-current-diff-B ((,c :inherit diff-added)))
|
||||
`(ediff-current-diff-C ((,c :inherit diff-changed)))
|
||||
`(ediff-even-diff-A ((,c :background ,bg-dim)))
|
||||
`(ediff-even-diff-Ancestor ((,c :background ,bg-dim)))
|
||||
`(ediff-even-diff-B ((,c :background ,bg-dim)))
|
||||
`(ediff-even-diff-C ((,c :background ,bg-dim)))
|
||||
`(ediff-fine-diff-A ((,c :inherit diff-refine-removed)))
|
||||
`(ediff-fine-diff-Ancestor ((,c :inherit diff-refine-cyan)))
|
||||
`(ediff-fine-diff-B ((,c :inherit diff-refine-added)))
|
||||
`(ediff-fine-diff-C ((,c :inherit diff-refine-changed)))
|
||||
`(ediff-current-diff-B ((,c :background ,bg-added :foreground ,fg-added)))
|
||||
`(ediff-current-diff-C ((,c :background ,bg-changed :foreground ,fg-changed)))
|
||||
`(ediff-even-diff-A ((,c :background ,bg-diff-context)))
|
||||
`(ediff-even-diff-Ancestor ((,c :background ,bg-diff-context)))
|
||||
`(ediff-even-diff-B ((,c :background ,bg-diff-context)))
|
||||
`(ediff-even-diff-C ((,c :background ,bg-diff-context)))
|
||||
`(ediff-fine-diff-A ((,c :background ,bg-removed-refine :foreground ,fg-removed)))
|
||||
`(ediff-fine-diff-Ancestor ((,c :inherit modus-themes-subtle-cyan)))
|
||||
`(ediff-fine-diff-B ((,c :background ,bg-added-refine :foreground ,fg-added)))
|
||||
`(ediff-fine-diff-C ((,c :background ,bg-changed-refine :foreground ,fg-changed)))
|
||||
`(ediff-odd-diff-A ((,c :inherit ediff-even-diff-A)))
|
||||
`(ediff-odd-diff-Ancestor ((,c :inherit ediff-even-diff-Ancestor)))
|
||||
`(ediff-odd-diff-B ((,c :inherit ediff-even-diff-B)))
|
||||
|
@ -2025,7 +2151,7 @@ FG and BG are the main colors."
|
|||
`(ein:markdowncell-input-area-face (( )))
|
||||
`(ein:notification-tab-normal ((,c :underline t)))
|
||||
;;;;; eglot
|
||||
`(eglot-mode-line ((,c :inherit bold :foreground ,modeline-info)))
|
||||
`(eglot-mode-line ((,c :inherit modus-themes-bold :foreground ,modeline-info)))
|
||||
;;;;; el-search
|
||||
`(el-search-highlight-in-prompt-face ((,c :inherit italic)))
|
||||
`(el-search-match ((,c :inherit modus-themes-search-current)))
|
||||
|
@ -2236,15 +2362,15 @@ FG and BG are the main colors."
|
|||
`(git-commit-overlong-summary ((,c :inherit warning)))
|
||||
`(git-commit-summary ((,c :inherit bold :foreground ,blue)))
|
||||
;;;;; git-gutter
|
||||
`(git-gutter:added ((,c :background ,bg-added-intense)))
|
||||
`(git-gutter:deleted ((,c :background ,bg-removed-intense)))
|
||||
`(git-gutter:modified ((,c :background ,bg-changed-intense)))
|
||||
`(git-gutter:added ((,c :background ,bg-added-fringe)))
|
||||
`(git-gutter:deleted ((,c :background ,bg-removed-fringe)))
|
||||
`(git-gutter:modified ((,c :background ,bg-changed-fringe)))
|
||||
`(git-gutter:separator ((,c :inherit modus-themes-intense-cyan)))
|
||||
`(git-gutter:unchanged ((,c :inherit modus-themes-intense-magenta)))
|
||||
;;;;; git-gutter-fr
|
||||
`(git-gutter-fr:added ((,c :background ,bg-added-intense)))
|
||||
`(git-gutter-fr:deleted ((,c :background ,bg-removed-intense)))
|
||||
`(git-gutter-fr:modified ((,c :background ,bg-changed-intense)))
|
||||
`(git-gutter-fr:added ((,c :background ,bg-added-fringe)))
|
||||
`(git-gutter-fr:deleted ((,c :background ,bg-removed-fringe)))
|
||||
`(git-gutter-fr:modified ((,c :background ,bg-changed-fringe)))
|
||||
;;;;; git-rebase
|
||||
`(git-rebase-comment-hash ((,c :inherit (bold font-lock-comment-face) :foreground ,identifier)))
|
||||
`(git-rebase-comment-heading ((,c :inherit (bold font-lock-comment-face))))
|
||||
|
@ -2377,7 +2503,6 @@ FG and BG are the main colors."
|
|||
:background "white" :foreground "#af6400" :inverse-video t)
|
||||
(((class color) (min-colors 88) (background dark))
|
||||
:background "black" :foreground "#faea00" :inverse-video t)))
|
||||
`(highlight ((,c :background ,bg-hover)))
|
||||
`(highlight-changes ((,c :foreground ,warning :underline nil)))
|
||||
`(highlight-changes-delete ((,c :foreground ,err :underline t)))
|
||||
`(hl-line ((,c :background ,bg-hl-line :extend t)))
|
||||
|
@ -2551,8 +2676,8 @@ FG and BG are the main colors."
|
|||
`(kaocha-runner-success-face ((,c :inherit success)))
|
||||
`(kaocha-runner-warning-face ((,c :inherit warning)))
|
||||
;;;;; keycast
|
||||
`(keycast-command ((,c :inherit bold :foreground ,keybind)))
|
||||
`(keycast-key ((,c :background ,keybind :foreground ,bg-main :box ,keybind)))
|
||||
`(keycast-command ((,c :inherit bold)))
|
||||
`(keycast-key ((,c :background ,keybind :foreground ,bg-main)))
|
||||
;;;;; ledger-mode
|
||||
`(ledger-font-auto-xact-face ((,c :inherit font-lock-builtin-face)))
|
||||
`(ledger-font-account-name-face ((,c :foreground ,name)))
|
||||
|
@ -2563,7 +2688,7 @@ FG and BG are the main colors."
|
|||
`(ledger-font-payee-cleared-face ((,c :inherit success)))
|
||||
`(ledger-font-payee-pending-face ((,c :inherit warning)))
|
||||
`(ledger-font-payee-uncleared-face ((,c :inherit error)))
|
||||
`(ledger-font-xact-highlight-face ((,c :inherit highlight)))
|
||||
`(ledger-font-xact-highlight-face ((,c :background ,bg-hl-line :extend t)))
|
||||
;;;;; leerzeichen
|
||||
`(leerzeichen ((,c :background ,bg-inactive)))
|
||||
;;;;; line numbers (display-line-numbers-mode and global variant)
|
||||
|
@ -2595,7 +2720,7 @@ FG and BG are the main colors."
|
|||
`(magit-diff-base ((,c :background ,bg-changed-faint :foreground ,fg-changed)))
|
||||
`(magit-diff-base-highlight ((,c :background ,bg-changed :foreground ,fg-changed)))
|
||||
`(magit-diff-context ((,c :inherit shadow)))
|
||||
`(magit-diff-context-highlight ((,c :background ,bg-dim)))
|
||||
`(magit-diff-context-highlight ((,c :background ,bg-diff-context)))
|
||||
`(magit-diff-file-heading ((,c :inherit bold :foreground ,accent-0)))
|
||||
`(magit-diff-file-heading-highlight ((,c :inherit magit-diff-file-heading :background ,bg-inactive)))
|
||||
`(magit-diff-file-heading-selection ((,c :inherit bold :background ,bg-hover-secondary)))
|
||||
|
@ -2668,7 +2793,7 @@ FG and BG are the main colors."
|
|||
`(marginalia-archive ((,c :foreground ,accent-0)))
|
||||
`(marginalia-char ((,c :foreground ,accent-2)))
|
||||
`(marginalia-date ((,c :foreground ,date-common)))
|
||||
`(marginalia-documentation ((,c :inherit italic :foreground ,docstring)))
|
||||
`(marginalia-documentation ((,c :inherit modus-themes-slant :foreground ,docstring)))
|
||||
`(marginalia-file-name (( )))
|
||||
`(marginalia-file-owner ((,c :inherit shadow)))
|
||||
`(marginalia-file-priv-dir ((,c :foreground ,accent-0)))
|
||||
|
@ -2720,7 +2845,7 @@ FG and BG are the main colors."
|
|||
`(markdown-table-face ((,c :inherit modus-themes-fixed-pitch :foreground ,prose-table)))
|
||||
`(markdown-url-face ((,c :foreground ,fg-alt)))
|
||||
;;;;; markup-faces (`adoc-mode')
|
||||
`(markup-attribute-face ((,c :inherit (italic markup-meta-face))))
|
||||
`(markup-attribute-face ((,c :inherit (modus-themes-slant markup-meta-face))))
|
||||
`(markup-bold-face ((,c :inherit bold)))
|
||||
`(markup-code-face ((,c :foreground ,prose-code)))
|
||||
`(markup-comment-face ((,c :inherit font-lock-comment-face)))
|
||||
|
@ -2809,7 +2934,7 @@ FG and BG are the main colors."
|
|||
`(mu4e-footer-face ((,c :inherit italic :foreground ,fg-alt)))
|
||||
`(mu4e-forwarded-face ((,c :inherit italic :foreground ,info)))
|
||||
`(mu4e-header-face ((,c :inherit shadow)))
|
||||
`(mu4e-header-highlight-face ((,c :inherit highlight)))
|
||||
`(mu4e-header-highlight-face ((,c :background ,bg-hl-line :extend t)))
|
||||
`(mu4e-header-key-face ((,c :inherit message-header-name)))
|
||||
`(mu4e-header-marks-face ((,c :inherit mu4e-special-header-value-face)))
|
||||
`(mu4e-header-title-face ((,c :foreground ,fg-alt)))
|
||||
|
@ -2920,7 +3045,7 @@ FG and BG are the main colors."
|
|||
`(orderless-match-face-3 ((,c :inherit modus-themes-completion-match-3)))
|
||||
;;;;; org
|
||||
`(org-agenda-calendar-event ((,c :foreground ,date-event)))
|
||||
`(org-agenda-calendar-sexp ((,c :inherit (italic org-agenda-calendar-event))))
|
||||
`(org-agenda-calendar-sexp ((,c :inherit (modus-themes-slant org-agenda-calendar-event))))
|
||||
`(org-agenda-clocking ((,c :inherit modus-themes-mark-alt)))
|
||||
`(org-agenda-column-dateline ((,c :background ,bg-inactive)))
|
||||
`(org-agenda-current-time ((,c :foreground ,date-now)))
|
||||
|
@ -2964,7 +3089,7 @@ FG and BG are the main colors."
|
|||
`(org-headline-todo ((,c :inherit org-todo)))
|
||||
`(org-hide ((,c :foreground ,bg-main)))
|
||||
`(org-indent ((,c :inherit (fixed-pitch org-hide))))
|
||||
`(org-imminent-deadline ((,c :inherit bold :foreground ,date-deadline)))
|
||||
`(org-imminent-deadline ((,c :inherit modus-themes-bold :foreground ,date-deadline)))
|
||||
`(org-latex-and-related ((,c :foreground ,type)))
|
||||
`(org-level-1 ((,c :inherit modus-themes-heading-1)))
|
||||
`(org-level-2 ((,c :inherit modus-themes-heading-2)))
|
||||
|
@ -2985,7 +3110,7 @@ FG and BG are the main colors."
|
|||
`(org-quote ((,c :inherit org-block)))
|
||||
`(org-scheduled ((,c :foreground ,date-scheduled)))
|
||||
`(org-scheduled-previously ((,c :inherit org-scheduled)))
|
||||
`(org-scheduled-today ((,c :inherit (bold org-scheduled))))
|
||||
`(org-scheduled-today ((,c :inherit (modus-themes-bold org-scheduled))))
|
||||
`(org-sexp-date ((,c :foreground ,date-common)))
|
||||
`(org-special-keyword ((,c :inherit org-drawer)))
|
||||
`(org-table ((,c :inherit modus-themes-fixed-pitch :foreground ,prose-table)))
|
||||
|
@ -3007,8 +3132,8 @@ FG and BG are the main colors."
|
|||
`(org-habit-clear-future-face ((,c :background ,bg-graph-blue-1)))
|
||||
`(org-habit-overdue-face ((,c :background ,bg-graph-red-0)))
|
||||
`(org-habit-overdue-future-face ((,c :background ,bg-graph-red-1)))
|
||||
`(org-habit-ready-face ((,c :background ,bg-graph-blue-0 :foreground "black"))) ; fg is special case
|
||||
`(org-habit-ready-future-face ((,c :background ,bg-graph-blue-1)))
|
||||
`(org-habit-ready-face ((,c :background ,bg-graph-green-0 :foreground "black"))) ; fg is special case
|
||||
`(org-habit-ready-future-face ((,c :background ,bg-graph-green-1)))
|
||||
;;;;; org-journal
|
||||
`(org-journal-calendar-entry-face ((,c :inherit modus-themes-slant :foreground ,date-common)))
|
||||
`(org-journal-calendar-scheduled-face ((,c :inherit (modus-themes-slant org-scheduled))))
|
||||
|
@ -3097,7 +3222,7 @@ FG and BG are the main colors."
|
|||
`(popup-tip-face ((,c :inherit modus-themes-intense-yellow)))
|
||||
;;;;; powerline
|
||||
`(powerline-active0 ((,c :background ,fg-dim :foreground ,bg-main)))
|
||||
`(powerline-active1 ((,c :inherit mode-line-active)))
|
||||
`(powerline-active1 ((,c :inherit mode-line)))
|
||||
`(powerline-active2 ((,c :inherit mode-line-inactive)))
|
||||
`(powerline-inactive0 ((,c :background ,bg-active :foreground ,fg-dim)))
|
||||
`(powerline-inactive1 ((,c :background ,bg-main :foreground ,fg-dim)))
|
||||
|
@ -3320,7 +3445,7 @@ FG and BG are the main colors."
|
|||
`(swiper-background-match-face-2 ((,c :inherit modus-themes-completion-match-0)))
|
||||
`(swiper-background-match-face-3 ((,c :inherit modus-themes-completion-match-1)))
|
||||
`(swiper-background-match-face-4 ((,c :inherit modus-themes-completion-match-2)))
|
||||
`(swiper-line-face ((,c :inherit highlight)))
|
||||
`(swiper-line-face ((,c :background ,bg-hl-line :extend t)))
|
||||
`(swiper-match-face-1 (( )))
|
||||
`(swiper-match-face-2 ((,c :inherit modus-themes-completion-match-0)))
|
||||
`(swiper-match-face-3 ((,c :inherit modus-themes-completion-match-1)))
|
||||
|
@ -3753,24 +3878,24 @@ FG and BG are the main colors."
|
|||
(if (or (eq modus-themes-org-blocks 'tinted-background)
|
||||
(eq modus-themes-org-blocks 'rainbow))
|
||||
`(org-src-block-faces
|
||||
`(("emacs-lisp" (:inherit modus-themes-subtle-magenta :extend t))
|
||||
("elisp" (:inherit modus-themes-subtle-magenta :extend t))
|
||||
("clojure" (:inherit modus-themes-subtle-magenta :extend t))
|
||||
("clojurescript" (:inherit modus-themes-subtle-magenta :extend t))
|
||||
("c" (:inherit modus-themes-subtle-blue :extend t))
|
||||
("c++" (:inherit modus-themes-subtle-blue :extend t))
|
||||
("sh" (:inherit modus-themes-subtle-green :extend t))
|
||||
("shell" (:inherit modus-themes-subtle-green :extend t))
|
||||
("html" (:inherit modus-themes-subtle-yellow :extend t))
|
||||
("xml" (:inherit modus-themes-subtle-yellow :extend t))
|
||||
("css" (:inherit modus-themes-subtle-red :extend t))
|
||||
("scss" (:inherit modus-themes-subtle-red :extend t))
|
||||
("python" (:inherit modus-themes-subtle-green :extend t))
|
||||
("ipython" (:inherit modus-themes-subtle-magenta :extend t))
|
||||
("r" (:inherit modus-themes-subtle-cyan :extend t))
|
||||
("yaml" (:inherit modus-themes-subtle-cyan :extend t))
|
||||
("conf" (:inherit modus-themes-subtle-cyan :extend t))
|
||||
("docker" (:inherit modus-themes-subtle-cyan :extend t))))
|
||||
`(("emacs-lisp" modus-themes-nuanced-magenta)
|
||||
("elisp" modus-themes-nuanced-magenta)
|
||||
("clojure" modus-themes-nuanced-magenta)
|
||||
("clojurescript" modus-themes-nuanced-magenta)
|
||||
("c" modus-themes-nuanced-blue)
|
||||
("c++" modus-themes-nuanced-blue)
|
||||
("sh" modus-themes-nuanced-green)
|
||||
("shell" modus-themes-nuanced-green)
|
||||
("html" modus-themes-nuanced-yellow)
|
||||
("xml" modus-themes-nuanced-yellow)
|
||||
("css" modus-themes-nuanced-red)
|
||||
("scss" modus-themes-nuanced-red)
|
||||
("python" modus-themes-nuanced-green)
|
||||
("ipython" modus-themes-nuanced-magenta)
|
||||
("r" modus-themes-nuanced-cyan)
|
||||
("yaml" modus-themes-nuanced-cyan)
|
||||
("conf" modus-themes-nuanced-cyan)
|
||||
("docker" modus-themes-nuanced-cyan)))
|
||||
`(org-src-block-faces '())))
|
||||
"Custom variables for `modus-themes-theme'.")
|
||||
|
||||
|
@ -3792,14 +3917,10 @@ corresponding entries."
|
|||
(let ((sym (gensym))
|
||||
(colors (mapcar #'car (symbol-value palette))))
|
||||
`(let* ((c '((class color) (min-colors 256)))
|
||||
(,sym (append ,overrides modus-themes-common-palette-overrides ,palette))
|
||||
(,sym (modus-themes--palette-value ',name ',overrides))
|
||||
,@(mapcar (lambda (color)
|
||||
(list color
|
||||
`(let* ((value (car (alist-get ',color ,sym))))
|
||||
(if (or (stringp value)
|
||||
(eq value 'unspecified))
|
||||
value
|
||||
(car (alist-get value ,sym))))))
|
||||
`(modus-themes--retrieve-palette-value ',color ,sym)))
|
||||
colors))
|
||||
(ignore c ,@colors) ; Silence unused variable warnings
|
||||
(custom-theme-set-faces ',name ,@modus-themes-faces)
|
||||
|
@ -3821,11 +3942,7 @@ corresponding entries."
|
|||
(,sym (modus-themes--current-theme-palette :overrides))
|
||||
,@(mapcar (lambda (color)
|
||||
(list color
|
||||
`(let* ((value (car (alist-get ',color ,sym))))
|
||||
(if (or (stringp value)
|
||||
(eq value 'unspecified))
|
||||
value
|
||||
(car (alist-get value ,sym))))))
|
||||
`(modus-themes--retrieve-palette-value ',color ,sym)))
|
||||
colors))
|
||||
(ignore c ,@colors) ; Silence unused variable warnings
|
||||
,@body)))
|
||||
|
|
|
@ -184,23 +184,25 @@ standard).")
|
|||
(bg-added "#003066")
|
||||
(bg-added-faint "#001a4f")
|
||||
(bg-added-refine "#0f4a77")
|
||||
(bg-added-intense "#0f4fbf")
|
||||
(bg-added-fringe "#006fff")
|
||||
(fg-added "#c4d5ff")
|
||||
(fg-added-intense "#a0afff")
|
||||
(fg-added-intense "#8080ff")
|
||||
|
||||
(bg-changed "#2f123f")
|
||||
(bg-changed-faint "#1f022f")
|
||||
(bg-changed-refine "#3f325f")
|
||||
(bg-changed-intense "#7f42af")
|
||||
(bg-changed-fringe "#7f55a0")
|
||||
(fg-changed "#e3cfff")
|
||||
(fg-changed-intense "#c0a4ff")
|
||||
(fg-changed-intense "#cf9fe2")
|
||||
|
||||
(bg-removed "#3d3d00")
|
||||
(bg-removed-faint "#281f00")
|
||||
(bg-removed-refine "#515100")
|
||||
(bg-removed-intense "#dfd23a")
|
||||
(bg-removed-fringe "#d0c03f")
|
||||
(fg-removed "#d4d48f")
|
||||
(fg-removed-intense "#c0b05f")
|
||||
(fg-removed-intense "#d0b05f")
|
||||
|
||||
(bg-diff-context "#1a1a1a")
|
||||
|
||||
;;; Paren match
|
||||
|
||||
|
@ -379,10 +381,7 @@ as a symbol and the latter as a string.
|
|||
|
||||
Semantic color mappings have the form (MAPPING-NAME COLOR-NAME)
|
||||
with both as symbols. The latter is a named color that already
|
||||
exists in the palette and is associated with a HEX-VALUE.
|
||||
|
||||
Semantic color mappings cannot be recursive: their value must be
|
||||
either COLOR-NAME or HEX-VALUE.")
|
||||
exists in the palette and is associated with a HEX-VALUE.")
|
||||
|
||||
(defcustom modus-vivendi-deuteranopia-palette-overrides nil
|
||||
"Overrides for `modus-vivendi-deuteranopia-palette'.
|
||||
|
|
|
@ -182,24 +182,26 @@ which corresponds to a minimum contrast in relative luminance of
|
|||
(bg-added "#00381f")
|
||||
(bg-added-faint "#002910")
|
||||
(bg-added-refine "#034f2f")
|
||||
(bg-added-intense "#237f3f")
|
||||
(bg-added-fringe "#237f3f")
|
||||
(fg-added "#a0e0a0")
|
||||
(fg-added-intense "#80e080")
|
||||
|
||||
(bg-changed "#363300")
|
||||
(bg-changed-faint "#2a1f00")
|
||||
(bg-changed-refine "#4a4a00")
|
||||
(bg-changed-intense "#8a7a00")
|
||||
(bg-changed-fringe "#8a7a00")
|
||||
(fg-changed "#efef80")
|
||||
(fg-changed-intense "#c0b05f")
|
||||
|
||||
(bg-removed "#4f1119")
|
||||
(bg-removed-faint "#380a0f")
|
||||
(bg-removed-refine "#781a1f")
|
||||
(bg-removed-intense "#b81a1f")
|
||||
(bg-removed-fringe "#b81a1f")
|
||||
(fg-removed "#ffbfbf")
|
||||
(fg-removed-intense "#ff9095")
|
||||
|
||||
(bg-diff-context "#1a1a1a")
|
||||
|
||||
;;; Paren match
|
||||
|
||||
(bg-paren-match "#2f7f9f")
|
||||
|
@ -377,10 +379,7 @@ as a symbol and the latter as a string.
|
|||
|
||||
Semantic color mappings have the form (MAPPING-NAME COLOR-NAME)
|
||||
with both as symbols. The latter is a named color that already
|
||||
exists in the palette and is associated with a HEX-VALUE.
|
||||
|
||||
Semantic color mappings cannot be recursive: their value must be
|
||||
either COLOR-NAME or HEX-VALUE.")
|
||||
exists in the palette and is associated with a HEX-VALUE.")
|
||||
|
||||
|
||||
(defcustom modus-vivendi-palette-overrides nil
|
||||
|
|
|
@ -121,12 +121,12 @@ which corresponds to a minimum contrast in relative luminance of
|
|||
(bg-magenta-subtle "#552f5f")
|
||||
(bg-cyan-subtle "#004065")
|
||||
|
||||
(bg-red-nuanced "#2c0614")
|
||||
(bg-green-nuanced "#001904")
|
||||
(bg-yellow-nuanced "#221000")
|
||||
(bg-blue-nuanced "#0f0e39")
|
||||
(bg-magenta-nuanced "#230631")
|
||||
(bg-cyan-nuanced "#041529")
|
||||
(bg-red-nuanced "#350f14")
|
||||
(bg-green-nuanced "#002718")
|
||||
(bg-yellow-nuanced "#2c1f00")
|
||||
(bg-blue-nuanced "#131c4d")
|
||||
(bg-magenta-nuanced "#2f133f")
|
||||
(bg-cyan-nuanced "#04253f")
|
||||
|
||||
;;; Graphs
|
||||
|
||||
|
@ -176,24 +176,26 @@ which corresponds to a minimum contrast in relative luminance of
|
|||
(bg-added "#003a2f")
|
||||
(bg-added-faint "#002922")
|
||||
(bg-added-refine "#035542")
|
||||
(bg-added-intense "#237f4f")
|
||||
(bg-added-fringe "#23884f")
|
||||
(fg-added "#a0e0a0")
|
||||
(fg-added-intense "#80e080")
|
||||
|
||||
(bg-changed "#363300")
|
||||
(bg-changed-faint "#2a1f00")
|
||||
(bg-changed-refine "#4a4a00")
|
||||
(bg-changed-intense "#8a7a00")
|
||||
(bg-changed-fringe "#8f7a30")
|
||||
(fg-changed "#efef80")
|
||||
(fg-changed-intense "#c0b05f")
|
||||
|
||||
(bg-removed "#4f1127")
|
||||
(bg-removed-faint "#380a19")
|
||||
(bg-removed-refine "#781a3a")
|
||||
(bg-removed-intense "#b81a26")
|
||||
(bg-removed-fringe "#b81a26")
|
||||
(fg-removed "#ffbfbf")
|
||||
(fg-removed-intense "#ff9095")
|
||||
|
||||
(bg-diff-context "#1a1f30")
|
||||
|
||||
;;; Uncommon accent backgrounds
|
||||
|
||||
(bg-ochre "#442c2f")
|
||||
|
@ -377,10 +379,7 @@ as a symbol and the latter as a string.
|
|||
|
||||
Semantic color mappings have the form (MAPPING-NAME COLOR-NAME)
|
||||
with both as symbols. The latter is a named color that already
|
||||
exists in the palette and is associated with a HEX-VALUE.
|
||||
|
||||
Semantic color mappings cannot be recursive: their value must be
|
||||
either COLOR-NAME or HEX-VALUE.")
|
||||
exists in the palette and is associated with a HEX-VALUE.")
|
||||
|
||||
(defcustom modus-vivendi-tinted-palette-overrides nil
|
||||
"Overrides for `modus-vivendi-tinted-palette'.
|
||||
|
|
Loading…
Add table
Reference in a new issue