From eab39937cd36c18e0d71c7c2b2cc10cab7a14bf4 Mon Sep 17 00:00:00 2001 From: Vincent Zhang Date: Tue, 12 Feb 2019 17:41:26 +0800 Subject: [PATCH] Fix incorrect file icon. See https://github.com/seagle0128/doom-modeline/issues/114#issuecomment-462471548. --- doom-modeline-segments.el | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/doom-modeline-segments.el b/doom-modeline-segments.el index c1cc678..4341df3 100644 --- a/doom-modeline-segments.el +++ b/doom-modeline-segments.el @@ -298,7 +298,8 @@ directory, the file name, and its state (modified, read-only or non-existent)." ;; major mode icon (when (and doom-modeline-icon doom-modeline-major-mode-icon) (when-let ((icon (or doom-modeline--buffer-file-icon - (doom-modeline-update-buffer-file-icon)))) + (doom-modeline-update-buffer-file-icon))) + (face (if active 'mode-line 'mode-line-inactive))) (concat (if (and active doom-modeline-major-mode-color-icon) icon @@ -307,7 +308,7 @@ directory, the file name, and its state (modified, read-only or non-existent)." ,(doom-modeline-icon-height 1.1) :family ,(all-the-icons-icon-family icon) - :inherit mode-line-inactive))) + :inherit ,face))) (if active doom-modeline-vspc doom-modeline-inactive-vspc)))) ;; state icon