Sams Teach Yourself Emacs in 24 Hours |
||||||||||||||
Hour 10: The Emacs Help System and Configuration System |
||||||||||||||
|
Long before the World Wide Web was invented, the info system was invented. It is a hyperlinked information system, intended to replace ordinary manual pages. It works much like the Web, with the important difference that the document can be read sequentially like a book.
If you press C-h i (info), you are taken to a whole new world of information. If you use a new Linux distribution, you can find info pages for most of the programs on your machine. Otherwise you can at least find information about Emacs. In Figure 10.6 shows one of the info pages.
Each info page is built up from the following parts:
The topmost line contains special information about how this info page relates to the rest of the pages in the given document. The Next and Prev fields link, respectively, to the next and the previous page on the same level as this page. To illustrate this, think of a book. If this node is a section, Next and Prev point to the next and the previous sections of the book. If it is a subsection, they point to the next and the previous subsection. The Up field links to the node at a higher level. In the book example, this would be the chapter node for a section.
The second line of the page is the title. This info page describes "Deletion and Killing."
Then comes the actual text of the node. In the text there might be links to other pages of the document. An example of this is the link to the node on Undo. All such references contain the text (*note before the link and ::.) after the link. (Remember, this was invented long before the Web and must work with terminals that do not support highlighting or underlines).
At the bottom of the page, there are links to subpages on the given topic. Again, from the book example, these would be links to all subsections of the given section. In this part, the lines start with *.
To get around in a single info page, use the arrow keys. Following links is done by either clicking the middle mouse button over them or moving point to the location and pressing Enter.
The info browser has a Back function similar to Web browsers. Press l to get back to the info page that you visited before this one.
Unfortunately, the info browser has no Forward function. In addition to using the links at the top, you can access the previous and next pages at the same level by pressing p and n and the up link by pressing u. Furthermore, the topmost info page (the one you arrive at when you enter the info system for the first time) is available by pressing d.
The ordinary search mechanism described in Hour 7, "Searching for Text in a Buffer," is still available in the info pages but, as always, applies only to the current buffer. Furthermore, there's a command for searching in a document, which is bound to s. When you press s Emacs asks you for a search string. To continue the search, press s again and, when Emacs asks you what you want to search for, simply press Enter; this makes Emacs continue the current search. You can also press , (comma) to continue the search, but that is one more key binding to remember.
Caution - The search command works only with documents, not with the whole hierarchy of info pages. |
Sams Teach Yourself Emacs in 24 Hours |
||||||||||||||
Hour 10: The Emacs Help System and Configuration System |
||||||||||||||
|
© Copyright Macmillan USA. All rights reserved.