diff options
author | Tom Willemsen | 2013-03-23 14:02:56 +0100 |
---|---|---|
committer | Tom Willemsen | 2013-03-23 14:02:56 +0100 |
commit | d215db6c7b8d8091a51d78c869c2486595ad265d (patch) | |
tree | a14534a0e242c8428dc8985a67ed3191821a004f /emacs/init.org | |
parent | 534a2e1ab752030869778ea34eadd086bacc83f3 (diff) | |
download | dotfiles-d215db6c7b8d8091a51d78c869c2486595ad265d.tar.gz dotfiles-d215db6c7b8d8091a51d78c869c2486595ad265d.zip |
Emacs: Fix minor modes widget
Diffstat (limited to 'emacs/init.org')
-rw-r--r-- | emacs/init.org | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/emacs/init.org b/emacs/init.org index 70b134c..531e6d5 100644 --- a/emacs/init.org +++ b/emacs/init.org @@ -363,10 +363,17 @@ functionality, plus more. #+BEGIN_SRC emacs-lisp (defun oni:smt/minor-mode-indicator-text (widget) - (let ((text (concat - (when (bound-and-true-p auto-complete-mode) "C") - (when (bound-and-true-p auto-fill-mode) "F") - (when (bound-and-true-p eldoc-mode) "D")))) + (let* ((mm-alist '((auto-complete-mode . "AC ") + (auto-fill-mode . "AF ") + (eldoc-mode . "LD ") + (paredit-mode . "()"))) + (text (apply 'concat + (mapcar + (lambda (pair) + (when (and (boundp (car pair)) + (symbol-value (car pair))) + (cdr pair))) + mm-alist)))) (if (plusp (length text)) (concat " " text) ""))) |