567 |
|
|
568 |
>> Try C-x C-b now. |
>> Try C-x C-b now. |
569 |
|
|
570 |
See how each buffer has a name, and it may also have a file name |
See how each buffer has a name, and it may also have a file name for |
571 |
for the file whose contents it holds. Some buffers do not correspond |
the file whose contents it holds. ANY text you see in an Emacs window |
|
to files. For example, the buffer named "*Buffer List*" does |
|
|
not have any file. It is the buffer which contains the buffer |
|
|
list that was made by C-x C-b. ANY text you see in an Emacs window |
|
572 |
is always part of some buffer. |
is always part of some buffer. |
573 |
|
|
574 |
>> Type C-x 1 to get rid of the buffer list. |
>> Type C-x 1 to get rid of the buffer list. |
575 |
|
|
576 |
|
When you have several buffers, only of of them is "current" at any |
577 |
|
time. That buffer is the one you edit. If you want to edit another |
578 |
|
buffer, you need to "switch" to it. If you want to switch to a buffer |
579 |
|
that corresponds to a file, you can do it by visiting the file again |
580 |
|
with C-x C-f. But there is an easier way: use the C-x b command. |
581 |
|
In that command, you have to type the buffer's name. |
582 |
|
|
583 |
|
>> Type C-x b foo <Return> to go back to the buffer "foo" which holds |
584 |
|
the text of the file "foo". Then type C-x b TUTORIAL <Return> |
585 |
|
to come back to this tutorial. |
586 |
|
|
587 |
|
Most of the time, the buffer's name is the same as the file name |
588 |
|
(without the file directory part). However, this is not always true. |
589 |
|
The buffer list you make with C-x C-b always shows you the name of |
590 |
|
every buffer. |
591 |
|
|
592 |
|
ANY text you see in an Emacs window is always part of some buffer. |
593 |
|
Some buffers do not correspond to files. For example, the buffer |
594 |
|
named "*Buffer List*" does not have any file. It is the buffer which |
595 |
|
contains the buffer list that you made with C-x C-b. The buffer named |
596 |
|
"*Messages*" also does not correspond to any file; it contains the |
597 |
|
messages that have appeared on the bottom line during your Emacs |
598 |
|
session. |
599 |
|
|
600 |
|
>> Type C-x b *Messages* <Return> to look at the buffer of messages. |
601 |
|
Then type C-b TUTORIAL <Return> to come back to this tutorial. |
602 |
|
|
603 |
If you make changes to the text of one file, then find another file, |
If you make changes to the text of one file, then find another file, |
604 |
this does not save the first file. Its changes remain inside Emacs, |
this does not save the first file. Its changes remain inside Emacs, |
605 |
in that file's buffer. The creation or editing of the second file's |
in that file's buffer. The creation or editing of the second file's |