Variable: minibuffer-default-prompt-format

minibuffer-default-prompt-format is a customizable variable defined in minibuffer.el.gz.

Value

" (default %s)"

Documentation

Format string used to output "default" values.

When prompting for input, there will often be a default value, leading to prompts like "Number of articles (default 50): ". The "default" part of that prompt is controlled by this variable, and can be set to, for instance, " [%s]" if you want a shorter displayed prompt, or "", if you don't want to display the default at all.

This variable is used by the format-prompt function.

This variable was added, or its default value changed, in Emacs 28.1.

View in manual

Probably introduced at or before Emacs version 28.1.

Source Code

;; Defined in /usr/src/emacs/lisp/minibuffer.el.gz
(defcustom minibuffer-default-prompt-format " (default %s)"
  "Format string used to output \"default\" values.
When prompting for input, there will often be a default value,
leading to prompts like \"Number of articles (default 50): \".
The \"default\" part of that prompt is controlled by this
variable, and can be set to, for instance, \" [%s]\" if you want
a shorter displayed prompt, or \"\", if you don't want to display
the default at all.

This variable is used by the `format-prompt' function."
  :version "28.1"
  :type 'string)