67 |
@table @kbd |
@table @kbd |
68 |
@item C-x b @var{buffer} @key{RET} |
@item C-x b @var{buffer} @key{RET} |
69 |
Select or create a buffer named @var{buffer} (@code{switch-to-buffer}). |
Select or create a buffer named @var{buffer} (@code{switch-to-buffer}). |
70 |
|
@item C-x @key{LEFT} |
71 |
|
Select the previous buffer in the list of existing buffers. |
72 |
|
@item C-x @key{RIGHT} |
73 |
|
Select the next buffer in the list of existing buffers. |
74 |
@item C-x 4 b @var{buffer} @key{RET} |
@item C-x 4 b @var{buffer} @key{RET} |
75 |
Similar, but select @var{buffer} in another window |
Similar, but select @var{buffer} in another window |
76 |
(@code{switch-to-buffer-other-window}). |
(@code{switch-to-buffer-other-window}). |
88 |
specifies the buffer that was current most recently among those not |
specifies the buffer that was current most recently among those not |
89 |
now displayed in any window. |
now displayed in any window. |
90 |
|
|
91 |
|
@kindex C-x @key{LEFT} |
92 |
|
@kindex C-x @key{RIGHT} |
93 |
|
@findex next-buffer |
94 |
|
@findex prev-buffer |
95 |
|
For conveniently switching between a few buffers, use the commands |
96 |
|
@kbd{C-x @key{LEFT}} and @kbd{C-x @key{RIGHT}}. @kbd{C-x @key{RIGHT}} |
97 |
|
(@code{prev-buffer}) selects the previous buffer (following the order |
98 |
|
of most recent selection), while @kbd{C-x @key{LEFT}} |
99 |
|
(@code{next-buffer}) moves through buffers in the reverse direction. |
100 |
|
|
101 |
@kindex C-x 4 b |
@kindex C-x 4 b |
102 |
@findex switch-to-buffer-other-window |
@findex switch-to-buffer-other-window |
103 |
@vindex even-window-heights |
@vindex even-window-heights |
155 |
@cindex listing current buffers |
@cindex listing current buffers |
156 |
@kindex C-x C-b |
@kindex C-x C-b |
157 |
@findex list-buffers |
@findex list-buffers |
158 |
To display a list of all the buffers that exist, type @kbd{C-x C-b}. |
To display a list of existing buffers, type @kbd{C-x C-b}. Each |
159 |
Each line in the list shows one buffer's name, major mode and visited |
line in the list shows one buffer's name, major mode and visited file. |
160 |
file. The buffers are listed in the order that they were current; the |
The buffers are listed in the order that they were current; the |
161 |
buffers that were current most recently come first. |
buffers that were current most recently come first. |
162 |
|
|
163 |
@samp{*} in the first field of a line indicates the buffer is ``modified.'' |
@samp{*} in the first field of a line indicates the buffer is ``modified.'' |
185 |
visiting files by giving the command a prefix; for instance, by typing |
visiting files by giving the command a prefix; for instance, by typing |
186 |
@kbd{C-u C-x C-b}. |
@kbd{C-u C-x C-b}. |
187 |
|
|
188 |
@code{list-buffers} omits buffers whose name begins with a blank, |
@code{list-buffers} omits buffers whose names begin with a space, |
189 |
unless they visit files: such buffers are used internally by Emacs. |
unless they visit files: such buffers are used internally by Emacs. |
190 |
|
|
191 |
@need 2000 |
@need 2000 |
346 |
buffers@footnote{Buffers which don't visit files and whose names begin |
buffers@footnote{Buffers which don't visit files and whose names begin |
347 |
with a space are omitted: these are used internally by Emacs.} into the |
with a space are omitted: these are used internally by Emacs.} into the |
348 |
buffer @samp{*Buffer List*}, and selects that buffer in Buffer Menu |
buffer @samp{*Buffer List*}, and selects that buffer in Buffer Menu |
349 |
mode. The list in the @samp{*Buffer List*} buffer looks exactly as |
mode. |
350 |
described in @ref{List Buffers}. The buffer is read-only, and can be |
|
351 |
|
The buffer is read-only, and can be |
352 |
changed only through the special commands described in this section. |
changed only through the special commands described in this section. |
353 |
The usual Emacs cursor motion commands can be used in the @samp{*Buffer |
The usual Emacs cursor motion commands can be used in the @samp{*Buffer |
354 |
List*} buffer. The following commands apply to the buffer described on |
List*} buffer. The following commands apply to the buffer described on |
426 |
marked any buffers, this command is equivalent to @kbd{1}. |
marked any buffers, this command is equivalent to @kbd{1}. |
427 |
@end table |
@end table |
428 |
|
|
429 |
All that @code{buffer-menu} does directly is create and switch to a |
There is also a command that affects the entire buffer list: |
430 |
suitable buffer, and turn on Buffer Menu mode. Everything else |
|
431 |
|
@table @kbd |
432 |
|
@item T |
433 |
|
Delete, or reinsert, lines for non-file buffers. This command toggles |
434 |
|
the inclusion of such buffers in the buffer list. |
435 |
|
@end table |
436 |
|
|
437 |
|
What @code{buffer-menu} actually does is create and switch to a |
438 |
|
suitable buffer, and turn on Buffer Menu mode in it. Everything else |
439 |
described above is implemented by the special commands provided in |
described above is implemented by the special commands provided in |
440 |
Buffer Menu mode. One consequence of this is that you can switch from |
Buffer Menu mode. One consequence of this is that you can switch from |
441 |
the @samp{*Buffer List*} buffer to another Emacs buffer, and edit there. |
the @samp{*Buffer List*} buffer to another Emacs buffer, and edit |
442 |
You can reselect the @samp{*Buffer List*} buffer later, to perform the |
there. You can reselect the @samp{*Buffer List*} buffer later, to |
443 |
operations already requested, or you can kill it, or pay no further |
perform the operations already requested, or you can kill it, or pay |
444 |
attention to it. |
no further attention to it. |
445 |
|
|
446 |
The only difference between @code{buffer-menu} and @code{list-buffers} |
The list in the @samp{*Buffer List*} buffer looks exactly like the |
447 |
is that @code{buffer-menu} switches to the @samp{*Buffer List*} buffer |
buffer list described in @ref{List Buffers}, because they really are |
448 |
in the selected window; @code{list-buffers} displays it in another |
the same. The only difference between @code{buffer-menu} and |
449 |
window. If you run @code{list-buffers} (that is, type @kbd{C-x C-b}) |
@code{list-buffers} is that @code{buffer-menu} switches to the |
450 |
and select the buffer list manually, you can use all of the commands |
@samp{*Buffer List*} buffer in the selected window; |
451 |
described here. |
@code{list-buffers} displays the same buffer in another window. If |
452 |
|
you run @code{list-buffers} (that is, type @kbd{C-x C-b}) and select |
453 |
|
the buffer list manually, you can use all of the commands described |
454 |
|
here. |
455 |
|
|
456 |
Normally, the buffer @samp{*Buffer List*} is not updated automatically when |
Normally, the buffer @samp{*Buffer List*} is not updated automatically when |
457 |
buffers are created and killed; its contents are just text. If you have |
buffers are created and killed; its contents are just text. If you have |
532 |
convenient to switch between buffers. |
convenient to switch between buffers. |
533 |
|
|
534 |
@menu |
@menu |
535 |
* Uniquify:: Buffer names can contain directory parts. |
* Uniquify:: Making buffer names unique with directory parts. |
536 |
* Iswitchb:: Switching between buffers with substrings. |
* Iswitchb:: Switching between buffers with substrings. |
537 |
* Buffer Menus:: Configurable buffer menu. |
* Buffer Menus:: Configurable buffer menu. |
538 |
@end menu |
@end menu |