mirror of
https://github.com/doomemacs/doomemacs
synced 2025-08-03 12:27:26 -05:00
Polish mode-line (and taller)
This commit is contained in:
@ -184,7 +184,7 @@
|
|||||||
:init
|
:init
|
||||||
(defvar-local doom--env-version nil)
|
(defvar-local doom--env-version nil)
|
||||||
(defvar-local doom--env-command nil)
|
(defvar-local doom--env-command nil)
|
||||||
(defvar powerline-height 26)
|
(defvar powerline-height 30)
|
||||||
(defvar powerline-default-separator nil)
|
(defvar powerline-default-separator nil)
|
||||||
|
|
||||||
:config
|
:config
|
||||||
@ -234,14 +234,13 @@
|
|||||||
(let ((start (window-start))
|
(let ((start (window-start))
|
||||||
(end (window-end))
|
(end (window-end))
|
||||||
(pend (point-max)))
|
(pend (point-max)))
|
||||||
(if (and (eq start 1)
|
(if (and (= start 1)
|
||||||
(eq end pend))
|
(= end pend))
|
||||||
":All"
|
":All"
|
||||||
(let ((perc (/ end 0.01 pend)))
|
(let ((perc (/ end 0.01 pend)))
|
||||||
(cond ((= start 1) ":Top")
|
(cond ((= start 1) ":Top")
|
||||||
((>= perc 100) ":Bot")
|
((>= perc 100) ":Bot")
|
||||||
(t (format ":%d%%%%" perc))))))
|
(t (format ":%d%%%%" perc))))))))
|
||||||
" "))
|
|
||||||
|
|
||||||
(defface mode-line-vcs-info nil '((t (:inherit warning))))
|
(defface mode-line-vcs-info nil '((t (:inherit warning))))
|
||||||
(defface mode-line-vcs-warning nil '((t (:inherit warning))))
|
(defface mode-line-vcs-warning nil '((t (:inherit warning))))
|
||||||
@ -386,8 +385,7 @@ anzu to be enabled."
|
|||||||
(if fw (propertize (format " ⚠%s " fw)
|
(if fw (propertize (format " ⚠%s " fw)
|
||||||
'face (if active
|
'face (if active
|
||||||
'doom-flycheck-warning
|
'doom-flycheck-warning
|
||||||
'mode-line)))))))))
|
'mode-line))))))))))
|
||||||
:tight t)
|
|
||||||
|
|
||||||
(spaceline-define-segment *pad
|
(spaceline-define-segment *pad
|
||||||
"Padding, to ensure the mode-line is `powerline-height' pixels tall"
|
"Padding, to ensure the mode-line is `powerline-height' pixels tall"
|
||||||
@ -397,7 +395,8 @@ anzu to be enabled."
|
|||||||
(spaceline-compile
|
(spaceline-compile
|
||||||
'main
|
'main
|
||||||
'(*pad
|
'(*pad
|
||||||
((*macro-recording *anzu *iedit *evil-substitute *flycheck *selection-info)
|
((*macro-recording *anzu *iedit
|
||||||
|
*evil-substitute *selection-info *flycheck)
|
||||||
:skip-alternate t
|
:skip-alternate t
|
||||||
:tight t)
|
:tight t)
|
||||||
*buffer-path)
|
*buffer-path)
|
||||||
@ -406,7 +405,8 @@ anzu to be enabled."
|
|||||||
*env-version
|
*env-version
|
||||||
*buffer-encoding-abbrev
|
*buffer-encoding-abbrev
|
||||||
(global :when active)
|
(global :when active)
|
||||||
*buffer-position))
|
*buffer-position
|
||||||
|
))
|
||||||
|
|
||||||
;;
|
;;
|
||||||
(spaceline-define-segment *default-dir
|
(spaceline-define-segment *default-dir
|
||||||
|
Reference in New Issue
Block a user