From 7936c8a96060fa118220d4d874f740dc75e2fe47 Mon Sep 17 00:00:00 2001 From: Gabriel do Nascimento Ribeiro Date: Wed, 6 Jan 2021 20:27:26 +0200 Subject: [PATCH] * lisp/mb-depth.el (minibuffer-depth-indicator): New face. (minibuffer-depth-setup): Use new face and add a single space between the depth indicator and the minibuffer prompt. https://lists.gnu.org/archive/html/emacs-devel/2020-12/msg00230.html Copyright-paperwork-exempt: yes --- lisp/mb-depth.el | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/lisp/mb-depth.el b/lisp/mb-depth.el index 06da0739d6b..ea2ea174b50 100644 --- a/lisp/mb-depth.el +++ b/lisp/mb-depth.el @@ -35,6 +35,10 @@ It is called with one argument, the minibuffer depth, and must return a string.") +(defface minibuffer-depth-indicator '((t :inherit highlight)) + "Face to use for minibuffer depth indicator." + :version "28.1") + ;; An overlay covering the prompt. This is a buffer-local variable in ;; each affected minibuffer. ;; @@ -52,7 +56,10 @@ The prompt should already have been inserted." (overlay-put minibuffer-depth-overlay 'before-string (if minibuffer-depth-indicator-function (funcall minibuffer-depth-indicator-function depth) - (propertize (format "[%d]" depth) 'face 'highlight))) + (concat (propertize (format "[%d]" depth) + 'face + 'minibuffer-depth-indicator) + " "))) (overlay-put minibuffer-depth-overlay 'evaporate t)))) ;;;###autoload -- 2.39.5