~protesilaos/modus-themes

Fix mode-line face inheritance v1 PROPOSED

Steven Allen: 1
 Fix mode-line face inheritance

 1 files changed, 6 insertions(+), 6 deletions(-)
Protesilaos Stavrou <info@protesilaos.com> writes:
Next
Export patchset (mbox)
How do I use this?

Copy & paste the following snippet into your terminal to import this patchset into git:

curl -s https://lists.sr.ht/~protesilaos/modus-themes/patches/46881/mbox | git am -3
Learn more about email & git

[PATCH] Fix mode-line face inheritance Export this patch

Make `mode-line-active` and `mode-line-inactive` inherit `mode-line`,
moving the "active" color specification to `mode-line-active`. This
mirrors the face-hierarchy in upstream Emacs and makes it possible to,
e.g., scale the font of all mode-line faces by altering the base
`mode-line` face.
---
 modus-themes.el | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/modus-themes.el b/modus-themes.el
index e90409e..bc840c2 100644
--- a/modus-themes.el
+++ b/modus-themes.el
@@ -3095,15 +3095,15 @@ defconst modus-themes-faces
    `(minimap-active-region-background ((,c :background ,bg-active)))
    `(minimap-current-line-face ((,c :background ,bg-cyan-intense :foreground ,fg-main)))
;;;;; mode-line
    `(mode-line ((,c :inherit modus-themes-ui-variable-pitch
                     :box ,border-mode-line-active
                     :background ,bg-mode-line-active
                     :foreground ,fg-mode-line-active)))
    `(mode-line-active ((,c :inherit mode-line)))
    `(mode-line ((,c :inherit modus-themes-ui-variable-pitch)))
    `(mode-line-active ((,c :inherit mode-line
                            :box ,border-mode-line-active
                            :background ,bg-mode-line-active
                            :foreground ,fg-mode-line-active)))
    `(mode-line-buffer-id ((,c :inherit bold)))
    `(mode-line-emphasis ((,c :inherit bold :foreground ,modeline-info)))
    `(mode-line-highlight ((,c :background ,bg-hover :foreground ,fg-main :box ,fg-main)))
    `(mode-line-inactive ((,c :inherit modus-themes-ui-variable-pitch
    `(mode-line-inactive ((,c :inherit mode-line
                              :box ,border-mode-line-inactive
                              :background ,bg-mode-line-inactive
                              :foreground ,fg-mode-line-inactive)))
-- 
2.43.0
Hello Steven,
Thank you for taking the time to do this! I think that moving the color
specification to 'mode-line-active' will not work with Emacs 28 because
there is no 'mode-line-active' there and the 'mode-line' will thus be
left empty. Or am I missing something?

Have a nice day,
Protesilaos (or simply "Prot")