emacs-elpa-diffs
[Top][All Lists]
Advanced

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

[nongnu] elpa/telephone-line 0d23081c68 148/195: Add a couple faces for


From: ELPA Syncer
Subject: [nongnu] elpa/telephone-line 0d23081c68 148/195: Add a couple faces for segments
Date: Wed, 5 Jan 2022 02:59:41 -0500 (EST)

branch: elpa/telephone-line
commit 0d23081c68c64c572993063549fee977147680e0
Author: Daniel Bordak <dbordak@fastmail.fm>
Commit: Daniel Bordak <dbordak@fastmail.fm>

    Add a couple faces for segments
---
 telephone-line-segments.el | 24 ++++++++++++------------
 telephone-line.el          | 10 ++++++++++
 2 files changed, 22 insertions(+), 12 deletions(-)

diff --git a/telephone-line-segments.el b/telephone-line-segments.el
index 0b0123700d..d7a96b49e5 100644
--- a/telephone-line-segments.el
+++ b/telephone-line-segments.el
@@ -128,16 +128,16 @@ mouse-3: Toggle minor modes"
       (winum-get-number-string))))
 
 (telephone-line-defsegment telephone-line-projectile-segment ()
-    (if (fboundp 'projectile-project-name)
-        (propertize (projectile-project-name)
-                    'face '(:inherit)
-                    'display '(raise 0.0)
-                    'help-echo "Switch project"
-                    'mouse-face '(:box 1)
-                    'local-map (make-mode-line-mouse-map
-                                'mouse-1 (lambda ()
-                                           (interactive)
-                                           (projectile-switch-project))))))
+  (if (fboundp 'projectile-project-name)
+      (propertize (projectile-project-name)
+                  'face 'telephone-line-projectile
+                  'display '(raise 0.0)
+                  'help-echo "Switch project"
+                  'mouse-face '(:box 1)
+                  'local-map (make-mode-line-mouse-map
+                              'mouse-1 (lambda ()
+                                         (interactive)
+                                         (projectile-switch-project))))))
 
 (telephone-line-defsegment* telephone-line-evil-tag-segment ()
   (when (bound-and-true-p evil-mode)
@@ -162,9 +162,9 @@ mouse-3: Toggle minor modes"
                                                             (or .error 0) (or 
.warning 0))
                                                     'face '(:foreground 
"orange"))
                                       ""))
-                                ":)"))
+                                (propertize ":)" 'face 
'telephone-line-unimportant)))
                    ('running     "*")
-                   ('no-checker  "-")
+                   ('no-checker  (propertize "-" 'face 
'telephone-line-unimportant))
                    ('not-checked "=")
                    ('errored     (propertize "!" 'face '(:foreground 
"tomato")))
                    ('interrupted (propertize "." 'face '(:foreground 
"tomato")))
diff --git a/telephone-line.el b/telephone-line.el
index e4ef34d8aa..c9cc278a52 100644
--- a/telephone-line.el
+++ b/telephone-line.el
@@ -50,6 +50,16 @@
   "Accent face for inactive mode-line."
   :group 'telephone-line)
 
+(defface telephone-line-projectile
+  '((t (:foreground "light green" :bold t :inherit mode-line)))
+  "Hightlight face for the projectile segment"
+  :group 'telephone-line)
+
+(defface telephone-line-unimportant
+  '((t (:foreground "dim grey" :inherit mode-line)))
+  "Hightlight face for the projectile segment"
+  :group 'telephone-line)
+
 (defface telephone-line-evil
   '((t (:foreground "white" :weight bold :inherit mode-line)))
   "Meta-face used for property inheritance on all telephone-line-evil faces."



reply via email to

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