Online Help


The emacs help system is always available. With the default key bindings, you can start it with CONTROL-H. The help system then prompts you for a one-letter help command. If you do not know which help command you want, type ? or CONTROL-H to switch the current window to a list of help commands, each with a one-line description; emacs again requests a one-letter help command. If you decide you do not want help after all, type CONTROL-G to cancel your help request and return to the former buffer.

If the help output is only a single line, it appears in the Echo Area. If it consists of more text, the output appears in its own window. Use CONTROL-V and META-v to scroll forward and backward through the buffer (page 210). You can move the cursor between windows with CONTROL-X o (lowercase "o"). See page 225 for a discussion on working with multiple windows.

Tip: Closing the help window

To delete the help window while the cursor is in the window that holds the text you are editing, type CONTROL-X 1 (one). Alternatively, you can move the cursor to the help window (CONTROL-X 0 [lowercase "o"]) and type CONTROL-X 0 (zero) to delete the current window.

If help displays a window that occupies the entire screen, as is the case with CONTROL-H n (emacs news) and CONTROL-H t (emacs tutorial), you can kill the help buffer with CONTROL-X k or use CONTROL-X b to switch buffers (both on page 224).


On many terminals the BACKSPACE or LEFT ARROW key generates CONTROL-H. If you forget that you are using emacs and try to back over a few characters, you may unintentionally enter the help system. This action does not pose a danger to the buffer you are editing, but it can be unsettling to lose the window contents and not have a clear picture of how to restore it. While you are being prompted for the type of help you want you can type CONTROL-G to remove the prompt and return to editing the buffer. Some users elect to put help on a different key (page 240). Table 7-3 lists some of the help commands.

Table 7-3. Help commands

Command

Type of help offered

CONTROL-H a

Prompts for a string and displays a list of commands whose names contain that string.

CONTROL-H b

Displays a long table of the key bindings in effect.

CONTROL-H c key-sequence

Displays the name of the command bound to key-sequence. Multiple key sequences are allowed. For a long key sequence where only the first part is recognized, the command describes the first part and quietly inserts the unrecognized part into the buffer. This can happen with three-character function keys (F1, F2, and so on, on the keyboard) that generate character sequences such as ESCAPE [SHIFT.

CONTROL-H f

Prompts for the name of a Lisp function and displays the documentation for it. Because commands are Lisp functions, you can use a command name with this command.

CONTROL-H i

Displays the top info (page 30) menu where you can browse emacs or other documentation.

CONTROL-H k key-sequence

Displays the name and documentation of the command bound to key-sequence. (See the notes on CONTROL-H c.)

CONTROL-H l (lowercase "l")

Displays the last 100 characters typed. The record is kept after the first-stage keyboard translation. If you have customized the keyboard translation table, you must make a mental reverse translation.

CONTROL-H m

Displays the documentation and special key bindings for the current Major mode (Text, C, Fundamental, and so on, [page 229]).

CONTROL-H n

Displays the emacs news file which lists recent changes to emacs, ordered with the most recent changes first. See the tip "Closing the help window" on page 213.

CONTROL-H t

Runs an emacs tutorial session. See the tip "Closing the help window" on page 213.

CONTROL-H v

Prompts for a Lisp variable name and displays the documentation for that variable.

CONTROL-H w

Prompts for a command name and identifies any key sequence bound to that command. Multiple key sequences are allowed. (See the notes on CONTROL-H c.)


As this abridged presentation makes clear, you can use the help system to browse through the emacs internal Lisp system. For the curious following is Stallman's list of strings that match many names in the Lisp system. To get a view of the internal functionality of emacs, you can use any of these strings with CONTROL-H a (help system list of commands) or META-x apropos (prompts for a string and lists variables whose names contain that string).

backward

dir

insert

previous

view

beginning

down

kill

region

what

buffer

end

line

register

window

case

file

list

screen

word

change

fill

mark

search

yank

char

find

mode

sentence

 

defun

forward

next

set

 

delete

goto

page

sexp

 

describe

indent

paragraph

up

 





A Practical Guide to UNIX[r] for Mac OS[r] X Users
A Practical Guide to UNIX for Mac OS X Users
ISBN: 0131863339
EAN: 2147483647
Year: 2005
Pages: 234

Similar book on Amazon

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net