Next: Multiple Displays, Up: Frames
To create a new frame, call the function make-frame.
This function creates and returns a new frame, displaying the current buffer. If you are using a supported window system, it makes a window frame; otherwise, it makes a terminal frame.
The argument is an alist specifying frame parameters. Any parameters not mentioned in alist default according to the value of the variable
default-frame-alist; parameters not specified even there default from the standard X resources or whatever is used instead on your system.The set of possible parameters depends in principle on what kind of window system Emacs uses to display its frames. See Window Frame Parameters, for documentation of individual parameters you can specify.
This function itself does not make the new frame the selected frame. See Input Focus. The previously selected frame remains selected. However, the window system may select the new frame for its own reasons, for instance if the frame appears under the mouse pointer and your setup is for focus to follow the pointer.
A normal hook run by
make-framebefore it actually creates the frame.
An abnormal hook run by
make-frameafter it creates the frame. Each function inafter-make-frame-functionsreceives one argument, the frame just created.