diff --git a/mood-line.el b/mood-line.el index 3f49c1a..471226e 100644 --- a/mood-line.el +++ b/mood-line.el @@ -55,6 +55,9 @@ (defvar anzu--current-position) (defvar anzu--total-matched) (defvar multiple-cursors-mode) +(defvar minions-direct) +(defvar minions-mode-line-lighter) +(defvar minions-mode-line-minor-modes-map) ;; ;; Function prototypes @@ -131,6 +134,11 @@ "Face used for the 'modified' indicator symbol in the mode-line." :group 'mood-line) +(defface mood-line-minions-mode + '((t (:inherit (shadow)))) + "Face used for the minions mode element." + :group 'mood-line) + ;; ;; Helper functions ;; @@ -297,6 +305,11 @@ (when mode-line-process (concat (mood-line--string-trim (format-mode-line mode-line-process)) " "))) +(defun mood-line-segment-minions-mode () + "Displays the minions mode symbol characters." + (when (and (boundp 'minions-mode) minions-mode) + (propertize (format "%s " minions-mode-line-lighter) 'face 'mood-line-minions-mode 'mouse-face 'mood-line-minions-mode 'help-echo "Minions mouse-1: Display minor modes menu" 'local-map minions-mode-line-minor-modes-map))) + ;; ;; Activation function ;; @@ -345,6 +358,7 @@ (:eval (mood-line-segment-flycheck)) (:eval (mood-line-segment-flymake)) (:eval (mood-line-segment-process)) + (:eval (mood-line-segment-minions-mode)) " "))))))) (progn