A Portable Swiss Army Knife of Emacs Commands
|
|
|
Many of these Emacs keyboard commands can be used in Aquamacs. It pays to increase your Emacs power!
In the following, "c-x" stands for "control-x", that is, two keys played simultaneously as a chord: control and x. "Esc x" is not a chord-- first press Esc, then press x.
Start emacs: emacs hello.cpp
Cursor movement: use arrow keys, DEL key
Save file: c-x c-s
Write file (Save As..): c-x c-w.
Compile file: esc-x compile.
Find file (or start new one): c-x c-f. Very useful to start a new program.
c-x c-b: list buffers
c-x b: switch buffers
c-x 1: display one window only (the one with the cursor)
c-x 2: display two windows
c-x o: move cursor to other window (when two windows showing)
c-x c-c: Exit emacs
c-space: Set mark
Redraw screen: c-l ("cntrl-ell"). Very useful when your display gets scrambled.
Undo the last command: Esc x undo
Redo Complex Command: c-x esc esc. Very useful to repeat a compile command.
Suspend Emacs: c-z. Resume from the command line with %1.
Restore Emacs display to one window (after a compile): c-x 1.
Exit emacs: c-x c-c
Cancel command: c-g. Very useful when you start a command by
accident.
Parse compiler errors (for C++ programmers): c-x `
Menus: Esc `
Emacs Tutorial: c-h t. Very useful if you want to really learn Emacs.