hydra.el (hydra-head-format): Customize the key formatting

* hydra.el (hydra--hint): Update.
master
Oleh Krehel 11 years ago
parent c8b4749e85
commit df7b079af8
  1. 5
      hydra.el

@ -419,6 +419,9 @@ Return DEFAULT if PROP is not in H."
(message "")))
nil)
(defvar hydra-head-format "[%s]: "
"The formatter for each head of a plain docstring.")
(defun hydra--hint (body heads)
"Generate a hint for the echo area.
BODY, and HEADS are parameters to `defhydra'."
@ -439,7 +442,7 @@ BODY, and HEADS are parameters to `defhydra'."
(lambda (x)
(format
(if (> (length (cdr x)) 0)
(concat "[%s]: " (cdr x))
(concat hydra-head-format (cdr x))
"%s")
(car x)))
keys

Loading…
Cancel
Save