Emacs: Split Windows

By Xah Lee. Date: . Last updated: .

Emacs Split Window Commands:

split-window-belowCtrl+x 2
Split window into top bottom.
split-window-rightCtrl+x 3
Split window into left right.
delete-other-windowsCtrl+x 1
Unsplit all.
delete-windowCtrl+x 0
Remove current pane.
other-windowCtrl+x o
Move cursor to next pane.
emacs split windows basics 2015
emacs split windows.

Note, emacs terminology of window/frame is reversed from modern meaning.

Adjust Split Pane Size

Or, you can use keys. Here's the commands:

enlarge-windowCtrl+x ^
Increase height.
shrink-window
Decrease height.
enlarge-window-horizontallyCtrl+x }
Increase width.
shrink-window-horizontallyCtrl+x {
Decrease width.
shrink-window-if-larger-than-bufferCtrl+x -
Shrink a window to fit its content.
balance-windowsCtrl+x +
Make all panes same width/height.

Most of these commands also take a argument. Alt+x universal-argumentCtrl+u】 first then type a number, then, call the command that adjust window size.

Put $5 at https://www.patreon.com/xahlee , or goto paypal.com and pay to Xah@XahLee.org . Message me on XahLee discord, say so, ask me questions.
Or Buy Xah Emacs Tutorial

Emacs Tutorial

Emacs Init

Emacs Keys

ELisp

ELisp Examples

ELisp Write Major Mode


Emacs Tutorial

Quick Start

Manage Windows

File

Buffer

Find Replace

Copy/Paste

Unicode

Whitespace

Rectangle Edit

Line Wrap

Shell

View Special File

Editing Brackets

Org Mode

HTML

Emacs Efficiency

Misc