Variable: display-buffer-alist

display-buffer-alist is a customizable variable defined in window.el.gz.

Value

nil

Documentation

Alist of user-defined conditional actions for display-buffer.

Its value takes effect before processing the ACTION argument of display-buffer and before display-buffer-base-action and display-buffer-fallback-action, but after display-buffer-overriding-action, which see.

If non-nil, this is an alist of elements (CONDITION . ACTION), where:

 CONDITION is passed to buffer-match-p, along with the name of
  the buffer that is to be displayed and the ACTION argument of
  display-buffer, to check if ACTION should be used.

 ACTION is a cons cell (FUNCTIONS . ALIST), where FUNCTIONS is an
  action function or a list of action functions and ALIST is an
  action alist. Each such action function should accept two
  arguments: a buffer to display and an alist of the same form as
  ALIST. See display-buffer for details.

display-buffer scans this alist until the CONDITION is satisfied and adds the associated ACTION to the list of actions it will try.

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

View in manual

Probably introduced at or before Emacs version 24.1.

Source Code

;; Defined in /usr/src/emacs/lisp/window.el.gz
(defcustom display-buffer-alist nil
  "Alist of user-defined conditional actions for `display-buffer'.
Its value takes effect before processing the ACTION argument of
`display-buffer' and before `display-buffer-base-action' and
`display-buffer-fallback-action', but after
`display-buffer-overriding-action', which see.

If non-nil, this is an alist of elements (CONDITION . ACTION),
where:

 CONDITION is passed to `buffer-match-p', along with the name of
  the buffer that is to be displayed and the ACTION argument of
  `display-buffer', to check if ACTION should be used.

 ACTION is a cons cell (FUNCTIONS . ALIST), where FUNCTIONS is an
  action function or a list of action functions and ALIST is an
  action alist.  Each such action function should accept two
  arguments: a buffer to display and an alist of the same form as
  ALIST.  See `display-buffer' for details.

`display-buffer' scans this alist until the CONDITION is satisfied
and adds the associated ACTION to the list of actions it will try."
  :type `(alist :key-type (buffer-predicate :tag "Condition")
                :value-type ,display-buffer--action-custom-type)
  :risky t
  :version "24.1"
  :group 'windows)