I want the echo area to have a black foreground (for the characters) and blue background.

The echo area is the very lowest line in the standard emacs interface, below the mode-line.

If there was just a face (say echo-area-face) for it, this is what I would do:

;; most readable
(set-face-background 'echo-area-face "blue")
(set-face-background 'echo-area-face "black")

;; alternative (usefull for changing more attributes at once)
 '(echo-area-face ((((type tty)) (:foreground "black" :background "blue")))))

As I work with emacs in the terminal only, GUI-aspects are not relevant here.

I searched around, obviously. Some sites that have related information but did not help me solve the problem entirely:

This brought me to the following setup:

(with-current-buffer " *Echo Area 0*" (face-remap-add-relative 'default '(:background "blue")))
(with-current-buffer " *Echo Area 1*" (face-remap-add-relative 'default '(:background "blue")))

(I don't fully understand this, it reads to me like there are these two magic buffers that are displayed as the echo area. That is not how I had imagined the echo area to be implemented. Never mind.)

This code works for when text is shown in the echo area. But when there is no text there (most of the time) then the background color changes back to the default (black in my terminal).

So I would like to know how I can color the echo area consistently.

  • 2
    I believe that background color is a property of a frame, not of a buffer or a window, so you cannot do that to a minibuffer in general. OTOH, you can put the minibuffer in a separate frame : search the Elisp manual for minibuffer-only frame.
    – NickD
    Nov 12, 2021 at 2:25


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.