fit-frame-to-buffer

fit-frame-to-buffer is a variable defined in `window.el'.
Its value is
nil


Documentation:
Non-nil means `fit-window-to-buffer' can fit a frame to its buffer.
A frame is fit if and only if its root window is a live window
and this option is non-nil. If this is `horizontally', frames
are resized horizontally only. If this is `vertically', frames
are resized vertically only. Any other non-nil value means
frames can be resized in both dimensions.

You can customize this variable.

This variable was introduced, or its default value was changed, in version 24.4 of Emacs.