From f4a3f54ee6ba01e2a0088695451b1cb7dbf53eb3 Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Fri, 3 Mar 2017 17:50:43 -0500 Subject: [PATCH] ui/doom-modeline: display filesize when matches segment is empty --- modules/ui/doom-modeline/config.el | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/modules/ui/doom-modeline/config.el b/modules/ui/doom-modeline/config.el index efcf7ba6f..d1c4a85aa 100644 --- a/modules/ui/doom-modeline/config.el +++ b/modules/ui/doom-modeline/config.el @@ -472,12 +472,15 @@ lines are selected, or the NxM dimensions of a block selection." 'face (if (active) 'doom-modeline-panel)))) (def-modeline-segment! matches - "TODO" - (or (concat (+doom-modeline--macro-recording) - (+doom-modeline--anzu) - (+doom-modeline--evil-substitute) - (+doom-modeline--iedit)) - " %I ")) + "Displays: 1. the currently recording macro, 2. A current/total for the +current search term (with anzu), 3. The number of substitutions being conducted +with `evil-ex-substitute', and/or 4. The number of active `iedit' regions." + (let ((meta (concat (+doom-modeline--macro-recording) + (+doom-modeline--anzu) + (+doom-modeline--evil-substitute) + (+doom-modeline--iedit)))) + (or (and (not (string-empty-p meta)) meta) + " %I "))) (def-modeline-segment! media-info "TODO"