aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChong Yidong2011-10-07 12:22:04 -0400
committerChong Yidong2011-10-07 12:22:04 -0400
commitde0bde6284da06b603b578cc5d19002fd15f928d (patch)
tree17a8c6b94b18d9173ccf23fcf39e25efadc051a6
parentc383327999c7bd66492878122fd2867acdeb9a23 (diff)
downloademacs-de0bde6284da06b603b578cc5d19002fd15f928d.tar.gz
emacs-de0bde6284da06b603b578cc5d19002fd15f928d.zip
Copyedits and updates for Emacs manual's first few chapters.
* doc/emacs/basic.texi (Inserting Text): Add xref to Completion. Add ucs-insert example, and document prefix argument. (Moving Point): Fix introduction; C-f/C-b are no longer equivalent to left/right. Tweak left-char and right-char descriptions. M-left and M-right are now bound to left-word/right-word. (Erasing): Document delete-forward-char. * doc/emacs/commands.texi (User Input): Define "input event" more clearly. (Keys): Add xref to Echo Area. (Commands): Clarify relation between commands and functions. * doc/emacs/entering.texi (Entering Emacs): Define "startup screen". Document window-splitting behavior with command-line inputs. (Exiting): Remove obsolete paragraph about shells without suspend functionality. * doc/emacs/frames.texi (Non-Window Terminals): Index just "text-only terminal", which is used throughout the manual now. * doc/emacs/screen.texi (Screen, Menu Bar): Copyedits. (Point): Remove duplicate paragraph on cursors, also in Screen. (Mode Line): Trailing dashes no longer shown on X displays.
-rw-r--r--admin/FOR-RELEASE6
-rw-r--r--doc/emacs/ChangeLog25
-rw-r--r--doc/emacs/basic.texi330
-rw-r--r--doc/emacs/commands.texi116
-rw-r--r--doc/emacs/entering.texi117
-rw-r--r--doc/emacs/frames.texi3
-rw-r--r--doc/emacs/screen.texi320
-rw-r--r--etc/NEWS10
8 files changed, 483 insertions, 444 deletions
diff --git a/admin/FOR-RELEASE b/admin/FOR-RELEASE
index e1c25ef07f3..4481d8cd93b 100644
--- a/admin/FOR-RELEASE
+++ b/admin/FOR-RELEASE
@@ -158,7 +158,7 @@ building.texi
158calendar.texi 158calendar.texi
159cal-xtra.texi 159cal-xtra.texi
160cmdargs.texi 160cmdargs.texi
161commands.texi 161commands.texi cyd
162custom.texi 162custom.texi
163dired.texi 163dired.texi
164dired-xtra.texi 164dired-xtra.texi
@@ -166,7 +166,7 @@ display.texi
166emacs.texi 166emacs.texi
167emacs-xtra.texi 167emacs-xtra.texi
168emerge-xtra.texi 168emerge-xtra.texi
169entering.texi 169entering.texi cyd
170files.texi 170files.texi
171fixit.texi 171fixit.texi
172fortran-xtra.texi 172fortran-xtra.texi
@@ -190,7 +190,7 @@ picture-xtra.texi
190programs.texi 190programs.texi
191regs.texi 191regs.texi
192rmail.texi 192rmail.texi
193screen.texi 193screen.texi cyd
194search.texi 194search.texi
195sending.texi 195sending.texi
196text.texi 196text.texi
diff --git a/doc/emacs/ChangeLog b/doc/emacs/ChangeLog
index ea124fb4402..dc331eeb612 100644
--- a/doc/emacs/ChangeLog
+++ b/doc/emacs/ChangeLog
@@ -1,3 +1,28 @@
12011-10-07 Chong Yidong <cyd@stupidchicken.com>
2
3 * basic.texi (Inserting Text): Add xref to Completion. Add
4 ucs-insert example, and document prefix argument.
5 (Moving Point): Fix introduction; C-f/C-b are no longer equivalent
6 to left/right. Tweak left-char and right-char descriptions.
7 M-left and M-right are now bound to left-word/right-word.
8 (Erasing): Document delete-forward-char.
9
10 * screen.texi (Screen, Menu Bar): Copyedits.
11 (Point): Remove duplicate paragraph on cursors, also in Screen.
12 (Mode Line): Trailing dashes no longer shown on X displays.
13
14 * frames.texi (Non-Window Terminals): Index just "text-only
15 terminal", which is used throughout the manual now.
16
17 * entering.texi (Entering Emacs): Define "startup screen".
18 Document window-splitting behavior with command-line inputs.
19 (Exiting): Remove obsolete paragraph about shells without suspend
20 functionality.
21
22 * commands.texi (User Input): Define "input event" more clearly.
23 (Keys): Add xref to Echo Area.
24 (Commands): Clarify relation between commands and functions.
25
12011-10-06 Chong Yidong <cyd@stupidchicken.com> 262011-10-06 Chong Yidong <cyd@stupidchicken.com>
2 27
3 * misc.texi (emacsclient Options): Document how emacsclient runs 28 * misc.texi (emacsclient Options): Document how emacsclient runs
diff --git a/doc/emacs/basic.texi b/doc/emacs/basic.texi
index 8c8708a3b51..52f9395cedc 100644
--- a/doc/emacs/basic.texi
+++ b/doc/emacs/basic.texi
@@ -10,7 +10,7 @@
10 Here we explain the basics of how to enter text, make corrections, 10 Here we explain the basics of how to enter text, make corrections,
11and save the text in a file. If this material is new to you, we 11and save the text in a file. If this material is new to you, we
12suggest you first run the Emacs learn-by-doing tutorial, by typing 12suggest you first run the Emacs learn-by-doing tutorial, by typing
13@kbd{Control-h t} inside Emacs. (@code{help-with-tutorial}). 13@kbd{C-h t} (@code{help-with-tutorial}).
14 14
15@menu 15@menu
16 16
@@ -41,20 +41,20 @@ forward, so that point remains just after the inserted text.
41 41
42@kindex RET 42@kindex RET
43@cindex newline 43@cindex newline
44 To end a line and start a new one, type @key{RET}. This key may be 44 To end a line and start a new one, type @key{RET} (@code{newline}).
45labeled @key{Return} or @key{Enter} on your keyboard, but we refer to 45(The @key{RET} key may be labeled @key{Return} or @key{Enter} on your
46it as @key{RET} in this manual. Pressing it inserts a newline 46keyboard, but we refer to it as @key{RET} in this manual.) This
47character in the buffer. If point is at the end of the line, this 47command inserts a newline character into the buffer. If point is at
48creates a new blank line after it; if point is in the middle of a 48the end of the line, the effect is to create a new blank line after
49line, the line is split at that position. 49it; if point is in the middle of a line, the line is split at that
50position.
50 51
51 As we explain later in this manual, you can change the way Emacs 52 As we explain later in this manual, you can change the way Emacs
52handles text insertion by turning on @dfn{minor modes}. For instance, 53handles text insertion by turning on @dfn{minor modes}. For instance,
53if you turn on a minor mode called @dfn{Auto Fill} mode, Emacs can 54the minor mode called Auto Fill mode splits lines automatically when
54split lines automatically when they become too long (@pxref{Filling}). 55they get too long (@pxref{Filling}). The minor mode called Overwrite
55If you turn on a minor mode called @dfn{Overwrite} mode, inserted 56mode causes inserted characters to replace (overwrite) existing text,
56characters replace (overwrite) existing text, instead of shoving it to 57instead of shoving it to the right. @xref{Minor Modes}.
57the right. @xref{Minor Modes}.
58 58
59@cindex quoting 59@cindex quoting
60@kindex C-q 60@kindex C-q
@@ -80,9 +80,10 @@ literal @samp{DEL} character.
80@kbd{C-q} followed by a sequence of octal digits inserts the character 80@kbd{C-q} followed by a sequence of octal digits inserts the character
81with the specified octal character code. You can use any number of 81with the specified octal character code. You can use any number of
82octal digits; any non-digit terminates the sequence. If the 82octal digits; any non-digit terminates the sequence. If the
83terminating character is @key{RET}, it serves only to terminate the 83terminating character is @key{RET}, that @key{RET} serves only to
84sequence. Any other non-digit terminates the sequence and then acts 84terminate the sequence. Any other non-digit terminates the sequence
85as normal input---thus, @kbd{C-q 1 0 1 B} inserts @samp{AB}. 85and then acts as normal input---thus, @kbd{C-q 1 0 1 B} inserts
86@samp{AB}.
86 87
87The use of octal sequences is disabled in ordinary non-binary 88The use of octal sequences is disabled in ordinary non-binary
88Overwrite mode, to give you a convenient way to insert a digit instead 89Overwrite mode, to give you a convenient way to insert a digit instead
@@ -96,21 +97,28 @@ To use decimal or hexadecimal instead of octal, set the variable
96the letters @kbd{a} to @kbd{f} serve as part of a character code, 97the letters @kbd{a} to @kbd{f} serve as part of a character code,
97just like digits. Case is ignored. 98just like digits. Case is ignored.
98 99
99 A numeric argument tells @kbd{C-q} how many copies of the quoted
100character to insert (@pxref{Arguments}).
101
102@findex ucs-insert 100@findex ucs-insert
103@kindex C-x 8 RET 101@kindex C-x 8 RET
104@cindex Unicode characters, inserting 102@cindex Unicode characters, inserting
105@cindex insert Unicode character 103@cindex insert Unicode character
106@cindex characters, inserting by name or code-point 104@cindex characters, inserting by name or code-point
107 Instead of @kbd{C-q}, you can use @kbd{C-x 8 @key{RET}} 105 Instead of @kbd{C-q}, you can use the command @kbd{C-x 8 @key{RET}}
108(@code{ucs-insert}) to insert a character based on its Unicode name or 106(@code{ucs-insert}). This prompts for the Unicode name or code-point
109code-point. This command prompts for a character to insert, using 107of a character, using the minibuffer. If you enter a name, the
110the minibuffer; you can specify the character using either (i) the 108command provides completion (@pxref{Completion}). If you enter a
111character's name in the Unicode standard, or (ii) the character's 109code-point, it should be a hexadecimal number (which is the convention
112code-point in the Unicode standard. If you specify the character's 110for Unicode). The command then inserts the corresponding character
113name, the command provides completion. 111into the buffer. For example, both of the following insert the
112infinity sign (Unicode code-point @code{#x221E}):
113
114@example
115@kbd{C-x 8 @key{RET} infinity @key{RET}}
116@kbd{C-x 8 @key{RET} 221e @key{RET}}
117@end example
118
119 A numeric argument to either @kbd{C-q} or @kbd{C-x 8 @key{RET}}
120specifies how many copies of the character to insert
121(@pxref{Arguments}).
114 122
115@node Moving Point 123@node Moving Point
116@section Changing the Location of Point 124@section Changing the Location of Point
@@ -123,85 +131,104 @@ name, the command provides completion.
123 To do more than insert characters, you have to know how to move 131 To do more than insert characters, you have to know how to move
124point (@pxref{Point}). The keyboard commands @kbd{C-f}, @kbd{C-b}, 132point (@pxref{Point}). The keyboard commands @kbd{C-f}, @kbd{C-b},
125@kbd{C-n}, and @kbd{C-p} move point to the right, left, up and down 133@kbd{C-n}, and @kbd{C-p} move point to the right, left, up and down
126respectively. These are equivalent to the commands @kbd{@key{right}}, 134respectively. You can also move point using the @dfn{arrow keys}
127@kbd{@key{left}}, @kbd{@key{down}}, and @kbd{@key{up}}, entered using 135present on most keyboards: @kbd{@key{right}}, @kbd{@key{left}},
128the @dfn{arrow keys} present on many keyboards. Many Emacs users find 136@kbd{@key{down}}, and @kbd{@key{up}}; however, many Emacs users find
129that it is slower to use the arrow keys than the equivalent control 137that it is slower to use the arrow keys than the control keys.
130keys. You can also click the left mouse button to move point to the 138
139 You can also click the left mouse button to move point to the
131position clicked. Emacs also provides a variety of additional 140position clicked. Emacs also provides a variety of additional
132keyboard commands that move point in more sophisticated ways. 141keyboard commands that move point in more sophisticated ways.
133 142
134@kindex C-a 143@table @kbd
135@kindex C-e 144
145@item C-f
136@kindex C-f 146@kindex C-f
137@kindex C-b
138@kindex C-n
139@kindex C-p
140@kindex M->
141@kindex M-<
142@kindex M-r
143@kindex LEFT
144@kindex RIGHT
145@kindex UP
146@kindex DOWN
147@findex move-beginning-of-line
148@findex move-end-of-line
149@findex forward-char 147@findex forward-char
150@findex backward-char 148Move forward one character (@code{forward-char}).
149
150@item @key{right}
151@kindex RIGHT
151@findex right-char 152@findex right-char
153This command (@code{right-char}) behaves like @kbd{C-f}, with one
154exception: when editing right-to-left scripts such as Arabic, it
155instead moves @emph{backward} if the current paragraph is a
156right-to-left paragraph. @xref{Bidirectional Editing}.
157
158@item C-b
159@kindex C-b
160@findex backward-char
161Move backward one character (@code{backward-char}).
162
163@item @key{left}
164@kindex LEFT
152@findex left-char 165@findex left-char
166This command (@code{left-char}) behaves like @kbd{C-b}, except it
167moves @emph{forward} if the current paragraph is right-to-left.
168@xref{Bidirectional Editing}.
169
170@item C-n
171@itemx @key{down}
172@kindex C-n
173@kindex DOWN
153@findex next-line 174@findex next-line
175Move down one screen line (@code{next-line}). This command attempts
176to keep the horizontal position unchanged, so if you start in the
177middle of one line, you move to the middle of the next.
178
179@item C-p
180@itemx @key{up}
181@kindex C-p
182@kindex UP
154@findex previous-line 183@findex previous-line
155@findex beginning-of-buffer 184Move up one screen line (@code{previous-line}). This command
156@findex end-of-buffer 185preserves position within the line, like @kbd{C-n}.
157@findex goto-char 186
158@findex goto-line
159@findex move-to-window-line
160@table @kbd
161@item C-a 187@item C-a
162@itemx @key{Home} 188@itemx @key{Home}
189@kindex C-a
190@kindex HOME
191@findex move-beginning-of-line
163Move to the beginning of the line (@code{move-beginning-of-line}). 192Move to the beginning of the line (@code{move-beginning-of-line}).
193
164@item C-e 194@item C-e
165@itemx @key{End} 195@itemx @key{End}
196@kindex C-e
197@kindex END
198@findex move-end-of-line
166Move to the end of the line (@code{move-end-of-line}). 199Move to the end of the line (@code{move-end-of-line}).
167@item C-f 200
168Move forward one character (@code{forward-char}).
169@item @key{right}
170Move one character to the right (@code{right-char}). This
171moves one character forward in text that is read in the usual
172left-to-right direction, but one character @emph{backward} if the text
173is read right-to-left, as needed for right-to-left scripts such as
174Arabic. @xref{Bidirectional Editing}.
175@item C-b
176Move backward one character (@code{backward-char}).
177@item @key{left}
178Move one character to the left (@code{left-char}). This
179moves one character backward in left-to-right text and one character
180forward in right-to-left text.
181@item M-f 201@item M-f
182@itemx M-@key{right} 202@kindex M-f
203@findex forward-word
183Move forward one word (@code{forward-word}). 204Move forward one word (@code{forward-word}).
205
184@item C-@key{right} 206@item C-@key{right}
185Move one word to the right (@code{right-word}). This moves one word 207@itemx M-@key{right}
186forward in left-to-right text and one word backward in right-to-left 208@kindex C-RIGHT
187text. 209@kindex M-RIGHT
210@findex right-word
211This command (@code{right-word}) behaves like @kbd{M-f}, except it
212moves @emph{backward} by one word if the current paragraph is
213right-to-left. @xref{Bidirectional Editing}.
214
188@item M-b 215@item M-b
189@itemx M-@key{left} 216@kindex M-b
217@findex backward-word
190Move backward one word (@code{backward-word}). 218Move backward one word (@code{backward-word}).
219
191@item C-@key{left} 220@item C-@key{left}
192Move one word to the left (@code{left-word}). This moves one word 221@itemx M-@key{left}
193backward in left-to-right text and one word forward in right-to-left 222@kindex C-LEFT
194text. 223@kindex M-LEFT
195@item C-n 224@findex left-word
196@itemx @key{down} 225This command (@code{left-word}) behaves like @kbd{M-f}, except it
197Move down one screen line (@code{next-line}). This command attempts 226moves @emph{forward} by one word if the current paragraph is
198to keep the horizontal position unchanged, so if you start in the 227right-to-left. @xref{Bidirectional Editing}.
199middle of one line, you move to the middle of the next. 228
200@item C-p
201@itemx @key{up}
202Move up one screen line (@code{previous-line}). This command
203preserves position within the line, like @kbd{C-n}.
204@item M-r 229@item M-r
230@kindex M-r
231@findex move-to-window-line-top-bottom
205Without moving the text on the screen, reposition point on the left 232Without moving the text on the screen, reposition point on the left
206margin of the center-most text line of the window; on subsequent 233margin of the center-most text line of the window; on subsequent
207consecutive invocations, move point to the left margin of the top-most 234consecutive invocations, move point to the left margin of the top-most
@@ -211,13 +238,18 @@ line, the bottom-most line, and so forth, in cyclic order
211A numeric argument says which screen line to place point on, counting 238A numeric argument says which screen line to place point on, counting
212downward from the top of the window (zero means the top line). A 239downward from the top of the window (zero means the top line). A
213negative argument counts lines up from the bottom (@minus{}1 means the 240negative argument counts lines up from the bottom (@minus{}1 means the
214bottom line). 241bottom line). @xref{Arguments}, for more information on numeric
242arguments.
215 243
216@item M-< 244@item M-<
245@kindex M-<
246@findex beginning-of-buffer
217Move to the top of the buffer (@code{beginning-of-buffer}). With 247Move to the top of the buffer (@code{beginning-of-buffer}). With
218numeric argument @var{n}, move to @var{n}/10 of the way from the top. 248numeric argument @var{n}, move to @var{n}/10 of the way from the top.
219@xref{Arguments}, for more information on numeric arguments.@refill 249
220@item M-> 250@item M->
251@kindex M->
252@findex end-of-buffer
221Move to the end of the buffer (@code{end-of-buffer}). 253Move to the end of the buffer (@code{end-of-buffer}).
222 254
223@item C-v 255@item C-v
@@ -233,10 +265,15 @@ Scroll one screen backward, and move point onscreen if necessary
233(@code{scroll-down-command}). @xref{Scrolling}. 265(@code{scroll-down-command}). @xref{Scrolling}.
234 266
235@item M-x goto-char 267@item M-x goto-char
268@findex goto-char
236Read a number @var{n} and move point to buffer position @var{n}. 269Read a number @var{n} and move point to buffer position @var{n}.
237Position 1 is the beginning of the buffer. 270Position 1 is the beginning of the buffer.
271
238@item M-g M-g 272@item M-g M-g
239@itemx M-g g 273@itemx M-g g
274@kindex M-g M-g
275@kindex M-g g
276@findex goto-line
240Read a number @var{n} and move point to the beginning of line number 277Read a number @var{n} and move point to the beginning of line number
241@var{n} (@code{goto-line}). Line 1 is the beginning of the buffer. If 278@var{n} (@code{goto-line}). Line 1 is the beginning of the buffer. If
242point is on or just after a number in the buffer, that is the default 279point is on or just after a number in the buffer, that is the default
@@ -244,14 +281,16 @@ for @var{n}. Just type @key{RET} in the minibuffer to use it. You can
244also specify @var{n} by giving @kbd{M-g M-g} a numeric prefix argument. 281also specify @var{n} by giving @kbd{M-g M-g} a numeric prefix argument.
245@xref{Select Buffer}, for the behavior of @kbd{M-g M-g} when you give it 282@xref{Select Buffer}, for the behavior of @kbd{M-g M-g} when you give it
246a plain prefix argument. 283a plain prefix argument.
284
247@item C-x C-n 285@item C-x C-n
248@findex set-goal-column
249@kindex C-x C-n 286@kindex C-x C-n
287@findex set-goal-column
250Use the current column of point as the @dfn{semipermanent goal column} 288Use the current column of point as the @dfn{semipermanent goal column}
251for @kbd{C-n} and @kbd{C-p} (@code{set-goal-column}). When a 289for @kbd{C-n} and @kbd{C-p} (@code{set-goal-column}). When a
252semipermanent goal column is in effect, those commands always try to 290semipermanent goal column is in effect, those commands always try to
253move to this column, or as close as possible to it, after moving 291move to this column, or as close as possible to it, after moving
254vertically. The goal column remains in effect until canceled. 292vertically. The goal column remains in effect until canceled.
293
255@item C-u C-x C-n 294@item C-u C-x C-n
256Cancel the goal column. Henceforth, @kbd{C-n} and @kbd{C-p} try to 295Cancel the goal column. Henceforth, @kbd{C-n} and @kbd{C-p} try to
257preserve the horizontal position, as usual. 296preserve the horizontal position, as usual.
@@ -266,9 +305,8 @@ can force these commands to move according to @dfn{logical lines}
266(i.e., according to the text lines in the buffer) by setting the 305(i.e., according to the text lines in the buffer) by setting the
267variable @code{line-move-visual} to @code{nil}; if a logical line 306variable @code{line-move-visual} to @code{nil}; if a logical line
268occupies multiple screen lines, the cursor then skips over the 307occupies multiple screen lines, the cursor then skips over the
269additional screen lines. Moving by logical lines was the default 308additional screen lines. For details, see @ref{Continuation Lines}.
270behavior prior to Emacs 23.1. For details, see @ref{Continuation 309@xref{Variables}, for how to set variables such as
271Lines}. @xref{Variables}, for how to set variables such as
272@code{line-move-visual}. 310@code{line-move-visual}.
273 311
274 Unlike @kbd{C-n} and @kbd{C-p}, most of the Emacs commands that work 312 Unlike @kbd{C-n} and @kbd{C-p}, most of the Emacs commands that work
@@ -288,21 +326,30 @@ the end of the next logical line. Normally, @code{track-eol} is
288 326
289@vindex next-line-add-newlines 327@vindex next-line-add-newlines
290 @kbd{C-n} normally stops at the end of the buffer when you use it on 328 @kbd{C-n} normally stops at the end of the buffer when you use it on
291the last line of the buffer. However, if you set the variable 329the last line in the buffer. However, if you set the variable
292@code{next-line-add-newlines} to a non-@code{nil} value, @kbd{C-n} on 330@code{next-line-add-newlines} to a non-@code{nil} value, @kbd{C-n} on
293the last line of a buffer creates an additional line at the end and 331the last line of a buffer creates an additional line at the end and
294moves down into it. 332moves down into it.
295 333
296@node Erasing 334@node Erasing
297@section Erasing Text 335@section Erasing Text
336@cindex killing characters and lines
337@cindex deleting characters and lines
338@cindex erasing characters and lines
298 339
299@table @kbd 340@table @kbd
300@item @key{DEL} 341@item @key{DEL}
301@itemx @key{Backspace} 342@itemx @key{Backspace}
302Delete the character before point (@code{delete-backward-char}). 343Delete the character before point, or the region if it is active
303@item C-d 344(@code{delete-backward-char}).
345
304@itemx @key{Delete} 346@itemx @key{Delete}
347Delete the character after point, or the region if it is active
348(@code{delete-forward-char}).
349
350@item C-d
305Delete the character after point (@code{delete-char}). 351Delete the character after point (@code{delete-char}).
352
306@item C-k 353@item C-k
307Kill to the end of the line (@code{kill-line}). 354Kill to the end of the line (@code{kill-line}).
308@item M-d 355@item M-d
@@ -312,37 +359,40 @@ Kill back to the beginning of the previous word
312(@code{backward-kill-word}). 359(@code{backward-kill-word}).
313@end table 360@end table
314 361
315 The key @kbd{@key{DEL}} (@code{delete-backward-char}) removes the 362 The @kbd{@key{DEL}} (@code{delete-backward-char}) command removes
316character before point, moving the cursor and all the characters after 363the character before point, moving the cursor and the characters after
317it backwards. On most keyboards, @key{DEL} is labelled 364it backwards. If point was at the beginning of a line, this deletes
318@key{Backspace}, but we refer to it as @key{DEL} in this manual. Do 365the preceding newline, joining this line to the previous one.
319not confuse @key{DEL} with another key, labelled @key{Delete}, that
320exists on many keyboards; we will discuss @key{Delete} momentarily.
321 366
322 Typing @key{DEL} when the cursor is at the beginning of a line 367 If, however, the region is active, @kbd{@key{DEL}} instead deletes
323deletes the preceding newline character, joining the line with the one 368the text in the region. @xref{Mark}, for a description of the region.
324before it.
325 369
326 On some text-only terminals, Emacs may not recognize the @key{DEL} 370 On most keyboards, @key{DEL} is labelled @key{Backspace}, but we
327key properly. If @key{DEL} does not do the right thing (e.g., if it 371refer to it as @key{DEL} in this manual. (Do not confuse @key{DEL}
328deletes characters forwards), see @ref{DEL Does Not Delete}. 372with the @key{Delete} key; we will discuss @key{Delete} momentarily.)
373On some text-only terminals, Emacs may not recognize the @key{DEL} key
374properly. @xref{DEL Does Not Delete}, if you encounter this problem.
329 375
330@cindex killing characters and lines 376 The @key{delete} (@code{delete-forward-char}) command deletes in the
331@cindex deleting characters and lines 377``opposite direction'': it deletes the character after point, i.e. the
332@cindex erasing characters and lines 378character under the cursor. If point was at the end of a line, this
333 The key @kbd{C-d} (@code{delete-char}) deletes the character after 379joins the following line onto this one. Like @kbd{@key{DEL}}, it
334point, i.e., the character under the cursor. This shifts the rest of 380deletes the text in the region if the region is active (@pxref{Mark}).
335the text on the line to the left. If you type @kbd{C-d} at the end of
336a line, it joins that line with the following line. This command is
337also bound to the key labelled @key{Delete} on many keyboards.
338 381
339 To erase a larger amount of text, use the @kbd{C-k} key, which 382 @kbd{C-d} (@code{delete-char}) deletes the character after point,
340erases (kills) a line at a time. If you type @kbd{C-k} at the 383similar to @key{delete}, but regardless of whether the region is
341beginning or middle of a line, it kills all the text up to the end of 384active.
342the line. If you type @kbd{C-k} at the end of a line, it joins that
343line with the following line.
344 385
345 To learn more about killing text, see @ref{Killing}. 386 @xref{Deletion}, for more detailed information about the above
387deletion commands.
388
389 @kbd{C-k} (@code{kill-line}) erases (kills) a line at a time. If
390you type @kbd{C-k} at the beginning or middle of a line, it kills all
391the text up to the end of the line. If you type @kbd{C-k} at the end
392of a line, it joins that line with the following line.
393
394 @xref{Killing}, for more information about @kbd{C-k} and related
395commands.
346 396
347@node Basic Undo 397@node Basic Undo
348@section Undoing Changes 398@section Undoing Changes
@@ -352,7 +402,7 @@ line with the following line.
352Undo one entry of the undo records---usually, one command worth 402Undo one entry of the undo records---usually, one command worth
353(@code{undo}). 403(@code{undo}).
354@itemx C-x u 404@itemx C-x u
355@item C-_ 405@itemx C-_
356The same. 406The same.
357@end table 407@end table
358 408
@@ -379,10 +429,7 @@ command displays an error message and does nothing.
379 429
380 Text that you insert in an Emacs buffer lasts only as long as the 430 Text that you insert in an Emacs buffer lasts only as long as the
381Emacs session. To keep any text permanently, you must put it in a 431Emacs session. To keep any text permanently, you must put it in a
382@dfn{file}. Files are named units of text which are stored by the 432@dfn{file}.
383operating system for you to retrieve later by name. To use the
384contents of a file in any way, including editing it with Emacs, you
385must specify the file name.
386 433
387 Suppose there is a file named @file{test.emacs} in your home 434 Suppose there is a file named @file{test.emacs} in your home
388directory. To begin editing this file in Emacs, type 435directory. To begin editing this file in Emacs, type
@@ -417,14 +464,15 @@ first time you save this buffer with @kbd{C-x C-s}.
417@section Help 464@section Help
418 465
419@cindex getting help with keys 466@cindex getting help with keys
420 If you forget what a key does, you can find out with the Help 467 If you forget what a key does, you can find out by typing @kbd{C-h
421character, which is @kbd{C-h} (or @key{F1}, which is an alias for 468k} (@code{describe-key}), followed by the key of interest; for
422@kbd{C-h}). Type @kbd{C-h k}, followed by the key of interest; for 469example, @kbd{C-h k C-n} tells you what @kbd{C-n} does.
423example, @kbd{C-h k C-n} tells you what @kbd{C-n} does. @kbd{C-h} is 470
424a prefix key; @kbd{C-h k} is just one of its subcommands (the command 471 The prefix key @kbd{C-h} stands for ``help''. The key @key{F1}
425@code{describe-key}). The other subcommands of @kbd{C-h} provide 472serves as an alias for @kbd{C-h}. Apart from @kbd{C-h k}, there are
426different kinds of help. Type @kbd{C-h} twice to get a description of 473many other help commands providing different kinds of help.
427all the help facilities. @xref{Help}. 474
475 @xref{Help}, for details.
428 476
429@node Blank Lines 477@node Blank Lines
430@section Blank Lines 478@section Blank Lines
@@ -532,12 +580,17 @@ Display the line number of point in the whole buffer.
532@itemx M-x column-number-mode 580@itemx M-x column-number-mode
533Toggle automatic display of the current line number or column number. 581Toggle automatic display of the current line number or column number.
534@xref{Optional Mode Line}. 582@xref{Optional Mode Line}.
535@item M-x count-lines-region 583
536Display the number of lines in the current region. Normally bound to 584@item M-=
537@kbd{M-=}, except in a few specialist modes. @xref{Mark}, for 585Display the number of lines in the region (@code{count-lines-region}).
538information about the region. 586@xref{Mark}, for information about the region.
587
588@item C-x l
589Display the number of lines in the current page
590(@code{count-lines-page}). @xref{Pages}.
591
539@item M-x count-words-region 592@item M-x count-words-region
540Display the number of words in the current region. 593Display the number of words in the region.
541@item C-x = 594@item C-x =
542Display the character code of character after point, character position of 595Display the character code of character after point, character position of
543point, and column of point (@code{what-cursor-position}). 596point, and column of point (@code{what-cursor-position}).
@@ -569,9 +622,10 @@ counts lines within the page, showing both numbers in the echo area.
569 622
570@kindex M-= 623@kindex M-=
571@findex count-lines-region 624@findex count-lines-region
572 Use @kbd{M-x count-lines-region} (normally bound to @kbd{M-=}) to 625 @kbd{M-=} (@code{count-lines-region}) displays the number of lines
573display the number of lines in the region (@pxref{Mark}). @xref{Pages}, 626in the region (@pxref{Mark}), while @kbd{C-x l}
574for the command @kbd{C-x l} which counts the lines in the current page. 627(@code{count-lines-page}) counts the lines in the current page
628(@pxref{Pages}).
575 629
576@kindex C-x = 630@kindex C-x =
577@findex what-cursor-position 631@findex what-cursor-position
diff --git a/doc/emacs/commands.texi b/doc/emacs/commands.texi
index cff725027e9..de6e7539c27 100644
--- a/doc/emacs/commands.texi
+++ b/doc/emacs/commands.texi
@@ -23,25 +23,21 @@ input.
23@cindex @acronym{ASCII} 23@cindex @acronym{ASCII}
24@cindex C- 24@cindex C-
25@cindex Control 25@cindex Control
26@cindex control characters
27 26
28 GNU Emacs is primarily designed for use with the keyboard. While it 27 GNU Emacs is primarily designed for use with the keyboard. While it
29is possible to use the mouse to issue editing commands through the 28is possible to use the mouse to issue editing commands through the
30menu bar and tool bar, that is not as efficient as using the keyboard. 29menu bar and tool bar, that is not as efficient as using the keyboard.
31Therefore, this manual mainly documents how to edit with the keyboard. 30Therefore, this manual mainly documents how to edit with the keyboard.
32 31
32@cindex control character
33 Keyboard input into Emacs is based on a heavily-extended version of 33 Keyboard input into Emacs is based on a heavily-extended version of
34@acronym{ASCII}. The simplest characters that you can input into 34@acronym{ASCII}. Simple characters, like @samp{a}, @samp{B},
35Emacs correspond to graphic symbols such as @samp{a}, @samp{B}, 35@samp{3}, @samp{=}, and the space character (denoted as @key{SPC}),
36@samp{3}, @samp{=}, the space character (conventionally denoted as 36are entered by typing the corresponding key. @dfn{Control
37@key{SPC}), and so on. Entering these using the keyboard is 37characters}, such as @key{RET}, @key{TAB}, @key{DEL}, @key{ESC},
38straightforward. Certain characters found on non-English keyboards 38@key{F1}, @key{Home}, and @key{left}, are also entered this way, as
39also fall into this category (@pxref{International}). 39are certain characters found on non-English keyboards
40 40(@pxref{International}).
41 In addition to these simple characters, Emacs recognizes
42@dfn{control characters} such as @key{RET}, @key{TAB}, @key{DEL},
43@key{ESC}, @key{F1}, @key{Home}, @key{left}, etc. Most keyboards have
44special keys for entering these.
45 41
46@cindex modifier keys 42@cindex modifier keys
47@cindex Control 43@cindex Control
@@ -50,13 +46,14 @@ special keys for entering these.
50@cindex M- 46@cindex M-
51 Emacs also recognizes control characters that are entered using 47 Emacs also recognizes control characters that are entered using
52@dfn{modifier keys}. Two commonly-used modifier keys are 48@dfn{modifier keys}. Two commonly-used modifier keys are
53@key{Control} (which is usually labelled as @key{Ctrl}), and 49@key{Control} (usually labelled @key{Ctrl}), and @key{Meta} (usually
54@key{Meta} (which is usually labeled as @key{Alt})@footnote{We refer 50labeled @key{Alt})@footnote{We refer to @key{Alt} as @key{Meta} for
55to @key{Alt} as @key{Meta} for historical reasons.}. For example, 51historical reasons.}. For example, @kbd{Control-a} is entered by
56@kbd{Control-a} is entered by holding down the @key{Ctrl} key while 52holding down the @key{Ctrl} key while pressing @kbd{a}; we will refer
57pressing @kbd{a}; we will refer to this as @kbd{C-a} for short. 53to this as @kbd{C-a} for short. Similarly @kbd{Meta-a}, or @kbd{M-a}
58Similarly @kbd{Meta-a}, or @kbd{M-a} for short, is entered by holding 54for short, is entered by holding down the @key{Alt} key and pressing
59down the @key{Alt} key and pressing @kbd{a}. 55@kbd{a}. Modifier keys can also be applied to non-alphanumerical
56characters, e.g. @kbd{C-@key{F1}} or @kbd{M-@key{left}}.
60 57
61@cindex @key{ESC} replacing @key{Meta} key 58@cindex @key{ESC} replacing @key{Meta} key
62 You can also type Meta characters using two-character sequences 59 You can also type Meta characters using two-character sequences
@@ -68,33 +65,28 @@ character; instead, press @key{ESC} and release it, then enter the
68next character. This feature is useful on certain text-only terminals 65next character. This feature is useful on certain text-only terminals
69where the @key{Meta} key does not function reliably. 66where the @key{Meta} key does not function reliably.
70 67
71 Modifier keys can apply not only to alphanumerical characters, but
72also to special input characters, such as the arrow keys and mouse
73buttons.
74
75@cindex input event
76 @xref{Input Events,,, elisp, The Emacs Lisp Reference Manual}, for
77the full Lisp-level details about keyboard and mouse input, which are
78collectively referred to as @dfn{input events}. If you are not doing
79Lisp programming, but simply want to redefine the meaning of some
80characters or non-character events, see @ref{Customization}.
81
82@cindex keys stolen by window manager 68@cindex keys stolen by window manager
83@cindex window manager, keys stolen by 69@cindex window manager, keys stolen by
84 On graphical displays, the window manager is likely to block the 70 On graphical displays, the window manager might block some keyboard
85character @kbd{M-@key{TAB}} before Emacs can see it. It may also 71inputs, including @kbd{M-@key{TAB}}, @kbd{M-@key{SPC}}, @kbd{C-M-d}
86block @kbd{M-@key{SPC}}, @kbd{C-M-d} and @kbd{C-M-l}. If you have 72and @kbd{C-M-l}. If you have this problem, you can either customize
87these problems, we recommend that you customize your window manager to 73your window manager to not block those keys, or ``rebind'' the
88turn off those commands, or put them on key combinations that Emacs 74affected Emacs commands (@pxref{Customization}).
89does not use. 75
76@cindex input event
77 Simple characters and control characters, as well as certain
78non-keyboard inputs such as mouse clicks, are collectively referred to
79as @dfn{input events}. For details about how Emacs internally handles
80input events, see @ref{Input Events,,, elisp, The Emacs Lisp Reference
81Manual}.
90 82
91@node Keys, Commands, User Input, Top 83@node Keys, Commands, User Input, Top
92@section Keys 84@section Keys
93 85
94 Some Emacs commands are invoked by just one input event; for 86 Some Emacs commands are invoked by just one input event; for
95example, @kbd{C-f} moves forward one character in the buffer. But 87example, @kbd{C-f} moves forward one character in the buffer. Other
96Emacs also has commands that take two or more input events to invoke, 88commands take two or more input events to invoke, such as @kbd{C-x
97such as @kbd{C-x C-f} and @kbd{C-x 4 C-f}. 89C-f} and @kbd{C-x 4 C-f}.
98 90
99@cindex key 91@cindex key
100@cindex key sequence 92@cindex key sequence
@@ -106,23 +98,23 @@ invokes a command, we call it a @dfn{complete key}; for example,
106@kbd{C-f}, @kbd{C-x C-f} and @kbd{C-x 4 C-f} are all complete keys. 98@kbd{C-f}, @kbd{C-x C-f} and @kbd{C-x 4 C-f} are all complete keys.
107If a key sequence isn't long enough to invoke a command, we call it a 99If a key sequence isn't long enough to invoke a command, we call it a
108@dfn{prefix key}; from the preceding example, we see that @kbd{C-x} 100@dfn{prefix key}; from the preceding example, we see that @kbd{C-x}
109and @kbd{C-x 4} are prefix keys. Every key is either a complete key 101and @kbd{C-x 4} are prefix keys. Every key sequence is either a
110or a prefix key. 102complete key or a prefix key.
111 103
112 A prefix key combines with the following input event to make a 104 A prefix key combines with the following input event to make a
113longer key sequence, which may itself be complete or a prefix. For 105longer key sequence. For example, @kbd{C-x} is a prefix key, so
114example, @kbd{C-x} is a prefix key, so @kbd{C-x} and the next input 106typing @kbd{C-x} alone does not invoke a command; instead, Emacs waits
115event combine to make a two-event key sequence. This two-event key 107for further input (if you pause for longer than a second, it echoes
116sequence could itself be a prefix key (such as @kbd{C-x 4}), or a 108the @kbd{C-x} key to prompt for that input; @pxref{Echo Area}).
117complete key (such as @kbd{C-x C-f}). There is no limit to the length 109@kbd{C-x} combines with the next input event to make a two-event key
118of a key sequence, but in practice people rarely use sequences longer 110sequence, which could itself be a prefix key (such as @kbd{C-x 4}), or
119than three or four input events. 111a complete key (such as @kbd{C-x C-f}). There is no limit to the
120 112length of key sequences, but in practice they are seldom longer than
121 You can't add input events onto a complete key. For example, the 113three or four input events.
122two-event sequence @kbd{C-f C-k} is not a key, because the @kbd{C-f} 114
123is a complete key in itself, so @kbd{C-f C-k} cannot have an 115 You can't add input events onto a complete key. For example,
124independent meaning as a command. @kbd{C-f C-k} is two key sequences, 116because @kbd{C-f} is a complete key, the two-event sequence @kbd{C-f
125not one.@refill 117C-k} is two key sequences, not one.
126 118
127 By default, the prefix keys in Emacs are @kbd{C-c}, @kbd{C-h}, 119 By default, the prefix keys in Emacs are @kbd{C-c}, @kbd{C-h},
128@kbd{C-x}, @kbd{C-x @key{RET}}, @kbd{C-x @@}, @kbd{C-x a}, @kbd{C-x 120@kbd{C-x}, @kbd{C-x @key{RET}}, @kbd{C-x @@}, @kbd{C-x a}, @kbd{C-x
@@ -132,22 +124,20 @@ aliases for @kbd{C-h} and @kbd{C-x 6}.) This list is not cast in
132stone; if you customize Emacs, you can make new prefix keys. You 124stone; if you customize Emacs, you can make new prefix keys. You
133could even eliminate some of the standard ones, though this is not 125could even eliminate some of the standard ones, though this is not
134recommended for most users; for example, if you remove the prefix 126recommended for most users; for example, if you remove the prefix
135definition of @kbd{C-x 4}, then @kbd{C-x 4 @var{anything}} would 127definition of @kbd{C-x 4}, then @kbd{C-x 4 C-f} becomes an invalid key
136become an invalid key sequence. @xref{Key Bindings}. 128sequence. @xref{Key Bindings}.
137 129
138 Typing the help character (@kbd{C-h} or @key{F1}) after a prefix key 130 Typing the help character (@kbd{C-h} or @key{F1}) after a prefix key
139displays a list of the commands starting with that prefix. The sole 131displays a list of the commands starting with that prefix. The sole
140exception to this rule is @key{ESC}: @kbd{@key{ESC} C-h} is equivalent 132exception to this rule is @key{ESC}: @kbd{@key{ESC} C-h} is equivalent
141to @kbd{C-M-h}, which does something else entirely. You can, however, 133to @kbd{C-M-h}, which does something else entirely. You can, however,
142use @key{F1} to displays a list of the commands starting with 134use @key{F1} to display a list of commands starting with @key{ESC}.
143@key{ESC}.
144 135
145@node Commands, Entering Emacs, Keys, Top 136@node Commands, Entering Emacs, Keys, Top
146@section Keys and Commands 137@section Keys and Commands
147 138
148@cindex binding 139@cindex binding
149@cindex command 140@cindex command
150@cindex function definition
151 This manual is full of passages that tell you what particular keys 141 This manual is full of passages that tell you what particular keys
152do. But Emacs does not assign meanings to keys directly. Instead, 142do. But Emacs does not assign meanings to keys directly. Instead,
153Emacs assigns meanings to named @dfn{commands}, and then gives keys 143Emacs assigns meanings to named @dfn{commands}, and then gives keys
@@ -155,11 +145,9 @@ their meanings by @dfn{binding} them to commands.
155 145
156 Every command has a name chosen by a programmer. The name is 146 Every command has a name chosen by a programmer. The name is
157usually made of a few English words separated by dashes; for example, 147usually made of a few English words separated by dashes; for example,
158@code{next-line} or @code{forward-word}. A command also has a 148@code{next-line} or @code{forward-word}. Internally, each command is
159@dfn{function definition} which is a Lisp program; this is how the 149a special type of Lisp @dfn{function}, and the actions associated with
160command does its work. In Emacs Lisp, a command is a Lisp function 150the command are performed by running the function. @xref{What Is a
161with special properties that make it suitable for interactive use.
162For more information on commands and functions, see @ref{What Is a
163Function,, What Is a Function, elisp, The Emacs Lisp Reference 151Function,, What Is a Function, elisp, The Emacs Lisp Reference
164Manual}. 152Manual}.
165 153
diff --git a/doc/emacs/entering.texi b/doc/emacs/entering.texi
index 3c4a74c02b5..4a76f206aed 100644
--- a/doc/emacs/entering.texi
+++ b/doc/emacs/entering.texi
@@ -19,49 +19,45 @@
19 19
20 The usual way to invoke Emacs is with the shell command 20 The usual way to invoke Emacs is with the shell command
21@command{emacs}. From a terminal window running in the X Window 21@command{emacs}. From a terminal window running in the X Window
22System, you can also run Emacs in the background with 22System, you can run Emacs in the background with @command{emacs &};
23@command{emacs&}; this way, Emacs won't tie up the terminal window, so 23this way, Emacs won't tie up the terminal window, so you can use it to
24you can use it to run other shell commands. 24run other shell commands.
25 25
26@cindex startup screen 26@cindex startup screen
27 When Emacs starts up, the initial frame displays a special buffer 27 When Emacs starts up, the initial frame displays a special buffer
28named @samp{*GNU Emacs*}. This buffer contains some information about 28named @samp{*GNU Emacs*}. This @dfn{startup screen} contains
29Emacs, and includes @dfn{links} to common tasks that might be useful 29information about Emacs and @dfn{links} to common tasks that are
30to beginning users. For instance, activating the @samp{Emacs 30useful for beginning users. For instance, activating the @samp{Emacs
31Tutorial} link opens the Emacs tutorial; this does the same thing as 31Tutorial} link opens the Emacs tutorial; this does the same thing as
32the command @kbd{C-h t} (@code{help-with-tutorial}). To activate a 32the command @kbd{C-h t} (@code{help-with-tutorial}). To activate a
33link, either move point onto it and type @kbd{@key{RET}}, or click on 33link, either move point onto it and type @kbd{@key{RET}}, or click on
34it with @kbd{mouse-1} (the left mouse button). 34it with @kbd{mouse-1} (the left mouse button).
35 35
36 Using a command line argument, you can tell Emacs to visit one or 36 Using a command line argument, you can tell Emacs to visit one or
37more specific files as soon as it starts up. For example, 37more files as soon as it starts up. For example, @command{emacs
38@command{emacs foo.txt} starts Emacs with a buffer displaying the 38foo.txt} starts Emacs with a buffer displaying the contents of the
39contents of the file @samp{foo.txt}. This feature exists mainly for 39file @samp{foo.txt}. This feature exists mainly for compatibility
40compatibility with other editors, which are designed to edit one file 40with other editors, which are designed to be launched from the shell
41at a time: once you are done with that file, you exit the editor, and 41for short editing sessions. If you call Emacs this way, the initial
42start it again the next time you need it. 42frame is split into two windows---one showing the specified file, and
43 43the other showing the startup screen. @xref{Windows}.
44 Using Emacs in this way---starting it afresh each time you want to 44
45edit a file---is unnecessary and wasteful. Emacs can visit more than 45 Generally, it is unnecessary and wasteful to start Emacs afresh each
46one file in a single editing session, and exiting the Emacs session 46time you want to edit a file. The recommended way to use Emacs is to
47loses valuable accumulated context, such as the kill ring, registers, 47start it just once, just after you log in, and do all your editing in
48undo history, and mark ring. These features, described later in the 48the same Emacs session. @xref{Files}, for information on visiting
49manual, are useful for performing edits across multiple files, or 49more than one file. If you use Emacs this way, the Emacs session
50continuing edits to a single file. 50accumulates valuable context, such as the kill ring, registers, undo
51 51history, and mark ring data, which together make editing more
52 The recommended way to use Emacs is to start it only once, just 52convenient. These features are described later in the manual.
53after you log in, and do all your editing in the same Emacs session.
54Each time you edit a file, visit it with the existing Emacs, which
55eventually has many files in it ready for editing. @xref{Files}, for
56more information on visiting more than one file.
57 53
58 To edit a file from another program while Emacs is running, you can 54 To edit a file from another program while Emacs is running, you can
59use the @command{emacsclient} helper program to open a file in the 55use the @command{emacsclient} helper program to open a file in the
60already running Emacs. @xref{Emacs Server}. 56existing Emacs session. @xref{Emacs Server}.
61 57
62 Emacs accepts other command line arguments that tell it to load 58 Emacs accepts other command line arguments that tell it to load
63certain Lisp files, call certain functions, and so forth. These 59certain Lisp files, where to put the initial frame, and so forth.
64features exist mainly for advanced users. @xref{Emacs Invocation}. 60@xref{Emacs Invocation}.
65 61
66@vindex inhibit-startup-screen 62@vindex inhibit-startup-screen
67 If the variable @code{inhibit-startup-screen} is non-@code{nil}, 63 If the variable @code{inhibit-startup-screen} is non-@code{nil},
@@ -72,11 +68,10 @@ which can be used to evaluate Emacs Lisp expressions interactively.
72@xref{Lisp Interaction}. You can set the variable 68@xref{Lisp Interaction}. You can set the variable
73@code{inhibit-startup-screen} using the Customize facility 69@code{inhibit-startup-screen} using the Customize facility
74(@pxref{Easy Customization}), or by editing your initialization file 70(@pxref{Easy Customization}), or by editing your initialization file
75(@pxref{Init File}).@footnote{Note that setting 71(@pxref{Init File}).@footnote{Setting @code{inhibit-startup-screen} in
76@code{inhibit-startup-screen} in @file{site-start.el} doesn't work, 72@file{site-start.el} doesn't work, because the startup screen is set
77because the startup screen is set up before reading 73up before reading @file{site-start.el}. @xref{Init File}, for
78@file{site-start.el}. @xref{Init File}, for information about 74information about @file{site-start.el}.}
79@file{site-start.el}.}
80 75
81 You can also force Emacs to display a file or directory at startup 76 You can also force Emacs to display a file or directory at startup
82by setting the variable @code{initial-buffer-choice} to a 77by setting the variable @code{initial-buffer-choice} to a
@@ -105,13 +100,13 @@ On a text terminal, suspend Emacs; on a graphical display,
105@findex save-buffers-kill-terminal 100@findex save-buffers-kill-terminal
106 @dfn{Killing} Emacs means terminating the Emacs program. To do 101 @dfn{Killing} Emacs means terminating the Emacs program. To do
107this, type @kbd{C-x C-c} (@code{save-buffers-kill-terminal}). A 102this, type @kbd{C-x C-c} (@code{save-buffers-kill-terminal}). A
108two-character key is used to make it harder to type by accident. If 103two-character key sequence is used to make it harder to type by
109there are any modified file-visiting buffers when you type @kbd{C-x 104accident. If there are any modified file-visiting buffers when you
110C-c}, Emacs first offers to save these buffers. If you do not save 105type @kbd{C-x C-c}, Emacs first offers to save these buffers. If you
111them all, it asks for confirmation again, since the unsaved changes 106do not save them all, it asks for confirmation again, since the
112will be lost. Emacs also asks for confirmation if any subprocesses 107unsaved changes will be lost. Emacs also asks for confirmation if any
113are still running, since killing Emacs will also kill the subprocesses 108subprocesses are still running, since killing Emacs will also kill the
114(@pxref{Shell}). 109subprocesses (@pxref{Shell}).
115 110
116 @kbd{C-x C-c} behaves specially if you are using Emacs as a server. 111 @kbd{C-x C-c} behaves specially if you are using Emacs as a server.
117If you type it from a ``client frame'', it closes the client 112If you type it from a ``client frame'', it closes the client
@@ -135,39 +130,19 @@ default value of @code{confirm-kill-emacs} is @code{nil}.
135 To kill Emacs without being prompted about saving, type @kbd{M-x 130 To kill Emacs without being prompted about saving, type @kbd{M-x
136kill-emacs}. 131kill-emacs}.
137 132
138@cindex minimizing a frame
139@cindex iconifying
140@cindex suspending
141 You can ``exit'' Emacs in two other ways. On a graphical display,
142you can @dfn{minimize} (or @dfn{iconify}) an Emacs frame; depending on
143the window system, this either replaces the Emacs frame with a tiny
144``icon'' or conceals the frame entirely (@pxref{Frames}). On a
145text-only terminal, you can @dfn{suspend} Emacs; this means stopping
146the Emacs program temporarily, returning control to its parent process
147(usually a shell).
148
149@kindex C-z 133@kindex C-z
150@findex suspend-frame 134@findex suspend-frame
135@cindex minimizing
136@cindex iconifying
137@cindex suspending
151 @kbd{C-z} runs the command @code{suspend-frame}. On a graphical 138 @kbd{C-z} runs the command @code{suspend-frame}. On a graphical
152display, this ``minimizes'' (or ``iconifies'') the selected Emacs 139display, this command @dfn{minimizes} (or @dfn{iconifies}) the
153frame. On a text terminal, this suspends the Emacs process. 140selected Emacs frame, hiding it in a way that lets you bring it back
154 141later (exactly how this hiding occurs depends on the window system).
155 After minimizing or suspending Emacs, you can return to it and 142On a text terminal, the @kbd{C-z} command @dfn{suspends} Emacs,
156continue editing wherever you left off. The way to do this depends on 143stopping the program temporarily and returning control to the parent
157the window system or shell. In most common shells, you can resume 144process (usually a shell); in most shells, you can resume Emacs after
158Emacs after suspending it with the shell command @command{%emacs}. 145suspending it with the shell command @command{%emacs}.
159
160@vindex cannot-suspend
161 On very old systems that don't support suspending programs,
162@kbd{C-z} starts an inferior shell that communicates directly with the
163terminal, and Emacs waits until you exit the subshell. (The way to
164exit the subshell is usually @kbd{C-d} or @command{exit}.) On these
165systems, you can only get back to the shell from which Emacs was run
166(to log out, for example) when you kill Emacs. Suspending can also
167fail if you run Emacs under a shell that doesn't support suspending
168jobs, even if the system itself does support it. In this case, you
169can set the variable @code{cannot-suspend} to a non-@code{nil} value
170to force @kbd{C-z} to start an inferior shell.
171 146
172 Text-only terminals usually listen for certain special characters 147 Text-only terminals usually listen for certain special characters
173whose meaning is to kill or suspend the program you are running. 148whose meaning is to kill or suspend the program you are running.
diff --git a/doc/emacs/frames.texi b/doc/emacs/frames.texi
index 619252503a9..fc78f90db15 100644
--- a/doc/emacs/frames.texi
+++ b/doc/emacs/frames.texi
@@ -1229,8 +1229,7 @@ raises the frame.
1229 1229
1230@node Non-Window Terminals 1230@node Non-Window Terminals
1231@section Non-Window Terminals 1231@section Non-Window Terminals
1232@cindex non-window terminals 1232@cindex text-only terminal
1233@cindex single-frame terminals
1234 1233
1235 On a text-only terminal, Emacs can display only one Emacs frame at a 1234 On a text-only terminal, Emacs can display only one Emacs frame at a
1236time. However, you can still create multiple Emacs frames, and switch 1235time. However, you can still create multiple Emacs frames, and switch
diff --git a/doc/emacs/screen.texi b/doc/emacs/screen.texi
index 59f65fac8af..14d4c678085 100644
--- a/doc/emacs/screen.texi
+++ b/doc/emacs/screen.texi
@@ -5,31 +5,35 @@
5@node Screen, User Input, Acknowledgments, Top 5@node Screen, User Input, Acknowledgments, Top
6@chapter The Organization of the Screen 6@chapter The Organization of the Screen
7@cindex screen 7@cindex screen
8@cindex parts of the screen 8@cindex frame
9 9
10 On a text-only terminal, the Emacs display occupies the entire 10 On a graphical display, such as on GNU/Linux using the X Window
11terminal screen. On a graphical display, such as on GNU/Linux using 11System, Emacs occupies a ``graphical window''. On a text-only
12the X Window System, Emacs creates its own windows to use. We use the 12terminal, Emacs occupies the entire terminal screen. We will use the
13term @dfn{frame} to mean the entire terminal screen or graphical 13term @dfn{frame} to mean a graphical window or terminal screen
14window used by Emacs. Emacs uses both kinds of frames, in the same 14occupied by Emacs. Emacs behaves very similarly on both kinds of
15way, to display your editing. Emacs normally starts out with just one 15frames. It normally starts out with just one frame, but you can
16frame, but you can create additional frames if you wish 16create additional frames if you wish (@pxref{Frames}).
17(@pxref{Frames}). 17
18 18 Each frame consists of several distinct regions. At the top of the
19 The frame consists of several distinct regions. At the top of the
20frame is a @dfn{menu bar}, which allows you to access commands via a 19frame is a @dfn{menu bar}, which allows you to access commands via a
21series of menus. On a graphical display, directly below the menu bar 20series of menus. On a graphical display, directly below the menu bar
22is a @dfn{tool bar}, a row of icons that perform editing commands if 21is a @dfn{tool bar}, a row of icons that perform editing commands if
23you click on them. At the very bottom of the frame is a special 22you click on them. At the very bottom of the frame is an @dfn{echo
24@dfn{echo area}, where short informative messages are displayed and 23area}, where informative messages are displayed and where you enter
25where you enter information when Emacs asks for it. 24information when Emacs asks for it.
26 25
27 The main area of the frame, below the tool bar (if one exists) and 26 The main area of the frame, below the tool bar (if one exists) and
28above the echo area, is called @dfn{the window}. This is where Emacs 27above the echo area, is called @dfn{the window}. Henceforth in this
29displays the @dfn{buffer}: the text that you are editing. On a 28manual, we will use the word ``window'' in this sense. Graphical
30graphical display, the window possesses a @dfn{scroll bar} on one 29display systems commonly use the word ``window'' with a different
31side, which you can use to display different parts of the buffer in 30meaning; but, as stated above, we refer to those ``graphical windows''
32the window. The last line of the window is a @dfn{mode line}. This 31as ``frames''.
32
33 An Emacs window is where the @dfn{buffer}---the text you are
34editing---is displayed. On a graphical display, the window possesses
35a @dfn{scroll bar} on one side, which can be used to scroll through
36the buffer. The last line of the window is a @dfn{mode line}. This
33displays various information about what is going on in the buffer, 37displays various information about what is going on in the buffer,
34such as whether there are unsaved changes, the editing modes that are 38such as whether there are unsaved changes, the editing modes that are
35in use, the current line number, and so forth. 39in use, the current line number, and so forth.
@@ -37,20 +41,18 @@ in use, the current line number, and so forth.
37 When you start Emacs, there is normally only one window in the 41 When you start Emacs, there is normally only one window in the
38frame. However, you can subdivide this window horizontally or 42frame. However, you can subdivide this window horizontally or
39vertically to create multiple windows, each of which can independently 43vertically to create multiple windows, each of which can independently
40display a buffer (@pxref{Windows}). In this manual, the word 44display a buffer (@pxref{Windows}).
41``window'' refers to the initial large window if not subdivided, or 45
42any one of the multiple windows you have subdivided it into. 46 At any time, one window is the @dfn{selected window}. On a
43 47graphical display, the selected window shows a more prominent cursor
44 At any time, one window is the @dfn{selected window}. On graphical 48(usually solid and blinking); other windows show a less prominent
45displays, the selected window normally shows a more prominent cursor 49cursor (usually a hollow box). On a text terminal, there is only one
46(usually solid and blinking) while other windows show a weaker cursor 50cursor, which is shown in the selected window. The buffer displayed
47(such as a hollow box). Text terminals have just one cursor, so it 51in the selected window is called the @dfn{current buffer}, and it is
48always appears in the selected window. The buffer displayed in the 52where editing happens. Most Emacs commands implicitly apply to the
49selected window is called the @dfn{current buffer}, and it is where 53current buffer; the text displayed in unselected windows is mostly
50editing happens. Most Emacs commands implicitly apply to the current 54visible for reference. If you use multiple frames on a graphical
51buffer; the text displayed in unselected windows is mostly visible for 55display, selecting a particular frame selects a window in that frame.
52reference. If you use multiple frames on a graphical display,
53selecting a particular frame selects a window in that frame.
54 56
55@menu 57@menu
56* Point:: The place in the text where editing commands operate. 58* Point:: The place in the text where editing commands operate.
@@ -64,42 +66,33 @@ selecting a particular frame selects a window in that frame.
64@cindex point 66@cindex point
65@cindex cursor 67@cindex cursor
66 68
67 The active cursor shows the location at which editing commands will 69 The cursor in the selected window shows the location where most
68take effect, which is called @dfn{point}@footnote{The term ``point'' 70editing commands take effect, which is called @dfn{point}@footnote{The
69comes from the character @samp{.}, which was the command in TECO (the 71term ``point'' comes from the character @samp{.}, which was the
70language in which the original Emacs was written) for accessing the 72command in TECO (the language in which the original Emacs was written)
71value now called ``point.''}. Many Emacs commands move point to 73for accessing the editing position.}. Many Emacs commands move point
72different places in the buffer; for example, you can place point by 74to different places in the buffer; for example, you can place point by
73clicking mouse button 1 (normally the left button) at the desired 75clicking mouse button 1 (normally the left button) at the desired
74location. 76location.
75 77
76 If you use a block cursor, the cursor appears to be @emph{on} a 78 By default, the cursor in the selected window is drawn as a solid
77character, but you should think of point as @emph{between} two 79block and appears to be @emph{on} a character, but you should think of
78characters; it points @emph{before} the character that appears under 80point as @emph{between} two characters; it is situated @emph{before}
79the cursor. For example, if your text looks like @samp{frob} with the 81the character under the cursor. For example, if your text looks like
80cursor over the @samp{b}, then point is between the @samp{o} and the 82@samp{frob} with the cursor over the @samp{b}, then point is between
81@samp{b}. If you insert the character @samp{!} at that position, the 83the @samp{o} and the @samp{b}. If you insert the character @samp{!}
82result is @samp{fro!b}, with point between the @samp{!} and the 84at that position, the result is @samp{fro!b}, with point between the
83@samp{b}. Thus, the cursor remains over the @samp{b}, as before. 85@samp{!} and the @samp{b}. Thus, the cursor remains over the
84 86@samp{b}, as before.
85 Sometimes people speak of ``the cursor'' when they mean ``point,'' or
86speak of commands that move point as ``cursor motion'' commands.
87 87
88 If you are editing several files in Emacs, each in its own buffer, 88 If you are editing several files in Emacs, each in its own buffer,
89each buffer has its own point location. A buffer that is not 89each buffer has its own value of point. A buffer that is not
90currently displayed remembers its point location in case you display 90currently displayed remembers its value of point if you later display
91it again later. When Emacs displays multiple windows, each window has 91it again. Furthermore, if a buffer is displayed in multiple windows,
92its own point location. If the same buffer appears in more than one 92each of those windows has its own value of point.
93window, each window has its own point position in that buffer. 93
94 94 @xref{Cursor Display}, for options that control how Emacs displays
95 On a graphical display, Emacs shows a cursor in each window. The 95the cursor.
96selected window's cursor will be blinking. If you use the default,
97@code{box} cursor type, the selected window's cursor will be solid,
98and the other cursors are hollow. On a text-only terminal, there is
99just one cursor, in the selected window; even though the unselected
100windows have their own point positions, they do not display a cursor.
101@xref{Cursor Display}, for customizable variables that control cursor
102display.
103 96
104@node Echo Area 97@node Echo Area
105@section The Echo Area 98@section The Echo Area
@@ -108,40 +101,41 @@ display.
108 The line at the very bottom of the frame is the @dfn{echo area}. It 101 The line at the very bottom of the frame is the @dfn{echo area}. It
109is used to display small amounts of text for various purposes. 102is used to display small amounts of text for various purposes.
110 103
111 @dfn{Echoing} means displaying the characters that you type. 104@cindex echoing
112Single-character commands, including most simple editing operations, 105 The echo area is so-named because one of the things it is used for
113are not echoed. Multi-character commands are echoed if you pause 106is @dfn{echoing}, which means displaying the characters of a
114while typing them: if you pause for more than a second in the middle 107multi-character command as you type. Single-character commands are
115of a command, Emacs echoes all the characters of the command so far, 108not echoed. Multi-character commands (@pxref{Keys}) are echoed if you
116to prompt you for the rest of the command. The echoed characters are 109pause for more than a second in the middle of a command. Emacs then
117displayed in the echo area. Once echoing has started, the rest of the 110echoes all the characters of the command so far, to prompt you for the
118command echoes immediately as you type it. This behavior is designed 111rest. Once echoing has started, the rest of the command echoes
119to give confident users fast response, while giving hesitant users 112immediately as you type it. This behavior is designed to give
120maximum feedback. @xref{Display Custom}. 113confident users fast response, while giving hesitant users maximum
121 114feedback.
122@cindex error message in the echo area 115
123 If a command cannot do its job, it may display an @dfn{error 116@cindex error message
124message}. Error messages are also displayed in the echo area. They 117@cindex echo area message
125may be accompanied by beeping or by flashing the screen. 118 The echo area is also used to display an @dfn{error message} when a
126 119command cannot do its job. Error messages may be accompanied by
127 Some commands display informative messages in the echo area. Unlike 120beeping or by flashing the screen.
128error messages, these messages are not announced with a beep or flash. 121
129Sometimes the message tells you what the command has done, when this 122 Some commands display informative messages in the echo area to tell
130is not obvious from looking at the text being edited. Other times, 123you what the command has done, or to provide you with some specific
131the sole purpose of a command is to show you a message giving you 124information. These @dfn{informative} messages, unlike error messages,
132specific information. For example, @kbd{C-x =} (hold down @key{CTRL} 125are not accompanied with a beep or flash. For example, @kbd{C-x =}
133and type @kbd{x}, then let go of @key{CTRL} and type @kbd{=}) displays 126(hold down @key{CTRL} and type @kbd{x}, then let go of @key{CTRL} and
134a message describing the character position of point in the text and 127type @kbd{=}) displays a message describing the character at point,
135its current column in the window. Commands that take a long time 128its position in the buffer, and its current column in the window.
136often display messages ending in @samp{...} while they are working, 129Commands that take a long time often display messages ending in
137and add @samp{done} at the end when they are finished. They may also 130@samp{...} while they are working (sometimes also indicating how much
138indicate progress with percentages. 131progress has been made, as a percentage), and add @samp{done} when
132they are finished.
139 133
140@cindex @samp{*Messages*} buffer 134@cindex @samp{*Messages*} buffer
141@cindex saved echo area messages 135@cindex saved echo area messages
142@cindex messages saved from echo area 136@cindex messages saved from echo area
143@vindex message-log-max 137@vindex message-log-max
144 Informative echo-area messages are saved in a special buffer named 138 Informative echo area messages are saved in a special buffer named
145@samp{*Messages*}. (We have not explained buffers yet; see 139@samp{*Messages*}. (We have not explained buffers yet; see
146@ref{Buffers}, for more information about them.) If you miss a 140@ref{Buffers}, for more information about them.) If you miss a
147message that appeared briefly on the screen, you can switch to the 141message that appeared briefly on the screen, you can switch to the
@@ -152,15 +146,17 @@ either; see @ref{Variables}, for more information about them.) Beyond
152this limit, one line is deleted from the beginning whenever a new 146this limit, one line is deleted from the beginning whenever a new
153message line is added at the end. 147message line is added at the end.
154 148
149 @xref{Display Custom}, for options that control how Emacs uses the
150echo area.
151
155@cindex minibuffer 152@cindex minibuffer
156 The echo area is also used to display the @dfn{minibuffer}, a 153 The echo area is also used to display the @dfn{minibuffer}, a
157special window where you can input arguments to commands, such as the 154special window where you can input arguments to commands, such as the
158name of a file to be edited. When the minibuffer is in use, the text 155name of a file to be edited. When the minibuffer is in use, the text
159displayed in the echo area begins with a @dfn{prompt string} (usually 156displayed in the echo area begins with a @dfn{prompt string}, and the
160ending with a colon); also, the active cursor appears within the 157active cursor appears within the minibuffer, which is temporarily
161minibuffer, which is temporarily considered the selected window. You 158considered the selected window. You can always get out of the
162can always get out of the minibuffer by typing @kbd{C-g}. 159minibuffer by typing @kbd{C-g}. @xref{Minibuffer}.
163@xref{Minibuffer}.
164 160
165@node Mode Line 161@node Mode Line
166@section The Mode Line 162@section The Mode Line
@@ -171,47 +167,51 @@ can always get out of the minibuffer by typing @kbd{C-g}.
171what is going on in the current buffer. When there is only one 167what is going on in the current buffer. When there is only one
172window, the mode line appears right above the echo area; it is the 168window, the mode line appears right above the echo area; it is the
173next-to-last line in the frame. On a graphical display, the mode line 169next-to-last line in the frame. On a graphical display, the mode line
174is drawn with a 3D box appearance, and the mode line of the selected 170is drawn with a 3D box appearance. Emacs also usually draws the mode
175window has a brighter color than that of unselected windows to make it 171line of the selected window with a different color than that of
176stand out. On a text-only terminal, the mode line is usually drawn in 172unselected windows, in order to make it stand out.
177inverse video.
178 173
179 The text displayed in the mode line has the following format: 174 The text displayed in the mode line has the following format:
180 175
181@example 176@example
182-@var{cs}:@var{ch}-@var{fr} @var{buf} @var{pos} @var{line} (@var{major} @var{minor})------ 177 @var{cs}:@var{ch}-@var{fr} @var{buf} @var{pos} @var{line} (@var{major} @var{minor})
183@end example 178@end example
184 179
185@noindent 180@noindent
181On a text-only terminal, this text is followed by a series of dashes
182extending to the right edge of the window. These dashes are omitted
183on a graphical display.
184
186The @var{cs} string and the colon character after it describe the 185The @var{cs} string and the colon character after it describe the
187character set and newline convention used for the current buffer. 186character set and newline convention used for the current buffer.
188Normally, Emacs handles these settings intelligently, but it is 187Normally, Emacs automatically handles these settings for you, but it
189sometimes useful to have this information. 188is sometimes useful to have this information.
190 189
191 @var{cs} describes the character set of the buffer (@pxref{Coding 190 @var{cs} describes the character set of the text in the buffer
192Systems}). If it is a dash (@samp{-}), that indicates the default 191(@pxref{Coding Systems}). If it is a dash (@samp{-}), that indicates
193state of affairs: no special character set handling, except for the 192no special character set handling (with the possible expection of
194end-of-line translations described in the next paragraph. @samp{=} 193end-of-line conventions, described in the next paragraph). @samp{=}
195means no conversion whatsoever. Characters represent various nontrivial 194means no conversion whatsoever, and is usually used for files
195containing non-textual data. Other characters represent various
196@dfn{coding systems}---for example, @samp{1} represents ISO Latin-1. 196@dfn{coding systems}---for example, @samp{1} represents ISO Latin-1.
197On a text-only terminal, @var{cs} is preceded by two additional 197
198characters that describe the coding system for keyboard input and the 198 On a text-only terminal, @var{cs} is preceded by two additional
199coding system for terminal output. Furthermore, if you are using an 199characters that describe the coding systems for keyboard input and
200input method, @var{cs} is preceded by a string that identifies the 200terminal output. Furthermore, if you are using an input method,
201input method, which takes the form @samp{@var{i}>}, @samp{@var{i}+}, 201@var{cs} is preceded by a string that identifies the input method
202or @samp{@var{i}@@} (@pxref{Input Methods}). 202(@pxref{Input Methods}).
203 203
204@cindex end-of-line conversion, mode-line indication 204@cindex end-of-line convention, mode-line indication
205 The character after @var{cs} is usually a colon. However, under 205 The character after @var{cs} is usually a colon. If a different
206some circumstances a different string is displayed, which indicates a 206string is displayed, that indicates a nontrivial end-of-line
207nontrivial end-of-line convention. Usually, lines of text are 207convention for encoding a file. Usually, lines of text are separated
208separated by @dfn{newline characters}, but two other conventions are 208by @dfn{newline characters} in a file, but two other conventions are
209sometimes used. The MS-DOS convention is to use a ``carriage-return'' 209sometimes used. The MS-DOS convention uses a ``carriage-return''
210character followed by a ``linefeed'' character; when editing such 210character followed by a ``linefeed'' character; when editing such
211files, the colon changes to either a backslash (@samp{\}) or 211files, the colon changes to either a backslash (@samp{\}) or
212@samp{(DOS)}, depending on the operating system. The Macintosh 212@samp{(DOS)}, depending on the operating system. Another convention,
213end-of-line convention is to use a ``carriage-return'' character 213employed by older Macintosh systems, uses a ``carriage-return''
214instead of a newline; when editing such files, the colon indicator 214character instead of a newline; when editing such files, the colon
215changes to either a forward slash (@samp{/}) or @samp{(Mac)}. On some 215changes to either a forward slash (@samp{/}) or @samp{(Mac)}. On some
216systems, Emacs displays @samp{(Unix)} instead of the colon for files 216systems, Emacs displays @samp{(Unix)} instead of the colon for files
217that use newline as the line separator. 217that use newline as the line separator.
@@ -234,14 +234,14 @@ only on text-only terminals. The initial frame's name is @samp{F1}.
234Usually, this is the same as the name of a file you are editing. 234Usually, this is the same as the name of a file you are editing.
235@xref{Buffers}. 235@xref{Buffers}.
236 236
237 @var{pos} tells you whether there is additional text above the top of 237 @var{pos} tells you whether there is additional text above the top
238the window, or below the bottom. If your buffer is small and it is all 238of the window, or below the bottom. If your buffer is small and all
239visible in the window, @var{pos} is @samp{All}. Otherwise, it is 239of it is visible in the window, @var{pos} is @samp{All}. Otherwise,
240@samp{Top} if you are looking at the beginning of the buffer, @samp{Bot} 240it is @samp{Top} if you are looking at the beginning of the buffer,
241if you are looking at the end of the buffer, or @samp{@var{nn}%}, where 241@samp{Bot} if you are looking at the end of the buffer, or
242@var{nn} is the percentage of the buffer above the top of the window. 242@samp{@var{nn}%}, where @var{nn} is the percentage of the buffer above
243With Size Indication mode, you can display the size of the buffer as 243the top of the window. With Size Indication mode, you can display the
244well. @xref{Optional Mode Line}. 244size of the buffer as well. @xref{Optional Mode Line}.
245 245
246 @var{line} is the character @samp{L} followed by the line number at 246 @var{line} is the character @samp{L} followed by the line number at
247point. (You can display the current column number too, by turning on 247point. (You can display the current column number too, by turning on
@@ -249,16 +249,14 @@ Column Number mode. @xref{Optional Mode Line}.)
249 249
250 @var{major} is the name of the @dfn{major mode} used in the buffer. 250 @var{major} is the name of the @dfn{major mode} used in the buffer.
251A major mode is a principal editing mode for the buffer, such as Text 251A major mode is a principal editing mode for the buffer, such as Text
252mode, Lisp mode, C mode, and so forth. @xref{Major Modes}. 252mode, Lisp mode, C mode, and so forth. @xref{Major Modes}. Some
253 253major modes display additional information after the major mode name.
254 Some major modes display additional information after the major mode 254For example, Compilation buffers and Shell buffers display the status
255name. For example, Rmail buffers display the current message number and 255of the subprocess.
256the total number of messages. Compilation buffers and Shell buffers
257display the status of the subprocess.
258 256
259 @var{minor} is a list of some of the @dfn{minor modes} turned on in 257 @var{minor} is a list of some of the enabled @dfn{minor modes},
260the buffer. Minor modes are optional editing modes that provide 258which are optional editing modes that provide additional features on
261additional features on top of the major mode. @xref{Minor Modes}. 259top of the major mode. @xref{Minor Modes}.
262 260
263 Some features are listed together with the minor modes whenever they 261 Some features are listed together with the minor modes whenever they
264are turned on, even though they are not really minor modes. 262are turned on, even though they are not really minor modes.
@@ -271,9 +269,8 @@ restricted to only a portion of its text (@pxref{Narrowing}).
271brackets (@samp{[@dots{}]}) appear around the parentheses that 269brackets (@samp{[@dots{}]}) appear around the parentheses that
272surround the modes. If Emacs is in one recursive editing level within 270surround the modes. If Emacs is in one recursive editing level within
273another, double square brackets appear, and so on. Since recursive 271another, double square brackets appear, and so on. Since recursive
274editing levels affect Emacs globally, not just one buffer, the square 272editing levels affect Emacs globally, such square brackets appear in
275brackets appear in every window's mode line or not in any of them. 273the mode line of every window. @xref{Recursive Edit}.
276@xref{Recursive Edit}.@refill
277 274
278 You can change the appearance of the mode line as well as the format 275 You can change the appearance of the mode line as well as the format
279of its contents. @xref{Optional Mode Line}. In addition, the mode 276of its contents. @xref{Optional Mode Line}. In addition, the mode
@@ -293,10 +290,10 @@ here, as you can more easily see them yourself.
293@findex tmm-menubar 290@findex tmm-menubar
294@findex menu-bar-open 291@findex menu-bar-open
295 On a graphical display, you can use the mouse to choose a command 292 On a graphical display, you can use the mouse to choose a command
296from the menu bar. A right-arrow at the end of a menu item means it 293from the menu bar. An arrow on the right edge of a menu item means it
297leads to a subsidiary menu, or @dfn{submenu}. A @samp{...} at the end 294leads to a subsidiary menu, or @dfn{submenu}. A @samp{...} at the end
298of a menu item means that the command invoked will prompt you for 295of a menu item means that the command will prompt you for further
299further input before it actually does anything. 296input before it actually does anything.
300 297
301 Some of the commands in the menu bar have ordinary key bindings as 298 Some of the commands in the menu bar have ordinary key bindings as
302well; if so, a key binding is shown in parentheses after the item 299well; if so, a key binding is shown in parentheses after the item
@@ -310,14 +307,13 @@ You can then navigate the menus with the arrow keys. To activate a
310selected menu item, press @key{RET}; to cancel menu navigation, press 307selected menu item, press @key{RET}; to cancel menu navigation, press
311@key{ESC}. 308@key{ESC}.
312 309
313 On text-only terminals with no mouse, you can use the menu bar by 310 On a text-only terminal, you can use the menu bar by typing
314typing @kbd{M-`} or @key{F10} (these run the command 311@kbd{M-`} or @key{F10} (these run the command @code{tmm-menubar}).
315@code{tmm-menubar}). This lets you select a menu item with the 312This lets you select a menu item with the keyboard. A provisional
316keyboard. A provisional choice appears in the echo area. You can use 313choice appears in the echo area. You can use the up and down arrow
317the up and down arrow keys to move through the menu to different 314keys to move through the menu to different items, and then you can
318items, and then you can type @key{RET} to select the item. 315type @key{RET} to select the item. Each menu item is also designated
319 316by a letter or digit (usually the initial of some word in the item's
320 Each menu item also has an assigned letter or digit which designates 317name). This letter or digit is separated from the item name by
321that item; it is usually the initial of some word in the item's name. 318@samp{=>}. You can type the item's letter or digit to select the
322This letter or digit is separated from the item name by @samp{=>}. You 319item.
323can type the item's letter or digit to select the item.
diff --git a/etc/NEWS b/etc/NEWS
index 332d12cb540..2c48a30e5f6 100644
--- a/etc/NEWS
+++ b/etc/NEWS
@@ -96,8 +96,10 @@ and also when HOME is set to C:\ by default.
96 96
97*** shell-mode uses pcomplete rules, with the standard completion UI. 97*** shell-mode uses pcomplete rules, with the standard completion UI.
98 98
99*** Many packages have been changed to use completion-at-point rather than 99*** Many packages have been changed to use `completion-at-point'
100their own completion code. 100rather than their own completion code.
101
102*** `completion-at-point' now handles tags and semantic completion.
101 103
102*** Completion in a non-minibuffer now tries to detect the end of completion 104*** Completion in a non-minibuffer now tries to detect the end of completion
103and pops down the *Completions* buffer accordingly. 105and pops down the *Completions* buffer accordingly.
@@ -455,8 +457,6 @@ isearch-yank-kill.
455+++ 457+++
456** New command `count-words-region'. This does what you expect. 458** New command `count-words-region'. This does what you expect.
457 459
458** completion-at-point now handles tags and semantic completion.
459
460** The default value of `backup-by-copying-when-mismatch' is now t. 460** The default value of `backup-by-copying-when-mismatch' is now t.
461 461
462** The command `just-one-space' (M-SPC), if given a negative argument, 462** The command `just-one-space' (M-SPC), if given a negative argument,
@@ -724,6 +724,8 @@ in the Rmail incoming message.
724 724
725** Shell mode 725** Shell mode
726 726
727*** Shell mode uses pcomplete rules, with the standard completion UI.
728
727*** The `shell' command prompts for the shell path name if the default 729*** The `shell' command prompts for the shell path name if the default
728directory is a remote file name and neither the environment variable 730directory is a remote file name and neither the environment variable
729$ESHELL nor the variable `explicit-shell-file-name' is set. 731$ESHELL nor the variable `explicit-shell-file-name' is set.