Getting Help

Emacs has extensive online help, which is discussed further in Chapter 14. You can enter help through the lifesaver icon on the toolbar or through the Help menu. Either method will show you a help menu, described later in this section. To enter help using the keyboard, press C-h. Pressing C-h ? gives you a list of options. Pressing C-h t starts a tutorial that is an excellent introduction to Emacs.

To get information about the meaning of a keystroke combination, press C-h k for describe-key. For example, if you type C-h k C-x i, Emacs displays a description of the insert-file command, which is bound to C-x i. Pressing C-h f (for describe-function) asks Emacs to describe a function (really just a command name, such as find-file). Essentially, C-h k and C-h f give you the same information; the difference is that with C-h k, you press a key whereas with C-h f, you type a command name.

Assume you want to find out about what C-x i does.

Type: C-h k

image with no caption

Asking for help about a keyboard command.

Type: C-x i

image with no caption

Emacs splits the screen to display help.

A few things to notice: the window is now split into two parts because you're looking at two separate buffers. Each buffer has its own mode line. The lower buffer is the *Help* buffer; it contains the information about the insert-file command. Emacs keeps the cursor in the dickens buffer because there's no good reason for you to edit the *Help* buffer.

You might also notice that in the text describing this command, Emacs calls the cursor point. This term is used throughout Emacs to refer to the cursor; you're bound to encounter it.

To make the *Help* buffer disappear, press C-x 1 (we cover this command in Chapter 4).

The Help Menu

You can also use the Help menu to access help commands quickly, and you can get there either through the menu or through the lifesaver on the toolbar. On this menu, you find options we've discussed here: Emacs Tutorial, Describe→ Describe Key, and Describe→ Describe Function. It includes a host of interesting options, including access to the Emacs frequently asked questions (FAQ) file, a new search feature, and even an Emacs psychiatrist (you might tell it something like "Emacs is driving me over the edge today"). There's an interface to Info, Emacs's online documentation. Simply choose Read the Emacs Manual to start Info.

In this section, we've given a very brief introduction to a few of the paths you can take in the help system. There are many more help facilities; they are described thoroughly in Chapter 14. The help features we've described here should be enough to get you started; if you want to learn more, jump ahead to Chapter 14.

Get Learning GNU Emacs, 3rd Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.