emacs: define gray face for mode line indicators

This commit is contained in:
Protesilaos Stavrou 2024-02-10 11:05:12 +02:00
parent aefe2ad634
commit 4b1619387f
No known key found for this signature in database
GPG key ID: 99BD6459CD5CA3EA
2 changed files with 32 additions and 2 deletions

View file

@ -12714,6 +12714,21 @@ package).")
"Face for modeline indicators with a background."
:group 'prot-modeline-faces)
(defface prot-modeline-indicator-gray
'((t :inherit shadow))
"Face for modeline indicators (e.g. see my `notmuch-indicator')."
:group 'prot-modeline-faces)
(defface prot-modeline-indicator-gray-bg
'((default :inherit (bold prot-modeline-indicator-button))
(((class color) (min-colors 88) (background light))
:background "#808080" :foreground "white")
(((class color) (min-colors 88) (background dark))
:background "#a0a0a0" :foreground "black")
(t :inverse-video t))
"Face for modeline indicatovrs with a background."
:group 'prot-modeline-faces)
;;;; Common helper functions
(defun prot-modeline--string-truncate-p (str)
@ -12827,7 +12842,7 @@ Specific to the current window's mode line.")
'(:eval
(when (window-dedicated-p)
(propertize " = "
'face 'prot-modeline-indicator-magenta-bg
'face 'prot-modeline-indicator-gray-bg
'mouse-face 'mode-line-highlight)))
"Mode line construct for dedicated window indicator.")

View file

@ -173,6 +173,21 @@ package).")
"Face for modeline indicators with a background."
:group 'prot-modeline-faces)
(defface prot-modeline-indicator-gray
'((t :inherit shadow))
"Face for modeline indicators (e.g. see my `notmuch-indicator')."
:group 'prot-modeline-faces)
(defface prot-modeline-indicator-gray-bg
'((default :inherit (bold prot-modeline-indicator-button))
(((class color) (min-colors 88) (background light))
:background "#808080" :foreground "white")
(((class color) (min-colors 88) (background dark))
:background "#a0a0a0" :foreground "black")
(t :inverse-video t))
"Face for modeline indicatovrs with a background."
:group 'prot-modeline-faces)
;;;; Common helper functions
(defun prot-modeline--string-truncate-p (str)
@ -286,7 +301,7 @@ Specific to the current window's mode line.")
'(:eval
(when (window-dedicated-p)
(propertize " = "
'face 'prot-modeline-indicator-magenta-bg
'face 'prot-modeline-indicator-gray-bg
'mouse-face 'mode-line-highlight)))
"Mode line construct for dedicated window indicator.")