Add the roy-modal indicator.

This commit is contained in:
Vincent Zhang 2018-11-22 03:13:44 +08:00
parent 9acad7f3f4
commit d430859bf2

View file

@ -240,8 +240,6 @@ active.")
(defface doom-modeline-evil-replace-state'((t (:inherit doom-modeline-buffer-modified)))
"Face for the replace state tag in evil state indicator.")
(defface doom-modeline-god-state'((t (:inherit doom-modeline-info)))
"Face for the god state indicator.")
;;
;; Modeline library
@ -1177,7 +1175,19 @@ See `mode-line-percent-position'.")
(doom-modeline-def-segment god-state
"The current god state. Requires `god-mode' to be enabled."
(when (bound-and-true-p god-local-mode)
(propertize " <G> " 'face 'doom-modeline-god-state)))
(propertize " <G> " 'face (if (doom-modeline--active)
'doom-modeline-evil-normal-state))))
;;
;; ryo-modal state
;;
(doom-modeline-def-segment ryo-modal-state ()
"The current ryo-modal state. Requires `ryo-modal-mode' to be enabled."
(when (bound-and-true-p ryo-modal-mode)
(propertize " <R> " 'face (if (doom-modeline--active)
'doom-modeline-evil-normal-state))))
;;
@ -1201,7 +1211,7 @@ See `mode-line-percent-position'.")
;;
(doom-modeline-def-modeline 'main
'(bar workspace-number window-number evil-state god-state matches " " buffer-info buffer-position " " selection-info)
'(bar workspace-number window-number evil-state god-state ryo-modal-state matches " " buffer-info buffer-position " " selection-info)
'(global input-method buffer-encoding major-mode process vcs flycheck))
(doom-modeline-def-modeline 'minimal
@ -1209,7 +1219,7 @@ See `mode-line-percent-position'.")
'(media-info major-mode))
(doom-modeline-def-modeline 'special
'(bar window-number evil-state god-state matches " " buffer-info-simple buffer-position " " selection-info)
'(bar window-number evil-state god-state ryo-modal-state matches " " buffer-info-simple buffer-position " " selection-info)
'(global input-method buffer-encoding major-mode process flycheck))
(doom-modeline-def-modeline 'project