From 556a5a3257b59e4406a51b7a1a023974cb4f93ac Mon Sep 17 00:00:00 2001 From: Case Duckworth Date: Tue, 28 Sep 2021 16:22:53 -0500 Subject: Configurate modeline --- init.el | 2 +- lisp/acdw-modeline.el | 16 ++++++++-------- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/init.el b/init.el index 5f367bb..0bc2277 100644 --- a/init.el +++ b/init.el @@ -2092,8 +2092,8 @@ the default is \"/\"." acdw-modeline/modified acdw-modeline/buffer-name acdw-modeline/vc-branch - acdw-modeline/position acdw-modeline/wc + acdw-modeline/position ) (;; right acdw-modeline/track simple-modeline-segment-misc-info diff --git a/lisp/acdw-modeline.el b/lisp/acdw-modeline.el index 3836c81..25502ec 100644 --- a/lisp/acdw-modeline.el +++ b/lisp/acdw-modeline.el @@ -35,8 +35,7 @@ Otherwise, cdr should be a function that takes two points (see `count-words')." "Display the buffer name in a face reflecting its modified status." (propertize (concat " " (truncate-string (/ (window-total-width) 2) - (buffer-name) "~") - " ") + (buffer-name) "~")) 'face (if (buffer-modified-p) 'font-lock-warning-face @@ -135,15 +134,15 @@ is, if point < mark." `((line-number-mode ((column-number-mode (column-number-indicator-zero-based - (8 " %l:%c") - (8 " %l:%C")) - (5 " L%l"))) + (9 " %l/%c") + (9 " %l/%C")) + (6 " L%l"))) ((column-number-mode (column-number-indicator-zero-based (5 " C%c") (5 " C%C"))))) ,(if (region-active-p) - (propertize (format "%s%s" + (propertize (format "%s%-5d" (if (and (mark) (< (point) (mark))) "-" @@ -172,14 +171,14 @@ is, if point < mark." (defun acdw-modeline/track () "Display `tracking-mode' information." - (when tracking-mode + '(tracking-mode tracking-mode-line-buffers)) (defun acdw-modeline/vc-branch () "Display the version control branch of the current buffer in the modeline." ;; from https://www.gonsie.com/blorg/modeline.html, from Doom (if-let ((backend (vc-backend buffer-file-name))) - (substring vc-mode (+ (if (eq backend 'Hg) 2 3) 2)))) + (concat " " (substring vc-mode (+ (if (eq backend 'Hg) 2 3) 2))))) (defun acdw-modeline/wc () "Display current `wc-buffer-stats'." @@ -206,3 +205,4 @@ Uses `acdw-modeline/word-count-modes' to determine which function to use." (format " %s%dW" (if r "+" "") (funcall fn min max))))) (provide 'acdw-modeline) +;;; acdw-modeline.el ends here -- cgit 1.4.1-21-gabe81