From 65ea32f20debdfc18dc709d187b498f0eed94341 Mon Sep 17 00:00:00 2001 From: Vincent Zhang Date: Fri, 21 Dec 2018 19:36:41 +0800 Subject: [PATCH] Fix #72: Keep the same buffer-info in active and inactive modeline. --- doom-modeline.el | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/doom-modeline.el b/doom-modeline.el index 1e601f8..bb31233 100644 --- a/doom-modeline.el +++ b/doom-modeline.el @@ -843,16 +843,21 @@ directory, the file name, and its state (modified, read-only or non-existent)." (concat ;; major mode icon (if (and doom-modeline-icon doom-modeline-major-mode-icon) - (or doom-modeline--buffer-file-icon (doom-modeline-update-buffer-file-icon))) + (or doom-modeline--buffer-file-icon + (doom-modeline-update-buffer-file-icon))) ;; state icon (if (doom-modeline--active) - (or doom-modeline--buffer-file-state-icon (doom-modeline-update-buffer-file-state-icon))) + (or doom-modeline--buffer-file-state-icon + (doom-modeline-update-buffer-file-state-icon))) ;; buffer file name (if (doom-modeline--active) - (or doom-modeline--buffer-file-name (doom-modeline-update-buffer-file-name)) - "%b"))) + (or doom-modeline--buffer-file-name + (doom-modeline-update-buffer-file-name)) + (propertize + (or doom-modeline--buffer-file-name "%b") + 'face 'mode-line-inactive)))) (doom-modeline-def-segment buffer-info-simple "Display only the current buffer's name, but with fontification."