doom-modeline no longer errors out, in case a modeline doesn't exist; add doom-set-modeline
This commit is contained in:
parent
b006e9d0dc
commit
8e7aa152bb
5 changed files with 25 additions and 15 deletions
|
@ -22,7 +22,7 @@
|
|||
(add-hook 'twittering-mode-hook #'doom-buffer-mode))
|
||||
|
||||
(add-hook! twittering-mode
|
||||
(setq header-line-format (doom-modeline 'twitter)
|
||||
(setq header-line-format (or (doom-modeline 'twitter) mode-line-format)
|
||||
mode-line-format nil))
|
||||
|
||||
(map! :map twittering-mode-map
|
||||
|
|
|
@ -101,9 +101,9 @@ whose dimensions may not be fully initialized by the time this is run."
|
|||
(unless +doom-dashboard-modeline
|
||||
(setq +doom-dashboard-old-modeline mode-line-format)
|
||||
(setq +doom-dashboard-modeline
|
||||
(if (featurep! :ui doom-modeline)
|
||||
(doom-modeline 'project)
|
||||
mode-line-format)))
|
||||
(or (and (featurep! :ui doom-modeline)
|
||||
(doom-modeline 'project))
|
||||
mode-line-format)))
|
||||
(let ((old-pwd (or dir default-directory)))
|
||||
(with-current-buffer (doom-fallback-buffer)
|
||||
(+doom-dashboard-mode)
|
||||
|
|
|
@ -20,7 +20,7 @@
|
|||
"Display string STR in the mode-line next to minibuffer."
|
||||
(with-current-buffer (eldoc-current-buffer)
|
||||
(let* ((str (and (stringp input) input))
|
||||
(mode-line-format (or (and str (doom-modeline 'eldoc))
|
||||
(mode-line-format (or (and str (or (doom-modeline 'eldoc) str))
|
||||
mode-line-format))
|
||||
mode-line-in-non-selected-windows)
|
||||
(force-mode-line-update)
|
||||
|
@ -562,12 +562,12 @@ with `evil-ex-substitute', and/or 4. The number of active `iedit' regions."
|
|||
(major-mode))
|
||||
|
||||
;;
|
||||
(setq-default mode-line-format (doom-modeline 'main))
|
||||
(doom-set-modeline 'main t)
|
||||
|
||||
;; This scratch buffer is already created, and doesn't get a modeline. For the
|
||||
;; love of Emacs, someone give the man a modeline!
|
||||
(with-current-buffer "*scratch*"
|
||||
(setq mode-line-format (doom-modeline 'main)))
|
||||
(doom-set-modeline 'main))
|
||||
|
||||
|
||||
;;
|
||||
|
@ -575,6 +575,6 @@ with `evil-ex-substitute', and/or 4. The number of active `iedit' regions."
|
|||
;;
|
||||
|
||||
(defun +doom-modeline|set-special-modeline ()
|
||||
(setq mode-line-format (doom-modeline 'special)))
|
||||
(doom-set-modeline 'special))
|
||||
|
||||
(add-hook 'org-src-mode-hook #'+doom-modeline|set-special-modeline)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue