Add an icon to modeline for narrowed buffers

This commit is contained in:
Henrik Lissner 2017-06-28 17:37:43 +02:00
parent 8f22c64e80
commit ba7bc03cf6
No known key found for this signature in database
GPG key ID: 5F6C0EA160557395

View file

@ -279,6 +279,12 @@ directory, the file name, and its state (modified, read-only or non-existent)."
"circle-slash" "circle-slash"
:face 'doom-modeline-urgent :face 'doom-modeline-urgent
:v-adjust -0.05) :v-adjust -0.05)
" "))
((buffer-narrowed-p)
(concat (all-the-icons-octicon
"fold"
:face 'doom-modeline-warning
:v-adjust -0.05)
" "))) " ")))
(when-let (dir-path (+doom-modeline--buffer-path)) (when-let (dir-path (+doom-modeline--buffer-path))
(if-let (faces (or faces (if active 'doom-modeline-buffer-path))) (if-let (faces (or faces (if active 'doom-modeline-buffer-path)))