diff options
| author | Thomas Ulmer <thomasmulmer02@gmail.com> | 2025-04-17 11:27:39 -0700 |
|---|---|---|
| committer | Thomas Ulmer <thomasmulmer02@gmail.com> | 2025-04-17 11:27:39 -0700 |
| commit | 5b33c36e579fdf8c127a53e542b4f02ce3bab2b8 (patch) | |
| tree | 7f2155d3136acfdfca8d6f942b9b53bb0e7a8db8 /emacs/site-lisp/single-header.el | |
| parent | ae2bf0a9162084af6e32df20258ed689a24048bc (diff) | |
various small changes and additions
Diffstat (limited to 'emacs/site-lisp/single-header.el')
| -rwxr-xr-x | emacs/site-lisp/single-header.el | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/emacs/site-lisp/single-header.el b/emacs/site-lisp/single-header.el index da57426..06faff5 100755 --- a/emacs/site-lisp/single-header.el +++ b/emacs/site-lisp/single-header.el @@ -14,11 +14,8 @@ (defun make-header-info-string () "generates the mode line string that contains all the info to the right" (let ((str (concat - (format-time-string "%a, %b %+4Y-%0m-%0d ") - (with-face (format-time-string "%R ") + (with-face (battery-format "[%b%p%%] " (and battery-status-function (funcall battery-status-function))) :weight 'bold) - (with-face (format "<%03.2f> " (car (load-average 1))) - :foreground "#da70d6") (with-face (let* ((mi (memory-info)) (tm (float (car mi))) (fm (float (cadr mi))) @@ -26,14 +23,17 @@ (fs (float (cadddr mi)))) (format "{%.2f %.2f} " (- 1 (/ fm tm)) (- 1 (/ fs ts)))) :foreground "#00ced1") - (with-face (battery-format "[%b%p%%] " (and battery-status-function (funcall battery-status-function))) + (with-face (format "<%03.2f> " (car (load-average 1))) + :foreground "#da70d6") + (format-time-string "%a, %b %+4Y-%0m-%0d ") + (with-face (format-time-string "%R") :weight 'bold) ))) - (setq str (concat str - (make-string + (setq str (concat (make-string (- (window-max-chars-per-line (minibuffer-window) 'single-header) (length str)) - ? ))) + ? ) + str)) (with-face str 'single-header))) (defun single-header-init-buffer (buf) |
