I'm trying to customize Helm buffers' mode-line.
I have set mode-line-format
with powerline
package:
(setq-default
mode-line-format
'("%e"
(:eval
(let* ((active (powerline-selected-window-active))
;; Conditionnal faces (in function of `active')
...
;; Left elements
(lhs ...)
;; Right elements
(rhs ...))
;; Build the result
(concat
(powerline-render lhs)
(powerline-fill mode-line-3-face (powerline-width rhs))
(powerline-render rhs))))))
From what I understand from helm-mode-line-string
's documentation:
Help string displayed in mode-line in
helm'. It can be a string or a list of two args, in this case, first arg is a string that will be used as name for candidates number, second arg any string to display in mode line. If nil, use default
mode-line-format'.
I should be able to have my customized mode-line everywhere (in every buffers) with:
(setq-default helm-mode-line-string nil)
Isn't this line from helm.el supposed to do exactly what I want?
(setq mode-line-format (default-value 'mode-line-format))
Edit
Works as intended with: helm-colors
, helm-projectile-ag
, helm-projectile-grep
.
But not with: helm-M-x
, helm-projectile-find-file
, helm-projectile-switch-project
.
helm-mode-line-string
to nil will keep helm from building its ownmode-line-format
, which works as expected (I can confirm).helm-M-x
, any idea? Update post.helm-mode-line-string
will not matter if helm source has'mode-line
slot set, such as inhelm-M-x
andhelm-regexp
. Since helm sets its ownmode-line-format
inhelm-display-mode-line
, you can set yourmode-line-format
there by advising the function (spaceline'sspaceline-helm-mode
is using this way: github.com/TheBB/spaceline/blob/…).