From f8ee1ceaf39dd6235b7294575c60608ed74602f2 Mon Sep 17 00:00:00 2001 From: BardofSprites <89086143+BardofSprites@users.noreply.github.com> Date: Sun, 31 Aug 2025 21:43:20 -0400 Subject: update evil mode --- bard-elisp/bard-modeline.el | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) (limited to 'bard-elisp/bard-modeline.el') diff --git a/bard-elisp/bard-modeline.el b/bard-elisp/bard-modeline.el index ceb7fbf..dd6a3d0 100644 --- a/bard-elisp/bard-modeline.el +++ b/bard-elisp/bard-modeline.el @@ -542,6 +542,22 @@ Specific to the current window's mode line.") "The equivalent of `notmuch-indicator-mode-line-construct'. Display the indicator only on the focused window's mode line.") +(defvar-local bard-evil-state-indicator + '(:eval + (when (and (bound-and-true-p evil-local-mode) + (mode-line-window-selected-p)) + (let ((state-label + (pcase evil-state + ('normal (propertize " " 'face 'prot-modeline-indicator-green)) + ('insert (propertize " " 'face 'prot-modeline-indicator-blue)) + ('visual (propertize " " 'face 'prot-modeline-indicator-yellow)) + ('replace (propertize " " 'face 'prot-modeline-indicator-red)) + ('emacs (propertize " " 'face 'prot-modeline-indicator-magenta)) + ('motion (propertize " " 'face 'prot-modeline-indicator-cyan)) + (_ (propertize " <> " 'face 'shadow))))) + state-label))) + "Modeline indicator for current Evil state.") + ;;;; Miscellaneous (defvar-local prot-modeline-misc-info @@ -558,8 +574,7 @@ Specific to the current window's mode line.") (dolist (construct '(prot-modeline-kbd-macro prot-modeline-narrow bard-modeline-centered-cursor - bard-modeline-ryo-modal-insert - bard-modeline-ryo-modal-normal + bard-evil-state-indicator prot-modeline-input-method prot-modeline-buffer-status prot-modeline-window-dedicated-status -- cgit v1.2.3