Next: , Previous: Minibuffer Commands, Up: Minibuffers

20.11 Minibuffer Windows

These functions access and select minibuffer windows and test whether they are active.

— Function: active-minibuffer-window

This function returns the currently active minibuffer window, or nil if there is none.

— Function: minibuffer-window &optional frame

This function returns the minibuffer window used for frame frame. If frame is nil, that stands for the current frame. Note that the minibuffer window used by a frame need not be part of that frame—a frame that has no minibuffer of its own necessarily uses some other frame's minibuffer window.

— Function: set-minibuffer-window window

This function specifies window as the minibuffer window to use. This affects where the minibuffer is displayed if you put text in it without invoking the usual minibuffer commands. It has no effect on the usual minibuffer input functions because they all start by choosing the minibuffer window according to the current frame.

— Function: window-minibuffer-p &optional window

This function returns non-nil if window is a minibuffer window. window defaults to the selected window.

It is not correct to determine whether a given window is a minibuffer by comparing it with the result of (minibuffer-window), because there can be more than one minibuffer window if there is more than one frame.

— Function: minibuffer-window-active-p window

This function returns non-nil if window is the currently active minibuffer window.