Commit | Line | Data |
---|---|---|
cb2f22fc BJ |
1 | .bd S 3 |
2 | .pn 21 | |
3 | .de iP | |
4 | .IP "\fB\\$1\fR" \\$2 | |
5 | .. | |
6 | .SH | |
7 | Appendix: character functions | |
8 | .PP | |
9 | This appendix gives the uses the editor makes of each character. The | |
10 | characters are presented in their order in the \s-2ASCII\s0 character | |
11 | set: Control characters come first, then most special characters, then | |
12 | the digits, upper and then lower case characters. | |
13 | .PP | |
14 | For each character we tell a meaning it has as a command and any meaning it | |
15 | has during an insert. | |
16 | If it has only meaning as a command, then only this is discussed. | |
17 | Section numbers in parentheses indicate where the character is discussed; | |
18 | a `f' after the section number means that the character is mentioned | |
19 | in a footnote. | |
20 | .iP "^@" 15 | |
21 | Not a command character. | |
22 | If typed as the first character of an insertion it is replaced with the | |
23 | last text inserted, and the insert terminates. Only 128 characters are | |
24 | saved from the last insert; if more characters were inserted the mechanism | |
25 | is not available. | |
26 | A \fB^@\fR cannot be part of the file due to the editor implementation | |
27 | (7.5f). | |
28 | .iP "^A" 15 | |
29 | Unused. | |
30 | .iP "^B" 15 | |
31 | Backward window. | |
32 | A count specifies a new window size. | |
33 | Two lines of continuity are kept if possible (2.1, 6.1, 7.2). | |
34 | .iP "^C" 15 | |
35 | Unused. | |
36 | .iP "^D" 15 | |
37 | As a command, scrolls down a half-window of text. | |
38 | A count gives the number of (logical) lines to scroll, and is remembered | |
39 | for future \fB^D\fR and \fB^U\fR commands (2.1, 7.2). | |
40 | During an insert, backtabs over \fIautoindent\fR white space at the beginning | |
41 | of a line (6.6, 7.5); this white space cannot be backspaced over. | |
42 | .iP "^E" 15 | |
43 | Exposes one more line below the current screen in the file, leaving | |
44 | the cursor where it is if possible. | |
45 | .iP "^F" 15 | |
46 | Forward window. A count specifies a new window size. | |
47 | Two lines of continuity are kept if possible (2.1, 6.1, 7.2). | |
48 | .iP "^G" 15 | |
49 | Equivalent to \fB:f\fR\s-2ESC\s0, printing the current file, whether | |
50 | it has been modified, the current line number and the number of lines | |
51 | in the file, and the percentage of the way through the file that you | |
52 | are. | |
53 | A count specifies a new default window size (2.2). | |
54 | .iP "^H (\fR\s-2BS\s0\fP)" 15 | |
55 | Backspaces one character on the current line. With a count backs up | |
56 | that many characters. The character \fBh\fR is a synonym for \fB^H\fR | |
57 | which is convenient on terminals without backspace keys (3.2). | |
58 | During an insert, eliminates the last input character, backing over it | |
59 | but not erasing it; it remains so you can see what you typed if you | |
60 | wish to type something only slightly different (3.1, 7.5). | |
61 | .iP "^I\ (\fR\s-2TAB\s0\fP)" 15 | |
62 | Not a command character. | |
63 | When inserted it prints as some | |
64 | number of spaces. | |
65 | When the cursor is at a tab character it rests at the last of the spaces | |
66 | which represent the tab. | |
67 | The spacing of tabstops is controlled by the \fItabstop\fR option (4.1, 6.6). | |
68 | .iP "^J\ (\fR\s-2LF\s0\fP)" 15 | |
69 | A linefeed advances to the next line, in the same column or as near this | |
70 | column as possible. A sequence of linefeeds will attempt to move vertically | |
71 | and stay in the original position horizontally. A count causes an advance | |
72 | over several lines (2.3). | |
73 | .iP "^K" 15 | |
74 | Unused. | |
75 | .iP "^L" 15 | |
76 | The \s-2ASCII\s0 formfeed character, this causes the screen to be cleared | |
77 | and redrawn. This is useful after a transmission error, if characters | |
78 | typed by a program other than the editor scramble the screen, | |
79 | or after output is stopped by an interrupt (5.4, 7.2f). | |
80 | .iP "^M\ (\fR\s-2RETURN\s0\fP)" 15 | |
81 | A carriage return advances to the next line, at the first non-white position | |
82 | in the line. Given a count, it advances that many lines (2.3). | |
83 | During an insert, a \s-2RETURN\s0 causes the insert to continue onto | |
84 | another line (3.1). | |
85 | .iP "^N" 15 | |
86 | Advances to the next line, in the same column (see \fB^J\fR for more | |
87 | details on how this works). A count advances that many lines (2.3). | |
88 | .iP "^O" 15 | |
89 | Unused. | |
90 | .iP "^P" 15 | |
91 | Retreats to the previous line, in the same column (see \fB^J\fR for more | |
92 | details). A count retreats that many lines (2.3). | |
93 | .iP "^Q" 15 | |
94 | Not a command character. | |
95 | During an insert, quotes the next character so that it is possible to | |
96 | insert non-printing and special characters into the file (4.2, 7.5). | |
97 | .iP "^R" 15 | |
98 | Redraws the current screen, eliminating logical lines not corresponding | |
99 | to physical lines (lines with only a single @ character on them). | |
100 | On hardcopy terminals in \fIopen\fR mode, retypes the current line | |
101 | (5.4, 7.2, 7.8). | |
102 | .iP "^S" 15 | |
103 | Suspends output temporarily; another \fB^S\fR restarts it. This works | |
104 | at all times (7.5f). | |
105 | .iP "^T" 15 | |
106 | Not a command character. | |
107 | During an insert, with \fIautoindent\fR set and at the beginning of the | |
108 | line, inserts \fIshiftwidth\fR white space (6.6, 7.5). | |
109 | .iP "^U" 15 | |
110 | Scrolls the screen up, inverting \fB^D\fR which scrolls down. Counts work as | |
111 | they do for \fB^D\fR, and the previous scroll amount is common to both. | |
112 | On a dumb terminal, \fB^U\fR will often necessitate clearing and redrawing | |
113 | the screen further back in the file (2.1, 7.2). | |
114 | .iP "^V" 15 | |
115 | Not a command character. In input mode, a synonym for \fB^Q\fR. | |
116 | .iP "^W" 15 | |
117 | Not a command character. | |
118 | During an insert, backs up as \fBb\fR would in command mode; the deleted | |
119 | characters remain on the display (see \fB^H\fR) (7.5). | |
120 | .iP "^X" 15 | |
121 | Unused. | |
122 | .iP "^Y" 15 | |
123 | Exposes one more line above the current screen, leaving the cursor where | |
124 | it is if possible. (No mnemonic value for this key; however, it is next | |
125 | to \fB^U\fR which scrolls up a bunch.) | |
126 | .iP "^Z" 15 | |
127 | Unused. | |
128 | .iP "^[\ (\fR\s-2ESC\s0\fP)" 15 | |
129 | Cancels a partially formed command, such as a \fBz\fR when no following | |
130 | character has yet been given; terminates inputs on the last line (read | |
131 | by commands such as \fB: /\fR and \fB?\fR); ends insertions of new text | |
132 | into the buffer. | |
133 | If an \s-2ESC\s0 is given when quiescent in command state, the editor | |
134 | rings the bell or flashes the screen. You can thus hit \s-2ESC\s0 if | |
135 | you don't know what is happening till the editor rings the bell. | |
136 | If you don't know if you are in insert mode you can type \s-2ESC\s0\fBa\fR, | |
137 | and then material to be input; the material will be inserted correctly | |
138 | whether or not you were in insert mode when you started (1.5, 3.1, 7.5). | |
139 | .iP "^\e" 15 | |
140 | Unused. | |
141 | .iP "^]" 15 | |
142 | Searches for the word which is after the cursor as a tag. Equivalent | |
143 | to typing \fB:ta\fR, this word, and then an \s-2ESC\s0. | |
144 | Mnemonically, this command is ``go right to'' (7.3). | |
145 | .iP "^\(ua" 15 | |
146 | Equivalent to \fB:e #\fR\s-2ESC\s0, returning to the previous position | |
147 | in the last edited file, or editing a file which you specified if you | |
148 | got a `No write since last change diagnostic' and do not want to have | |
149 | to type the file name again (7.3). | |
150 | (You have to do a \fB:w\fR before \fB^\(ua\fR | |
151 | will work in this case. If you do not wish to write the file you should | |
152 | do \fB:e!\ #\fR\s-2ESC\s0 instead.) | |
153 | .iP "^_" 15 | |
154 | Unused. | |
155 | .iP "\fR\s-2SPACE\s0\fP" 15 | |
156 | Advances to the next character in the current line. With a count, advances | |
157 | that many characters. | |
158 | .iP "!" 15 | |
159 | An operator, which processes lines from the buffer with reformatting commands. | |
160 | Follow \fB!\fR with the object to be processed, and then the command name | |
161 | terminated by \s-2ESC\s0. Doubling \fB!\fR and preceding it by a count | |
162 | causes count lines to be filtered; otherwise the count | |
163 | is passed on to the object after the \fB!\fR. Thus \fB2!}\fR\fIfmt\fR\s-2ESC\s0 | |
164 | reformats the next two paragraphs by running them through the program | |
165 | \fIfmt\fR. If you are working on \s-2LISP\s0, | |
166 | the command \fB!%\fR\fIgrind\fR\s-2ESC\s0, given at the beginning of a | |
167 | function, will run the text of the function through the \s-2LISP\s0 grinder | |
168 | (6.7, 7.3). | |
169 | To read a file or the output of a command into the buffer use \fB:r\fR (7.3). | |
170 | To simply execute a command use \fB:!\fR (7.3). | |
171 | .tr \a" | |
172 | .iP \a 15 | |
173 | Precedes a named buffer specification. There are named buffers \fB1\-9\fR | |
174 | used for saving deleted text and named buffers \fBa\-z\fR into which you can | |
175 | place text (4.3, 6.3) | |
176 | .tr \a\a | |
177 | .iP "#" 15 | |
178 | The macro character which, when followed by a number, will substitute | |
179 | for a function key on terminals without function keys (6.9). | |
180 | In input mode, | |
181 | if this is your erase character, it will delete the last character | |
182 | you typed in input mode, and must be preceded with a \fB\e\fR to insert | |
183 | it, since it normally backs over the last input character you gave. | |
184 | .iP "$" 15 | |
185 | Moves to the end of the current line. If you \fB:se list\fR\s-2ESC\s0, | |
186 | then the end of each line will be shown by printing a \fB$\fR after the | |
187 | end of the displayed text in the line. Given a count, advances to the | |
188 | count'th following end of line; thus \fB2$\fR advances to the end of the | |
189 | following line. | |
190 | .iP "%" 15 | |
191 | Moves to the parenthesis or brace \fB{ }\fR which balances the parenthesis | |
192 | or brace at the current cursor position. | |
193 | .iP "&" 15 | |
194 | A synonym for \fB:&\fR\s-2CR\s0, by analogy with the | |
195 | .I ex | |
196 | .B & | |
197 | command. | |
198 | .iP "\(aa" 15 | |
199 | When followed by a \fB\(aa\fR returns to the previous context at the | |
200 | beginning of a line. The previous context is set whenever the current | |
201 | line is moved in a non-relative way. | |
202 | When followed by a letter \fBa\fR\-\fBz\fR, returns to the line which | |
203 | was marked with this letter with a \fBm\fR command, at the first non-white | |
204 | character in the line. A count before a \fB\(aa\fR gives a new window | |
205 | size for the next screen redraw (2.2, 5.3). | |
206 | When used with an operator such as \fBd\fR, the operation takes place | |
207 | over complete lines; if you use \fB\(ga\fR, the operation takes place | |
208 | from the exact marked place to the current cursor position within the | |
209 | line. | |
210 | .iP "(" 15 | |
211 | Retreats to the beginning of a | |
212 | sentence, or to the beginning of a \s-2LISP\s0 s-expression | |
213 | if the \fIlisp\fR option is set. | |
214 | A sentence ends at a \fB. !\fR or \fB?\fR which is followed by either | |
215 | the end of a line or by two spaces. Any number of closing \fB) ] "\fR | |
216 | and \fB\(aa\fR characters may appear after the \fB. !\fR or \fB?\fR, | |
217 | and before the spaces or end of line. Sentences also begin | |
218 | at paragraph and section boundaries | |
219 | (see \fB{\fR and \fB[[\fR below). | |
220 | A count advances that many sentences (4.2, 6.8). | |
221 | .iP ")" 15 | |
222 | Advances to the beginning of a sentence. | |
223 | A count repeats the effect. | |
224 | See \fB(\fR above for the definition of a sentence (4.2, 6.8). | |
225 | .iP "*" 15 | |
226 | Unused. | |
227 | .iP "+" 15 | |
228 | Advances to the next line at the first non-white character. | |
229 | A count repeats the effect. | |
230 | A \s-2RETURN\s0 is equivalent to a \fB+\fR. | |
231 | If the line moved to is not on the screen, the screen is scrolled, or | |
232 | cleared and redrawn if a large amount of scrolling would be necessary | |
233 | (2.3). | |
234 | .iP "," 15 | |
235 | Reverse of the last \fBf F t\fR or \fBT\fR command, looking the other way | |
236 | in the current line. Especially useful after hitting too many \fB;\fR | |
237 | characters. A count repeats the search. | |
238 | .iP "\-" 15 | |
239 | Retreats to the previous line at the first non-white character. | |
240 | This is the inverse of \fB+\fR and \s-2RETURN\s0. | |
241 | If the line moved to is not on the screen, the screen is scrolled, or | |
242 | cleared and redrawn if this is not possible. | |
243 | If a large amount of scrolling would be required the screen is also cleared | |
244 | and redrawn, with the current line at the center (2.3). | |
245 | .iP "\&." 15 | |
246 | Repeats the last command which changed the buffer. Especially useful | |
247 | when deleting words or lines; you can delete some words/lines and then | |
248 | hit \fB.\fR to delete more and more words/lines. | |
249 | Given a count, it passes it on to the command being repeated. Thus after | |
250 | a \fB2dw\fR, \fB3.\fR deletes three words (3.3, 6.3, 7.2, 7.4). | |
251 | .iP "/" 15 | |
252 | Reads a string from the last line on the screen, and scans forward for | |
253 | the next occurrence of this string. The normal input editing sequences may | |
254 | be used during the input on the bottom line; an returns to command state | |
255 | without ever searching. | |
256 | The search begins when you hit \s-2ESC\s0 to terminate the pattern; | |
257 | the cursor moves to the beginning of the last line to indicate that the search | |
258 | is in progress; the search may then | |
259 | be terminated with a \s-2DEL\s0 or \s-2RUB\s0, or by backspacing when | |
260 | at the beginning of the bottom line, returning the cursor to | |
261 | its initial position. | |
262 | Searches normally wrap end-around to find a string | |
263 | anywhere in the buffer. | |
264 | A count to the command specifies the a new window size. | |
265 | .IP | |
266 | When used with an operator the enclosed region is normally affected. | |
267 | By mentioning an | |
268 | offset from the line matched by the pattern you can force whole lines | |
269 | to be affected. To do this give a pattern with a closing | |
270 | a closing \fB/\fR and then an offset \fB+\fR\fIn\fR or \fB\-\fR\fIn\fR. | |
271 | .IP | |
272 | To include the character \fB/\fR in the search string, you must escape | |
273 | it with a preceding \fB\e\fR. | |
274 | A \fB\(ua\fR at the beginning of the pattern forces the match to occur | |
275 | at the beginning of a line only; this speeds the search. A \fB$\fR at | |
276 | the end of the pattern forces the match to occur at the end of a line | |
277 | only. | |
278 | More extended pattern matching is available, see section 7.4; | |
279 | unless you set \fBnomagic\fR in your \fI\&.exrc\fR file you will have | |
280 | to preceed the characters \fB. [ *\fR and \fB~\fR in the search pattern | |
281 | with a \fB\e\fR to get them to work as you would naively expect (1.5, 2,2, | |
282 | 6.1, 7.2, 7.4). | |
283 | .iP "0" 15 | |
284 | Moves to the first character on the current line. | |
285 | Also used, in forming numbers, after an initial \fB1\fR\-\fB9\fR. | |
286 | .iP "1\-9" 15 | |
287 | Used to form numeric arguments to commands (2.3, 7.2). | |
288 | .iP ":" 15 | |
289 | A prefix to a set of commands for file and option manipulation and escapes | |
290 | to the system. Input is given on the bottom line and terminated with | |
291 | an \s-2ESC\s0, and the command then executed. You can return to where | |
292 | you were by hitting \s-2DEL\s0 or \s-2RUB\s0 if you hit \fB:\fR accidentally | |
293 | (see primarily 6.2 and 7.3). | |
294 | .iP ";" 15 | |
295 | Repeats the last single character find which used \fBf F t\fR or \fBT\fR. | |
296 | A count iterates the basic scan (4.1). | |
297 | .iP "<" 15 | |
298 | An operator which shifts lines left one \fIshiftwidth\fR, normally 8 | |
299 | spaces. Like all operators, affects lines when repeated, as in | |
300 | \fB<<\fR. Counts are passed through to the basic object, thus \fB3<<\fR | |
301 | shifts three lines (6.6, 7.2). | |
302 | .iP "=" 15 | |
303 | Reindents line for \s-2LISP\s0, as though they were typed in with \fIlisp\fR | |
304 | and \fIautoindent\fR set (6.8). | |
305 | .iP ">" 15 | |
306 | An operator which shifts lines right one \fIshiftwidth\fR, normally 8 | |
307 | spaces. Affects lines when repeated as in \fB>>\fR. Counts repeat the | |
308 | basic object (6.6, 7.2). | |
309 | .iP "?" 15 | |
310 | Scans backwards, the opposite of \fB/\fR. See the \fB/\fR description | |
311 | above for details on scanning (2.2, 6.1, 7.4). | |
312 | .iP "@" 15 | |
313 | A macro character (6.9). If this is your kill character, you must escape it with a \e | |
314 | to type it in during input mode, as it normally backs over the input you | |
315 | have given on the current line (3.1, 3.4, 7.5). | |
316 | .iP "A" 15 | |
317 | Appends at the end of line, a synonym for \fB$a\fR (7.2). | |
318 | .iP "B" 15 | |
319 | Backs up a word, where words are composed of non-blank sequences, placing | |
320 | the cursor at the beginning of the word. A count repeats the effect | |
321 | (2.4). | |
322 | .iP "C" 15 | |
323 | Changes the rest of the text on the current line; a synonym for \fBc$\fR. | |
324 | .iP "D" 15 | |
325 | Deletes the rest of the text on the current line; a synonym for \fBd$\fR. | |
326 | .iP "E" 15 | |
327 | Moves forward to the end of a word, defined as blanks and non-blanks, | |
328 | like \fBB\fR and \fBW\fR. A count repeats the effect. | |
329 | .iP "F" 15 | |
330 | Finds a single following character, backwards in the current line. | |
331 | A count repeats this search that many times (4.1). | |
332 | .iP "G" 15 | |
333 | Goes to the line number given as preceding argument, or the end of the | |
334 | file if no preceding count is given. The screen is redrawn with the | |
335 | new current line in the center if necessary (7.2). | |
336 | .iP "H" 15 | |
337 | Homes the cursor to the top line on the screen. If a count is given, | |
338 | then the cursor is moved to the count'th line on the screen. | |
339 | In any case the cursor is moved to the first non-white character on the | |
340 | line. If used as the target of an operator, full lines are affected | |
341 | (2.3, 3.2). | |
342 | .iP "I" 15 | |
343 | Inserts at the beginning of a line; a synonym for \fB\(uai\fR. | |
344 | .iP "J" 15 | |
345 | Joins together lines, supplying appropriate white space: one space between | |
346 | words, two spaces after a \fB.\fR, and no spaces at all if the first | |
347 | character of the joined on line is \fB)\fR. A count causes that many | |
348 | lines to be joined rather than the default two (6.5, 7.1f). | |
349 | .iP "K" 15 | |
350 | Unused. | |
351 | .iP "L" 15 | |
352 | Moves the cursor to the first non-white character of the last line on | |
353 | the screen. With a count, to the first non-white of the count'th line | |
354 | from the bottom. Operators affect whole lines when used with \fBL\fR | |
355 | (2.3). | |
356 | .iP "M" 15 | |
357 | Moves the cursor to the middle line on the screen, at the first non-white | |
358 | position on the line (2.3). | |
359 | .iP "N" 15 | |
360 | Scans for the next match of the last pattern given to | |
361 | \fB/\fR or \fB?\fR, but in the reverse direction; this is the inverse | |
362 | of \fBn\fR. | |
363 | .iP "O" 15 | |
364 | Opens a new line above the current line and inputs text there up to an | |
365 | \s-2ESC\s0. A count can be used on dumb terminals to specify a number | |
366 | of lines to be opened; this is generally obsolete, as the \fIslowopen\fR | |
367 | option works better (3.1). | |
368 | .iP "P" 15 | |
369 | Puts the last deleted text back before/above the cursor. The text goes | |
370 | back as whole lines above the cursor if it was deleted as whole lines. | |
371 | Otherwise the text is inserted between the characters before and at the | |
372 | cursor. May be preceded by a named buffer specification \fB"\fR\fIx\fR | |
373 | to retrieve the contents of the buffer; buffers \fB1\fR\-\fB9\fR contain | |
374 | deleted material, buffers \fBa\fR\-\fBz\fR are available for general | |
375 | use (6.3). | |
376 | .iP "Q" 15 | |
377 | Quits from \fIvi\fR to \fIex\fR command mode. In this mode, whole lines | |
378 | form commands, ending with a \s-2RETURN\s0. You can give all the \fB:\fR | |
379 | commands; the editor supplies the \fB:\fR as a prompt (7.7). | |
380 | .iP "R" 15 | |
381 | Replaces characters on the screen with characters you type (overlay fashion). | |
382 | Terminates with an \s-2ESC\s0. | |
383 | .iP "S" 15 | |
384 | Changes whole lines, a synonym for \fBcc\fR. A count substitutes for | |
385 | that many lines. The lines are saved in the numeric buffers, and erased | |
386 | on the screen before the substitution begins. | |
387 | .iP "T" 15 | |
388 | Takes a single following character, locates the character before the | |
389 | cursor in the current line, and places the cursor just after that character. | |
390 | A count repeats the effect. Most useful with operators such as \fBd\fR | |
391 | (4.1). | |
392 | .iP "U" 15 | |
393 | Restores the current line to its state before you started changing it | |
394 | (3.5). | |
395 | .iP "V" 15 | |
396 | Unused. | |
397 | .iP "W" 15 | |
398 | Moves forward to the beginning of a word in the current line, | |
399 | where words are defined as sequences of blank/non-blank characters. | |
400 | A count repeats the effect (2.4). | |
401 | .iP "X" 15 | |
402 | Deletes the character before the cursor. A count repeats the effect, | |
403 | but only characters on the current line are deleted. | |
404 | .iP "Y" 15 | |
405 | Yanks a copy of the current line into the unnamed buffer, to be put back | |
406 | by a later \fBp\fR or \fBP\fR; a very useful synonym for \fByy\fR. | |
407 | A count yanks that many lines. May be preceded by a buffer name to put | |
408 | lines in that buffer (7.4). | |
409 | .iP "Z" 15 | |
410 | Unused. | |
411 | .iP "[[" 15 | |
412 | Backs up to the previous section boundary. A section begins at each | |
413 | macro in the \fIsections\fR option, | |
414 | normally a `.NH' or `.SH' and also at lines which which start | |
415 | with a formfeed \fB^L\fR. Lines beginning with \fB{\fR also stop \fB[[\fR; | |
416 | this makes it useful for looking backwards, a function at a time, in C | |
417 | programs. If the option \fIlisp\fR is set, stops at each \fB(\fR at the | |
418 | beginning of a line, and is thus useful for moving backwards at the top | |
419 | level \s-2LISP\s0 objects. A count gives a new window size for the next | |
420 | screen redraw (4.2, 6.1, 6.6, 7.2). | |
421 | .iP "\e" 15 | |
422 | Unused. | |
423 | .iP "]]" 15 | |
424 | Forward to a section boundary, see \fB[[\fR for a definition (4.2, 6.1, | |
425 | 6.6, 7.2). | |
426 | .iP "\(ua" 15 | |
427 | Moves to the first non-white position on the current line (4.4). | |
428 | .iP "_" 15 | |
429 | Unused. | |
430 | .iP "\(ga" 15 | |
431 | When followed by a \fB\(ga\fR returns to the previous context. | |
432 | The previous context is set whenever the current | |
433 | line is moved in a non-relative way. | |
434 | When followed by a letter \fBa\fR\-\fBz\fR, returns to the position which | |
435 | was marked with this letter with a \fBm\fR command. | |
436 | A count before a \fB\(ga\fR gives a new window | |
437 | size for the next screen redraw. | |
438 | When used with an operator such as \fBd\fR, the operation takes place | |
439 | from the exact marked place to the current position within the line; | |
440 | if you use \fB\(aa\fR, the operation takes place over complete lines | |
441 | (2.2, 5.3). | |
442 | .iP "a" 15 | |
443 | Appends arbitrary text after the current cursor position; the insert | |
444 | can continue onto multiple lines by using \s-2RETURN\s0 within the insert. | |
445 | A count causes the inserted text to be replicated, but only if the inserted | |
446 | text is all on one line. | |
447 | The insertion terminates with an \s-2ESC\s0 (3.1, 7.2). | |
448 | .iP "b" 15 | |
449 | Backs up to the beginning of a word in the current line. A word is a | |
450 | sequence of alphanumerics, or a sequence of special characters. | |
451 | A count repeats the effect (2.4). | |
452 | .iP "c" 15 | |
453 | An operator which changes the following object, replacing it with the | |
454 | following input text up to an \s-2ESC\s0. If more than part of a single | |
455 | line is affected, the text which is changed away is saved in the numeric named | |
456 | buffers. If only part of the current line is affected, then the last | |
457 | character to be changed away is marked with a \fB$\fR. | |
458 | A count causes that many objects to be affected, thus both | |
459 | \fB3c)\fR and \fBc3)\fR change the following three sentences (7.4). | |
460 | .iP "d" 15 | |
461 | An operator which deletes the following object. If more than part of | |
462 | a line is affected, the text is saved in the numeric buffers. | |
463 | A count causes that many objects to be affected; thus \fB3dw\fR is the | |
464 | same as \fBd3w\fR (3.3, 3.4, 4.1, 7.4). | |
465 | .iP "e" 15 | |
466 | Advances to the end of the next word, defined as for \fBb\fR and \fBw\fR. | |
467 | A count repeats the effect (2.4, 3.1). | |
468 | .iP "f" 15 | |
469 | Finds the first instance of the next character following the cursor on | |
470 | the current line. A count repeats the find (4.1). | |
471 | .iP "g" 15 | |
472 | Unused. | |
473 | .iP "h" 15 | |
474 | Backspaces a single character in the current line; a synonym for \fB^H\fR. | |
475 | A count repeats the effect (3.1, 7.5). | |
476 | .iP "i" 15 | |
477 | Inserts text before the cursor, otherwise like \fBa\fR (7.2). | |
478 | .iP "j" 15 | |
479 | A synonym for \fB^N\fR (or \s-2LF\s0) moving to the next line in the same | |
480 | column (1.1, 2.3). | |
481 | .iP "k" 15 | |
482 | A synonym for \fB^P\fR, moving to the previous line in the same column (1.1, 2.3). | |
483 | .iP "l" 15 | |
484 | A synonym for \s-2SPACE\s0, moving the cursor one column to the right on the | |
485 | same line (1.1, 2.3). | |
486 | .iP "m" 15 | |
487 | Marks the current position of the cursor in the mark register which is | |
488 | specified by the next character \fBa\fR\-\fBz\fR. Return to this position | |
489 | or use with an operator using \fB\(ga\fR or \fB\(aa\fR (5.3). | |
490 | .iP "n" 15 | |
491 | Repeats the last \fB/\fR or \fB?\fR scanning commands (2.2). | |
492 | .iP "o" 15 | |
493 | Opens new lines below the current line; otherwise like \fBO\fR (3.1). | |
494 | .iP "p" 15 | |
495 | Puts text after/below the cursor; otherwise like \fBP\fR (6.3). | |
496 | .iP "q" 15 | |
497 | Unused. In a \fIvi\fR command executed from within \fIex\fR this returns | |
498 | to \fIex\fR command mode. | |
499 | .iP "r" 15 | |
500 | Replaces the single character at the cursor with a single character you | |
501 | type. The new character may be a \s-2RETURN\s0; this is the easiest | |
502 | way to split lines. A count replaces each of the following count characters | |
503 | with the single character given; see \fBR\fR above which is the more | |
504 | usually useful iteration of \fBr\fR (3.2). | |
505 | .iP "s" 15 | |
506 | Changes the single character under the cursor to the text which follows | |
507 | up to an \s-2ESC\s0; given a count, that many characters from the current | |
508 | line are changed. The last character to be changed is marked with \fB$\fR | |
509 | as in \fBc\fR (3.2). | |
510 | .iP "t" 15 | |
511 | Advances the cursor upto the character before the next character typed. | |
512 | Most useful with operators such as \fBd\fR and \fBc\fR to delete the | |
513 | characters up to a following character. You can use \fB.\fR to delete | |
514 | more if this doesn't delete enough the first time (4.1). | |
515 | .iP "u" 15 | |
516 | Undoes the last change made to the current buffer. If repeated, will | |
517 | alternate between these two states, thus is its own inverse. When used | |
518 | after an insert which inserted text on more than one line, the lines are | |
519 | saved in the numeric named buffers (3.5). | |
520 | .iP "v" 15 | |
521 | Unused. | |
522 | .iP "w" 15 | |
523 | Advances to the beginning of the next word, as defined by \fBb\fR (2.4). | |
524 | .iP "x" 15 | |
525 | Deletes the single character under the cursor. With a count deletes | |
526 | deletes that many characters forward from the cursor position, but only | |
527 | on the current line (6.5). | |
528 | .iP "y" 15 | |
529 | An operator, yanks the following object into the unnamed temporary buffer. | |
530 | If preceded by a named buffer specification, \fB"\fR\fIx\fR, the text | |
531 | is placed in that buffer also. Text can be recovered by a later \fBp\fR | |
532 | or \fBP\fR (7.4). | |
533 | .iP "z" 15 | |
534 | Redraws the screen with the current line placed as specified by the following | |
535 | character: \s-2RETURN\s0 specifies the top of the screen, \fB.\fR the | |
536 | center of the screen, and \fB\-\fR at the bottom of the screen. | |
537 | A count may be given after the \fBz\fR and before the following character | |
538 | to specify the new screen size for the redraw. | |
539 | A count before the \fBz\fR gives the number of the line to place in the | |
540 | center of the screen instead of the default current line. | |
541 | .iP "{" 15 | |
542 | Retreats to the beginning of the beginning of the preceding paragraph. | |
543 | A paragraph begins at each macro in the \fIparagraphs\fR option, normally | |
544 | `.IP', `.LP', `.PP', `.QP' and `.bp'. | |
545 | A paragraph also begins after a completely | |
546 | empty line, and at each section boundary (see \fB[[\fR above) (4.2, 6.8, | |
547 | 7.6). | |
548 | .iP "|" 15 | |
549 | Places the cursor on the character in the column specified | |
550 | by the count (7.1, 7.2). | |
551 | .iP "}" 15 | |
552 | Advances to the beginning of the next paragraph. See \fB{\fR for the | |
553 | definition of paragraph (4.2, 6.8, 7.6). | |
554 | .iP "~" 15 | |
555 | Unused. | |
556 | .iP "^?\ (\s-2\fRDEL\fP\s0)" 15 | |
557 | Interrupts the editor, returning it to command accepting state (1.5, | |
558 | 7.5) | |
559 | .bp | |
560 | \&. |