Fun with Emacs

By Xah Lee. Date: . Last updated: .

You probably heard that emacs can do lots of things. This page shows some.

emacs learning curve
A comic on emacs's learning curve. [Original source appears to be Steve Rowe's blog. A friend of mine put this together @ ]

Emacs Tetris

emacs tetris 49994
tetris in emacs

Alt+x tetris to start it. Use arrow keys to move the blocks.

Alt+x kill-buffer to close it.

Split Windows

wildly split emacs screen
Wildly split emacs screen. From top to bottom: calendar, Unicode, shell, hexl-mode , html-mode, dired, calculator.

You can split your window into two or more panes, vertically or horizontally.

Alt+x split-window-below
split top/bottom.
Alt+x split-window-right
split side-by-side.
Alt+x delete-other-windows
Alt+x other-window
move cursor to another pane. (or click mouse)

[see Emacs: Split Windows]

View Calendar

To run calendar in emacs, Alt+x calendar.

emacs calendar
A screenshots of emacs's calendar feature.

To close the calendar pane, type q.


To run a calculator in emacs, Alt+x calc.

emacs calculator
Calc mode in emacs.

To quit calculator, type q.

To compute “1+2”, type 1 Enter 2 +. Or, you can type the expression directly by starting with a sinle quote, like this: ' 1 + 2 Enter.

Directory Navigation and Managing Files

emacs dired

To start, Alt+x dired, then, type a dir path. To exit, press q. For a full tutorial, see: Emacs: File Manager, dired.

Pretty Colors

Alt+x list-colors-display

emacs list-colors-display 2021-07-19
emacs list-colors-display 2021-07-19

Command Line Interface (aka Shell)

Alt+x shell to start a shell interface. [see Emacs: Run Shell in Emacs]

emacs shell 2022-06-02
Shell in emacs

LISP in Emacs

Sometime you hear that emacs has the artificial intelligence language LISP built-in. That's right. Here's how you can run a short example.

emacs lisp eval 2021-11-01 wgWV
eval emacs lisp code [see Evaluate Emacs Lisp Code]

In emacs, open a file, any file. In the file, type (+ 1 2), then, select the whole text, then Alt+x eval-region. You will see the result “3”. CONGRADULATIONS, you've just evaluated a lisp program!

See: Emacs Lisp Basics.

ErgoEmacs mascot-s276x226
Buy Xah Emacs Tutorial

Emacs Tutorial

Quick Start

Manage Windows



Find Replace




Rectangle Edit

Line Wrap


View Special File

Editing Brackets

Org Mode


Emacs Efficiency