aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Tom Willemse2025-05-08 22:18:07 -0700
committerGravatar Tom Willemse2025-05-08 22:18:07 -0700
commit1cf6c63830e07c5131ca7d8889c2561ac7d6cd91 (patch)
tree32d24bbfdbbdeb4db86a0f70af75c3a551bf65f6
parent384fd8e70e8f7613dd1bdf6be11b61f258e9bef8 (diff)
downloadyoshi-theme-1cf6c63830e07c5131ca7d8889c2561ac7d6cd91.tar.gz
yoshi-theme-1cf6c63830e07c5131ca7d8889c2561ac7d6cd91.zip
yoshi-mode-line: Fix getting original value for mode-line-format
Now the ‘setq-default’ form can be called multiple times without duplicating the elements added to the mode line.
-rw-r--r--yoshi-mode-line.el2
1 files changed, 1 insertions, 1 deletions
diff --git a/yoshi-mode-line.el b/yoshi-mode-line.el
index 0113765..6089013 100644
--- a/yoshi-mode-line.el
+++ b/yoshi-mode-line.el
@@ -60,7 +60,7 @@
(propertize "read-write" 'display `(image :type svg :file ,(expand-file-name "file-solid.svg" yoshi-mode-line-icons-dir) :ascent center :height ,(window-default-font-height))))))
(setq-default mode-line-format
- `("%e" mode-line-front-space (:eval (yoshi-mode-line-buffer-status-display)) ,@(cdr (default-value 'mode-line-format))))
+ `("%e" mode-line-front-space (:eval (yoshi-mode-line-buffer-status-display)) ,@(cdadr (car (get 'mode-line-format 'standard-value)))))
(provide 'yoshi-mode-line)
;;; yoshi-mode-line.el ends here