1 @comment Copyright (c) 1994
2 @comment The Regents of the University of California. All rights reserved.
3 @comment Copyright (c) 1994, 1995, 1996
4 @comment Keith Bostic. All rights reserved.
6 @comment See the LICENSE file for redistribution information.
8 @comment Id: vi.cmd.texi,v 8.1 2001/08/18 20:43:49 skimo Exp (Berkeley) Date: 2001/08/18 20:43:49
10 @chapter Vi Description
12 @CO{Vi} takes up the entire screen to display the edited file,
13 except for the bottom line of the screen.
14 The bottom line of the screen is used to enter
18 error and informational messages.
19 If no other information is being displayed,
20 the default display can show the current cursor row and cursor column,
21 an indication of whether the file has been modified,
22 and the current mode of the editor.
27 options for more information.
29 Empty lines do not have any special representation on the screen,
30 but lines on the screen that would logically come after the end of
31 the file are displayed as a single tilde
34 To differentiate between empty lines and lines consisting of only
35 whitespace characters, use the
38 Historically, implementations of
40 have also displayed some lines as single asterisk
43 These were lines that were not correctly displayed, i.e. lines on the
44 screen that did not correspond to lines in the file, or lines that did
45 not fit on the current screen.
47 never displays lines in this fashion.
50 is a modeful editor, i.e. it has two modes,
57 first starts, it is in command mode.
58 There are several commands that change
62 @LI{<escape>}character is used to resolve the text input into the file,
63 and exit back into command mode.
66 command mode, the cursor is always positioned on the last column of
67 characters which take up more than one column on the screen.
70 text insert mode, the cursor is positioned on the first column of
71 characters which take up more than one column on the screen.
73 When positioning the cursor to a new line and column,
74 the type of movement is defined by the distance to the new cursor position.
75 If the new position is close,
76 the screen is scrolled to the new location.
77 If the new position is far away,
78 the screen is repainted so that the new position is on the screen.
79 If the screen is scrolled,
80 it is moved a minimal amount,
81 and the cursor line will usually appear at the top or bottom of the screen.
82 If the screen is repainted,
83 the cursor line will appear in the center of the screen,
84 unless the cursor is sufficiently close to the beginning or end of the file
85 that this isn't possible.
88 option is set, the screen may be scrolled or repainted in a horizontal
89 direction as well as in a vertical one.
91 A major difference between the historical
95 is in the scrolling and screen oriented position commands,
106 In historical implementations of
108 these commands acted on physical (as opposed to logical, or screen)
110 For lines that were sufficiently long in relation to the size of the
111 screen, this meant that single line scroll commands might repaint the
112 entire screen, scrolling or screen positioning commands might not change
113 the screen or move the cursor at all, and some lines simply could not
114 be displayed, even though
116 would edit the file that contained them.
119 these commands act on logical, i.e. screen lines.
120 You are unlikely to notice any difference unless you are editing files
121 with lines significantly longer than a screen width.
124 keeps track of the currently
127 Each command description (for commands that alter the current cursor
129 specifies if the cursor is set to a specific location in the line,
130 or if it is moved to the
131 @QQ{most attractive cursor position}.
132 The latter means that the cursor is moved to the cursor position that
133 is horizontally as close as possible to the current cursor position.
134 If the current line is shorter than the cursor position
136 would select, the cursor is positioned on the last character in the line.
137 (If the line is empty, the cursor is positioned on the first column
139 If a command moves the cursor to the most attractive position,
140 it does not alter the current cursor position, and a subsequent
141 movement will again attempt to move the cursor to that position.
142 Therefore, although a movement to a line shorter than the currently
143 most attractive position will cause the cursor to move to the end of
144 that line, a subsequent movement to a longer line will cause the
145 cursor to move back to the most attractive position.
149 command makes the end of each line the most attractive cursor position
150 rather than a specific column.
154 command described below notes where the cursor ends up after it is
156 This position is described in terms of characters on the line, i.e.
157 @QQ{the previous character},
159 @QQ{the last character in the line}.
160 This is to avoid needing to continually refer to on what part of the
161 character the cursor rests.
163 The following words have special meaning for
167 @cindex "previous context"
168 @IP{previous context}
170 The position of the cursor before the command which caused the
171 last absolute movement was executed.
174 command described in the next section that is considered an
175 absolute movement is so noted.
176 In addition, specifying
180 command is considered an absolute movement.
186 command can be used as an optional trailing argument to the
194 and (depending on the
199 This command indicates the end of the region of text that's affected by
201 The motion command may be either the command character repeated (in
202 which case it means the current line) or a cursor movement command.
203 In the latter case, the region affected by the command is from the
204 starting or stopping cursor position which comes first in the file,
205 to immediately before the starting or stopping cursor position which
206 comes later in the file.
207 Commands that operate on lines instead of using beginning and ending
208 cursor positions operate on all of the lines that are wholly or
209 partially in the region.
210 In addition, some other commands become line oriented depending on
211 where in the text they are used.
212 The command descriptions below note these special cases.
214 The following commands may all be used as motion components for
218 @multitable {@CO{<control-N>}} {@CO{'<character>}} {@CO{<control-J>}} {@CO{<control-M>}}
219 @item @CO{<control-A>} @tab @CO{<control-H>} @tab @CO{<control-J>} @tab @CO{<control-M>}
220 @item @CO{<control-N>} @tab @CO{<control-P>} @tab @CO{<space>} @tab @CO{$}
221 @item @CO{%} @tab @CO{'<character>} @tab @CO{(} @tab @CO{)}
222 @item @CO{+} @tab @CO{,} @tab @CO{-} @tab @CO{/}
223 @item @CO{0} @tab @CO{;} @tab @CO{?} @tab @CO{B}
224 @item @CO{E} @tab @CO{F} @tab @CO{G} @tab @CO{H}
225 @item @CO{L} @tab @CO{M} @tab @CO{N} @tab @CO{T}
226 @item @CO{W} @tab @CO{[[} @tab @CO{]]} @tab @CO{^}
227 @item @CO{_} @tab @CO{`<character>} @tab @CO{b} @tab @CO{e}
228 @item @CO{f} @tab @CO{h} @tab @CO{j} @tab @CO{k}
229 @item @CO{l} @tab @CO{n} @tab @CO{t} @tab @CO{w}
230 @item @strong{@{} @tab @CO{|} @tab @strong{@}}
233 The optional count prefix available for some of the
235 commands that take motion commands,
236 or the count prefix available for the
238 commands that are used as motion components,
239 may be included and is
241 considered part of the motion argument.
242 For example, the commands
246 are equivalent, and the region affected by the
248 command is two words of text.
250 if the optional count prefix is specified for both the
252 command and its motion component,
253 the effect is multiplicative and is considered part of the motion argument.
254 For example, the commands
258 are equivalent, and the region affected by the
260 command is four words of text.
264 A positive number used as an optional argument to most commands,
265 either to give a size or a position (for display or movement commands),
266 or as a repeat count (for commands that modify text).
267 The count argument is always optional and defaults to 1 unless otherwise
268 noted in the command description.
272 command synopsis shows both a
275 they may be presented in any order.
279 Generally, in languages where it is applicable,
281 recognizes two kinds of words.
282 First, a sequence of letters, digits and underscores,
283 delimited at both ends by:
284 characters other than letters, digits, or underscores,
285 the beginning or end of a line, and the beginning or end of the file.
286 Second, a sequence of characters other than letters, digits, underscores,
287 or whitespace characters, delimited at both ends by: a letter, digit,
288 underscore, or whitespace character,
289 the beginning or end of a line, and the beginning or end of the file.
290 For example, the characters
298 Groups of empty lines (or lines containing only whitespace characters)
299 are treated as a single word.
303 A set of non-whitespace characters preceded and followed by whitespace
304 characters or the beginning or end of the file or line.
305 For example, the characters
310 Groups of empty lines (or lines containing only whitespace characters)
311 are treated as a single bigword.
315 An area of text that begins with either the beginning of a file,
316 an empty line, or a section boundary, and continues until either
317 an empty line, section boundary, or the end of the file.
319 Groups of empty lines (or lines containing only whitespace characters)
320 are treated as a single paragraph.
322 Additional paragraph boundaries can be defined using the
328 An area of text that starts with the beginning of the file or a line
329 whose first character is an open brace
332 and continues until the next section or the end of the file.
334 Additional section boundaries can be defined using the
340 An area of text that begins with either the beginning of the file or the
341 first nonblank character following the previous sentence, paragraph, or
342 section boundary and continues until the end of the file or a period
349 followed by either an end-of-line or two whitespace characters.
350 Any number of closing parentheses
358 characters can appear between the period, exclamation point,
359 or question mark and the whitespace characters or end-of-line.
361 Groups of empty lines (or lines containing only whitespace characters)
362 are treated as a single sentence.
366 The following section describes the commands available in the command
370 In each entry below, the tag line is a usage synopsis for the command
372 In addition, the final line and column the cursor rests upon,
373 and any options which affect the command are noted.
376 @deftypefn Command {[count]} {<control-A>}
379 @LI{count}times for the current word.
380 The current word begins at the first non-whitespace character on or
381 after the current cursor position,
382 and extends up to the next non-word character or the end of the line.
383 The search is literal, i.e. no characters in the word have any special
384 meaning in terms of Regular Expressions.
385 It is an error if no matching pattern is found between the starting position
386 and the end of the file.
390 command is an absolute movement.
393 command may be used as the motion component of other
395 commands, in which case any text copied into a buffer is
399 Set to the line where the word is found.
401 Set to the first character of the word.
411 @deftypefn Command {[count]} {<control-B>}
415 Two lines of overlap are maintained, if possible,
416 by displaying the window starting at line
417 @LI{(top_line - count * window_size) + 2},
419 @LI{window_size}is the value of the
422 (In the case of split screens, this size is corrected to the
423 current screen size.)
424 It is an error if the movement is past the beginning of the file.
427 Set to the last line of text displayed on the screen.
429 Set to the first nonblank character of the line.
437 @deftypefn Command {[count]} {<control-D>}
442 @LI{count}is not specified, scroll forward the number of lines specified by the last
452 scroll forward half the number of lines in the screen.
453 (In the case of split screens, the default scrolling distance is
454 corrected to half the current screen size.)
455 It is an error if the movement is past the end of the file.
458 Set to the current line plus the number of lines scrolled.
460 Set to the first nonblank character of the line.
466 @deftypefn Command {[count]} {<control-E>}
469 @LI{count}lines, leaving the cursor on the current line and column, if possible.
470 It is an error if the movement is past the end of the file.
473 Unchanged unless the current line scrolls off the screen,
474 in which case it is set to the first line on the screen.
476 Unchanged unless the current line scrolls off the screen,
477 in which case it is set to the most attractive cursor position.
483 @deftypefn Command {[count]} {<control-F>}
487 Two lines of overlap are maintained, if possible,
488 by displaying the window starting at line
489 @LI{top_line + count * window_size - 2},
491 @LI{window_size}is the value of the
494 (In the case of split screens, this size is corrected to the
495 current screen size.)
496 It is an error if the movement is past the end of the file.
499 Set to the first line on the screen.
501 Set to the first nonblank character of the current line.
509 @deftypefn Command {} {<control-G>}
511 Display the file information.
512 The information includes the current pathname, the current line,
513 the number of total lines in the file, the current line as a percentage
514 of the total lines in the file, if the file has been modified,
515 was able to be locked, if the file's name has been changed,
516 and if the edit session is read-only.
528 @deftypefn Command {[count]} {<control-H>}
529 @deftypefnx Command {[count]} {h}
531 @LI{count}characters in the current line.
532 It is an error if the cursor is on the first character in the line.
538 commands may be used as the motion component of other
541 in which case any text copied into a buffer is character oriented.
547 @LI{current - count}character, or, the first character in the line if
548 @LI{count}is greater than or equal to the number of characters in the line
556 @deftypefn Command {[count]} {<control-J>}
559 @deftypefnx Command {[count]} {<control-N>}
561 @deftypefnx Command {[count]} {j}
563 @LI{count}lines without changing the current column.
564 It is an error if the movement is past the end of the file.
571 commands may be used as the motion component of other
573 commands, in which case any text copied into a buffer is
577 Set to the current line plus
580 The most attractive cursor position.
586 @deftypefn Command {} {<control-L>}
589 @deftypefnx Command {} {<control-R>}
601 @deftypefn Command {[count]} {<control-M>}
604 @deftypefnx Command {[count]} {+}
606 @LI{count}lines to the first nonblank character of that line.
607 It is an error if the movement is past the end of the file.
613 commands may be used as the motion component of other
615 commands, in which case any text copied into a buffer is
619 Set to the current line plus
622 Set to the first nonblank character in the line.
628 @deftypefn Command {[count]} {<control-P>}
631 @deftypefnx Command {[count]} {k}
633 @LI{count}lines, without changing the current column.
634 It is an error if the movement is past the beginning of the file.
640 commands may be used as the motion component of other
642 commands, in which case any text copied into a buffer is
646 Set to the current line minus
649 The most attractive cursor position.
655 @deftypefn Command {} {<control-T>}
657 Return to the most recent tag context.
660 command is an absolute movement.
663 Set to the context of the previous tag command.
665 Set to the context of the previous tag command.
671 @deftypefn Command {[count]} {<control-U>}
676 @LI{count}is not specified, scroll backward the number of lines specified by the
687 scroll backward half the number of lines in the screen.
688 (In the case of split screens, the default scrolling distance is
689 corrected to half the current screen size.)
690 It is an error if the movement is past the beginning of the file.
693 Set to the current line minus the amount scrolled.
695 Set to the first nonblank character in the line.
701 @deftypefn Command {} {<control-W>}
703 Switch to the next lower screen in the window, or, to the first
704 screen if there are no lower screens in the window.
707 Set to the previous cursor position in the window.
709 Set to the previous cursor position in the window.
715 @deftypefn Command {[count]} {<control-Y>}
718 @LI{count}lines, leaving the current line and column as is, if possible.
719 It is an error if the movement is past the beginning of the file.
722 Unchanged unless the current line scrolls off the screen,
723 in which case it is set to the last line of text displayed
726 Unchanged unless the current line scrolls off the screen,
727 in which case it is the most attractive cursor position.
733 @deftypefn Command {} {<control-Z>}
735 Suspend the current editor session.
736 If the file has been modified since it was last completely written,
739 option is set, the file is written before the editor session is
741 If this write fails, the editor session is not suspended.
754 @deftypefn Command {} {<escape>}
758 commands or cancel partial commands.
761 command is being entered (e.g.
767 the command is executed.
768 If a partial command has been entered, e.g.
772 the command is cancelled.
773 Otherwise, it is an error.
778 command is being executed, the current line is set as described for
780 Otherwise, unchanged.
784 command is being executed, the current column is set as described for
786 Otherwise, unchanged.
792 @deftypefn Command {} {<control-]>}
794 Push a tag reference onto the tag stack.
795 The tags files (see the
797 option for more information) are searched for a tag matching the
799 The current word begins at the first non-whitespace character on or
800 after the current cursor position,
801 and extends up to the next non-word character or the end of the line.
802 If a matching tag is found, the current file is discarded and the
803 file containing the tag reference is edited.
805 If the current file has been modified since it was last completely
806 written, the command will fail.
809 command is an absolute movement.
812 Set to the line containing the matching tag string.
814 Set to the start of the matching tag string.
824 @deftypefn Command {} {<control-^>}
826 Switch to the most recently edited file.
828 If the file has been modified since it was last completely written,
831 option is set, the file is written out.
832 If this write fails, the command will fail.
833 Otherwise, if the current file has been modified since it was last
834 completely written, the command will fail.
837 Set to the line the cursor was on when the file was last edited.
839 Set to the column the cursor was on when the file was last edited.
847 @deftypefn Command {[count]} {<space>}
850 @deftypefnx Command {[count]} {l}
851 Move the cursor forward
852 @LI{count}characters without changing the current line.
853 It is an error if the cursor is on the last character in the line.
859 commands may be used as the motion component of other
861 commands, in which case any text copied into a buffer is
863 In addition, these commands may be used as the motion components
864 of other commands when the cursor is on the last character in the
870 Set to the current character plus the next
871 @LI{count}characters, or to the last character on the line if
872 @LI{count}is greater than the number of characters in the line after the
879 @deftypefn Command {[count]} {!} {motion shell-argument(s)<carriage-return>}
881 Replace text with results from a shell command.
882 Pass the lines specified by the
884 @LI{motion}arguments as standard input to the program named by the
886 option, and replace those lines with the output (both
887 standard error and standard output) of that command.
889 After the motion is entered,
891 prompts for arguments to the shell command.
893 Within those arguments,
897 characters are expanded to the current and alternate pathnames,
901 character is expanded with the command text of the previous
906 (Therefore, the command
911 The special meanings of
916 can be overridden by escaping them with a backslash.
921 command has yet been executed,
922 it is an error to use an unescaped
924 character as a shell argument.
929 do shell expansion on the strings provided as arguments.
930 If any of the above expansions change the arguments the user entered,
931 the command is redisplayed at the bottom of the screen.
934 then executes the program named by the
938 flag followed by the arguments (which are bundled into a single argument).
942 command is permitted in an empty file.
944 If the file has been modified since it was last completely written,
947 command will warn you.
950 The first line of the replaced text.
952 The first column of the replaced text.
960 @deftypefn Command {[count]} {#} {#|+|-}
962 Increment or decrement the number referenced by the cursor.
963 If the trailing character is a
966 the number is incremented by
968 If the trailing character is a
970 the number is decremented by
977 causes the number to be interpreted as a hexadecimal number.
980 causes the number to be interpreted as an octal number, unless a non-octal
981 digit is found as part of the number.
982 Otherwise, the number is interpreted as a decimal number, and may
986 The current number begins at the first non-blank character at or after
987 the current cursor position, and extends up to the end of the line or
988 the first character that isn't a possible character for the numeric type.
989 The format of the number (e.g. leading 0's, signs) is retained unless
990 the new value cannot be represented in the previous format.
992 Octal and hexadecimal numbers, and the result of the operation, must fit
995 Similarly, decimal numbers and their result must fit into a
997 It is an error to use this command when the cursor is not positioned at
1004 Set to the first character in the cursor number.
1010 @deftypefn Command {[count]} {$}
1012 Move the cursor to the end of a line.
1014 @LI{count}is specified, the cursor moves down
1015 @LI{count - 1}lines.
1017 It is not an error to use the
1019 command when the cursor is on the last character in the line or
1020 when the line is empty.
1024 command may be used as the motion component of other
1026 commands, in which case any text copied into a buffer is
1027 character oriented, unless the cursor is at, or before the first
1028 nonblank character in the line, in which case it is line oriented.
1029 It is not an error to use the
1031 command as a motion component when the cursor is on the last character
1032 in the line, although it is an error when the line is empty.
1035 Set to the current line plus
1038 Set to the last character in the line.
1044 @deftypefn Command {} {%}
1046 Move to the matching character.
1047 The cursor moves to the bracket character which
1049 the bracket found at the current cursor position
1050 or which is the closest one to the right of the cursor on the line.
1051 The bracket characters are defined by the
1054 An error will be reported if none of the
1056 characters is found, or if no matching character is found.
1057 If the open and close brackes are identical (e.g.: if they are
1063 command will perform a backwards search from the original opening bracket.
1065 @LI{count}specified to the
1067 command was ignored.
1071 command is an absolute movement.
1074 command may be used as the motion component of other
1076 commands, in which case any text copied into a buffer is
1077 character oriented, unless the starting point of the region is at
1078 or before the first nonblank character on its line, and the ending
1079 point is at or after the last nonblank character on its line, in
1080 which case it is line oriented.
1083 Set to the line containing the matching character.
1085 Set to the matching character.
1091 @deftypefn Command {} {&}
1093 Repeat the previous substitution command on the current line.
1096 @LI{count}specified to the
1098 command was ignored.
1103 Unchanged if the cursor was on the last character in the line,
1104 otherwise, set to the first nonblank character in the line.
1115 @cindex SQUOTE<character>
1116 @deftypefn Command {} {'<character>}
1118 @cindex `<character>
1119 @deftypefnx Command {} `<character>
1120 Return to a context marked by the character
1123 @LI{<character>}is the
1127 character, return to the previous context.
1129 @LI{<character>}is any other character,
1130 return to the context marked by that character (see the
1132 command for more information).
1133 If the command is the
1135 command, only the line value is restored,
1136 and the cursor is placed on the first nonblank character of that line.
1137 If the command is the
1139 command, both the line and column values are restored.
1141 It is an error if the context no longer exists because of
1143 (Contexts follow lines that are moved, or which are deleted
1150 commands are both absolute movements.
1151 They may be used as a motion component for other
1156 command, any text copied into a buffer is line oriented.
1160 any text copied into a buffer is character oriented,
1161 unless it both starts and stops at the first character in the line,
1162 in which case it is line oriented.
1163 In addition, when using the
1165 command as a motion component,
1166 commands which move backward and started at the first character in the line,
1167 or move forward and ended at the first character in the line,
1168 are corrected to the last character of the line preceding the starting and
1169 ending lines, respectively.
1172 Set to the line from the context.
1174 Set to the first nonblank character in the line, for the
1176 command, and set to the context's column for the
1184 @deftypefn Command {} {[count] (}
1187 @LI{count}sentences.
1191 command is an absolute movement.
1194 command may be used as the motion component of other
1197 in which case any text copied into a buffer is character oriented,
1198 unless the starting and stopping points of the region are the first
1199 character in the line,
1200 in which case it is line oriented.
1201 If it is line oriented,
1202 the starting point of the region is adjusted to be the end of the line
1203 immediately before the starting cursor position.
1206 Set to the line containing the beginning of the sentence.
1208 Set to the first nonblank character of the sentence.
1216 @deftypefn Command {[count]} {)}
1219 @LI{count}sentences.
1223 command is an absolute movement.
1226 command may be used as the motion component of other
1228 commands, in which case any text copied into a buffer is
1229 character oriented, unless the starting point of the region is the
1230 first character in the line, in which case it is line oriented.
1231 In the latter case, if the stopping point of the region is also
1232 the first character in the line, it is adjusted to be the end of the
1233 line immediately before it.
1236 Set to the line containing the beginning of the sentence.
1238 Set to the first nonblank character of the sentence.
1246 @deftypefn Command {[count]} {,}
1248 Reverse find character
1256 command, searching the other way in the line,
1264 command has not been performed yet.
1268 command may be used as the motion component of other
1270 commands, in which case any text copied into a buffer is
1276 Set to the searched-for character for the
1281 before the character for the
1284 and after the character for the
1292 @deftypefn Command {[count]} {-}
1294 Move to the first nonblank of the previous line,
1297 It is an error if the movement is past the beginning of the file.
1301 command may be used as the motion component of other
1303 commands, in which case any text copied into a buffer is
1307 Set to the current line minus
1310 Set to the first nonblank character in the line.
1316 @deftypefn Command {[count]} {.}
1320 command that modified text.
1321 The repeated command may be a command and motion component combination.
1323 @LI{count}is specified, it replaces
1325 the count specified for the repeated command, and, if applicable, for
1326 the repeated motion component.
1328 @LI{count}is not specified, the counts originally specified to the command being
1329 repeated are used again.
1331 As a special case, if the
1333 command is executed immediately after the
1335 command, the change log is rolled forward or backward, depending on
1341 Set as described for the repeated command.
1343 Set as described for the repeated command.
1349 @deftypefn Command {} {/RE<carriage-return>}
1351 @deftypefnx Command {} {/RE/} {[offset]<carriage-return>}
1353 @deftypefnx Command {} {?RE<carriage-return>}
1354 @deftypefnx Command {} {?RE?} {[offset]<carriage-return>}
1356 @deftypefnx Command {} N
1358 @deftypefnx Command {} n
1359 Search forward or backward for a regular expression.
1360 The commands beginning with a slash
1362 character are forward searches, the commands beginning with a
1365 are backward searches.
1367 prompts with the leading character on the last line of the screen
1369 It then searches forward or backward in the file for the next
1370 occurrence of the string, which is interpreted as a Basic Regular
1377 commands are absolute movements.
1378 They may be used as the motion components of other
1380 commands, in which case any text copied into a buffer is
1381 character oriented, unless the search started and ended on
1382 the first column of a line, in which case it is line oriented.
1383 In addition, forward searches ending at the first character of a line,
1384 and backward searches beginning at the first character in the line,
1385 are corrected to begin or end at the last character of the previous line.
1386 (Note, forward and backward searches can occur for both
1394 If an offset from the matched line is specified (i.e. a trailing
1398 character is followed by a signed offset), the buffer will always
1399 be line oriented (e.g.
1401 will always guarantee a line orientation).
1405 command repeats the previous search, but in the reverse direction.
1408 command repeats the previous search.
1413 commands are used as motion components for the
1415 command, you will not be prompted for the text of the bang command,
1416 instead the previous bang command will be executed.
1419 @QT{//<carriage-return>},
1420 @QT{/<carriage-return>},
1421 @QT{??<carriage-return>},
1423 @QT{?<carriage-return>}
1424 search for the last search RE, in the indicated direction.
1426 Searches may be interrupted using the
1427 @LI{<interrupt>}character.
1429 Multiple search patterns may be grouped together by delimiting
1430 them with semicolons and zero or more whitespace characters, e.g.
1431 @LI{/foo/ ; ?bar?}searches forward for
1432 @LI{foo}and then, from that location, backwards for
1434 When search patterns are grouped together in this manner,
1435 the search patterns are evaluated left to right with the
1436 final cursor position determined by the last search pattern.
1438 It is also permissible to append a
1440 command to the search strings, e.g.
1441 @LI{/foo/ z.}searches forward for the next occurrence of
1443 and then positions that line in the middle of screen.
1446 Set to the line in which the match occurred.
1448 Set to the first character of the matched string.
1461 @deftypefn Command {} {0}
1463 Move to the first character in the current line.
1464 It is not an error to use the
1466 command when the cursor is on the first character in the line,
1470 command may be used as the motion component of other
1473 in which case it is an error if the cursor is on the first character
1475 and any text copied into a buffer is character oriented.
1480 Set to the first character in the line.
1486 @deftypefn Command {} {:}
1494 command on the last line of the screen, using a colon
1497 The command is terminated by a
1498 @LI{<carriage-return>},
1500 @LI{<escape>}character; all of these characters may be escaped by using a
1501 @LI{<literal-next>}character.
1502 The command is then executed.
1506 command writes to the screen,
1508 will prompt the user for a
1509 @LI{<carriage-return>}before continuing
1513 Large amounts of output from the
1515 command will be paged for the user, and the user prompted for a
1516 @LI{<carriage-return>}or
1517 @LI{<space>}key to continue.
1518 In some cases, a quit (normally a
1521 @LI{<interrupt>}may be entered to interrupt the
1527 command finishes, and the user is prompted to resume visual mode,
1528 it is also possible to enter another
1530 character followed by another
1535 The current line is set as described for the
1539 The current column is set as described for the
1543 Affected as described for the
1549 @deftypefn Command {[count]} {;}
1551 Repeat the last character find
1553 The last character find is one of the
1566 command has not been performed yet.
1570 command may be used as the motion component of other
1572 commands, in which case any text copied into a buffer is
1578 Set to the searched-for character for the
1583 before the character for the
1586 and after the character for the
1594 @deftypefn Command {[count]} {< motion}
1597 @deftypefnx Command {[count]} {>} {motion}
1598 Shift lines left or right.
1599 Shift the number of lines in the region specified by the
1601 @LI{motion}left (for the
1603 command) or right (for the
1605 command) by the number of columns specified by the
1608 Only whitespace characters are deleted when shifting left.
1609 Once the first character in the line no longer contains a whitespace
1610 character, the command will succeed,
1611 but the line will not be modified.
1616 Set to the first nonblank character in the line.
1624 @deftypefn Command {} {@@} {buffer}
1626 Execute a named buffer.
1627 Execute the named buffer as
1630 The buffer may include
1632 commands, too, but they must be expressed as a
1635 If the buffer is line oriented,
1636 @LI{<newline>}characters are logically appended to each line of the buffer.
1637 If the buffer is character oriented,
1638 @LI{<newline>}characters are logically appended to all but the last line in the buffer.
1640 If the buffer name is
1644 then the last buffer executed shall be used.
1645 It is an error to specify
1649 if there were no previous buffer executions.
1650 The text of a buffer may contain a
1653 and it is possible to create infinite loops in this manner.
1655 @LI{<interrupt>}character may be used to interrupt the loop.)
1658 The current line is set as described for the command(s).
1660 The current column is set as described for the command(s).
1666 @deftypefn Command {[count]} {A}
1668 Enter input mode, appending the text after the end of the line.
1670 @LI{count}is specified, the text is repeatedly input
1671 @LI{count - 1}more times after input mode is exited.
1674 Set to the last line upon which characters were entered.
1676 Set to the last character entered.
1690 @deftypefn Command {[count]} {B}
1694 Move the cursor backward to the beginning of a bigword by repeating the
1695 following algorithm: if the current position is at the beginning of a
1696 bigword or the character at the current position cannot be part of a bigword,
1697 move to the first character of the preceding bigword.
1698 Otherwise, move to the first character of the bigword at the current position.
1699 If no preceding bigword exists on the current line, move to the first
1700 character of the last bigword on the first preceding line that contains a
1705 command may be used as the motion component of other
1707 commands, in which case any text copied into a buffer is
1711 Set to the line containing the word selected.
1713 Set to the first character of the word selected.
1719 @deftypefn Command {[buffer]} {[count] C}
1721 Change text from the current position to the end-of-line.
1723 @LI{count}is specified, the input text replaces from the current position to
1724 the end-of-line, plus
1725 @LI{count - 1}subsequent lines.
1728 Set to the last line upon which characters were entered.
1730 Set to the last character entered.
1744 @deftypefn Command {[buffer]} {D}
1746 Delete text from the current position to the end-of-line.
1748 It is not an error to execute the
1750 command on an empty line.
1755 Set to the character before the current character, or, column 1 if
1756 the cursor was on column 1.
1762 @deftypefn Command {[count]} {E}
1765 @LI{count}end-of-bigwords.
1766 Move the cursor forward to the end of a bigword by repeating the
1767 following algorithm: if the current position is the end of a
1768 bigword or the character at that position cannot be part of a bigword,
1769 move to the last character of the following bigword.
1770 Otherwise, move to the last character of the bigword at the current
1772 If no succeeding bigword exists on the current line,
1773 move to the last character of the first bigword on the next following
1774 line that contains a bigword.
1778 command may be used as the motion component of other
1780 commands, in which case any text copied into a buffer is
1784 Set to the line containing the word selected.
1786 Set to the last character of the word selected.
1792 @deftypefn Command {[count]} {F} {<character>}
1795 @LI{count}times backward through the current line for
1800 command may be used as the motion component of other
1802 commands, in which case any text copied into a buffer is
1808 Set to the searched-for character.
1814 @deftypefn Command {[count]} {G}
1818 or the last line of the file if
1819 @LI{count}not specified.
1823 command is an absolute movement.
1826 command may be used as the motion component of other
1828 commands, in which case any text copied into a buffer is
1834 if specified, otherwise, the last line.
1836 Set to the first nonblank character in the line.
1842 @deftypefn Command {[count]} {H}
1844 Move to the screen line
1845 @LI{count - 1}lines below the top of the screen.
1849 command is an absolute movement.
1852 command may be used as the motion component of other
1854 commands, in which case any text copied into a buffer is
1859 @LI{count - 1}lines below the top of the screen.
1861 Set to the first nonblank character of the
1869 @deftypefn Command {[count]} {I}
1871 Enter input mode, inserting the text at the beginning of the line.
1873 @LI{count}is specified, the text input is repeatedly input
1874 @LI{count - 1}more times.
1877 Set to the last line upon which characters were entered.
1879 Set to the last character entered.
1885 @deftypefn Command {[count]} {J}
1889 @LI{count}is specified,
1890 @LI{count}lines are joined; a minimum of two lines are always joined,
1891 regardless of the value of
1894 If the current line ends with a whitespace character, all whitespace
1895 is stripped from the next line.
1896 Otherwise, if the next line starts with a open parenthesis
1899 Otherwise, if the current line ends with a question mark
1903 or exclamation point
1906 Otherwise, insert a single space.
1908 It is not an error to join lines past the end of the file,
1909 i.e. lines that do not exist.
1914 Set to the character after the last character of the next-to-last
1921 @deftypefn Command {[count]} {L}
1923 Move to the screen line
1924 @LI{count - 1}lines above the bottom of the screen.
1928 command is an absolute movement.
1931 command may be used as the motion component of other
1933 commands, in which case any text copied into a buffer is
1938 @LI{count - 1}lines above the bottom of the screen.
1940 Set to the first nonblank character of the
1948 @deftypefn Command {} {M}
1950 Move to the screen line in the middle of the screen.
1954 command is an absolute movement.
1957 command may be used as the motion component of other
1959 commands, in which case any text copied into a buffer is
1963 @LI{count}specified to the
1965 command was ignored.
1968 Set to the line in the middle of the screen.
1970 Set to the first nonblank character of the
1978 @deftypefn Command {[count]} {O}
1980 Enter input mode, appending text in a new line above the current line.
1982 @LI{count}is specified, the text input is repeatedly input
1983 @LI{count - 1}more times.
1986 @LI{count}specified to the
1988 command was ignored.
1991 Set to the last line upon which characters were entered.
1993 Set to the last character entered.
2007 @deftypefn Command {[buffer]} {P}
2009 Insert text from a buffer.
2010 Text from the buffer (the unnamed buffer by default) is inserted
2011 before the current column or, if the buffer is line oriented,
2012 before the current line.
2015 Set to the lowest numbered line insert,
2016 if the buffer is line oriented, otherwise unchanged.
2018 Set to the first nonblank character of the appended text,
2019 if the buffer is line oriented, otherwise, the last character
2020 of the appended text.
2026 @deftypefn Command {} {Q}
2030 (or visual) mode and switch to
2043 @deftypefn Command {[count]} {R}
2045 Enter input mode, replacing the characters in the current line.
2047 @LI{count}is specified, the text input is repeatedly input
2048 @LI{count - 1}more times.
2050 If the end of the current line is reached, no more characters are
2051 replaced and any further characters input are appended to the line.
2054 Set to the last line upon which characters were entered.
2056 Set to the last character entered.
2070 @deftypefn Command {[buffer] [count]} {S}
2076 Set to the last line upon which characters were entered.
2078 Set to the last character entered.
2092 @deftypefn Command {[count]} {T} {<character>}
2096 through the current line for the character
2103 command may be used as the motion component of other
2105 commands, in which case any text copied into a buffer is
2111 Set to the character
2113 the searched-for character.
2119 @deftypefn Command {} {U}
2121 Restore the current line to its state before the cursor last
2127 The first character in the line.
2133 @deftypefn Command {[count]} {W}
2137 Move the cursor forward to the beginning of a bigword by repeating the
2138 following algorithm: if the current position is within a bigword or the
2139 character at that position cannot be part of a bigword, move to the first
2140 character of the next bigword.
2141 If no subsequent bigword exists on the current line,
2142 move to the first character of the first bigword on the first following
2143 line that contains a bigword.
2147 command may be used as the motion component of other
2149 commands, in which case any text copied into a buffer is
2153 The line containing the word selected.
2155 The first character of the word selected.
2161 @deftypefn Command {[buffer] [count]} {X}
2164 @LI{count}characters before the cursor.
2165 If the number of characters to be deleted is greater than or equal to
2166 the number of characters to the beginning of the line, all of the
2167 characters before the current cursor position, to the beginning of the
2173 Set to the current character minus
2175 or the first character if count is greater than the number of
2176 characters in the line before the cursor.
2182 @deftypefn Command {[buffer] [count]} {Y}
2186 @LI{count}lines into the specified buffer.
2197 @deftypefn Command {} {ZZ}
2199 Write the file and exit
2201 The file is only written if it has been modified since the last
2202 complete write of the file to any file.
2206 command will exit the editor after writing the file,
2207 if there are no further files to edit.
2216 in a row will override this check and the editor will exit,
2217 ignoring any files that have not yet been edited.
2228 @deftypefn Command {[count]} {[[}
2231 @LI{count}section boundaries.
2235 command is an absolute movement.
2238 command may be used as the motion component of other
2240 commands, in which case any text copied into a buffer is
2241 character oriented, unless the starting position is column 0,
2242 in which case it is line oriented.
2244 It is an error if the movement is past the beginning of the file.
2247 Set to the previous line that is
2248 @LI{count}section boundaries back,
2249 or the first line of the file if no more section boundaries exist
2250 preceding the current line.
2252 Set to the first nonblank character in the line.
2260 @deftypefn Command {[count]} {]]}
2263 @LI{count}section boundaries.
2267 command is an absolute movement.
2270 command may be used as the motion component of other
2272 commands, in which case any text copied into a buffer is
2273 character oriented, unless the starting position is column 0,
2274 in which case it is line oriented.
2276 It is an error if the movement is past the end of the file.
2279 Set to the line that is
2280 @LI{count}section boundaries forward,
2281 or to the last line of the file if no more section
2282 boundaries exist following the current line.
2284 Set to the first nonblank character in the line.
2292 @deftypefn Command {} {^}
2294 Move to first nonblank character on the current line.
2298 command may be used as the motion component of other
2300 commands, in which case any text copied into a buffer is
2306 Set to the first nonblank character of the current line.
2312 @deftypefn Command {[count]} {_}
2315 @LI{count - 1}lines, to the first nonblank character.
2318 command may be used as the motion component of other
2320 commands, in which case any text copied into a buffer is
2323 It is not an error to execute the
2325 command when the cursor is on the first character in the line.
2328 The current line plus
2331 The first nonblank character in the line.
2337 @deftypefn Command {[count]} {a}
2339 Enter input mode, appending the text after the cursor.
2341 @LI{count}is specified, the text input is repeatedly input
2342 @LI{count - 1}more times.
2345 Set to the last line upon which characters were entered.
2347 Set to the last character entered.
2361 @deftypefn Command {[count]} {b}
2365 Move the cursor backward to the beginning of a word by repeating the
2366 following algorithm: if the current position is at the beginning of a word,
2367 move to the first character of the preceding word.
2368 Otherwise, the current position moves to the first character of the word
2369 at the current position.
2370 If no preceding word exists on the current line, move to the first
2371 character of the last word on the first preceding line that contains
2376 command may be used as the motion component of other
2378 commands, in which case any text copied into a buffer is
2382 Set to the line containing the word selected.
2384 Set to the first character of the word selected.
2390 @deftypefn Command {[buffer] [count]} {c} {motion}
2392 Change the region of text specified by the
2395 If only part of a single line is affected, then the last character
2396 being changed is marked with a
2398 Otherwise, the region of text is deleted, and input mode is entered.
2401 Set to the last line upon which characters were entered.
2403 Set to the last character entered.
2417 @deftypefn Command {[buffer] [count]} {d} {motion}
2419 Delete the region of text specified by the
2424 Set to the line where the region starts.
2426 Set to the first character in the line after the last character in the
2428 If no such character exists, set to the last character before the region.
2434 @deftypefn Command {[count]} {e}
2437 @LI{count}end-of-words.
2438 Move the cursor forward to the end of a word by repeating the following
2439 algorithm: if the current position is the end of a word,
2440 move to the last character of the following word.
2441 Otherwise, move to the last character of the word at the current position.
2442 If no succeeding word exists on the current line, move to the last character
2443 of the first word on the next following line that contains a word.
2447 command may be used as the motion component of other
2449 commands, in which case any text copied into a buffer is
2453 Set to the line containing the word selected.
2455 Set to the last character of the word selected.
2461 @deftypefn Command {[count]} {f} {<character>}
2464 @LI{count}times, through the rest of the current line for
2469 command may be used as the motion component of other
2471 commands, in which case any text copied into a buffer is
2477 Set to the searched-for character.
2483 @deftypefn Command {[count]} {i}
2485 Enter input mode, inserting the text before the cursor.
2487 @LI{count}is specified, the text input is repeatedly input
2488 @LI{count - 1}more times.
2491 Set to the last line upon which characters were entered.
2493 Set to the last character entered.
2507 @deftypefn Command {} {m} {<character>}
2509 Save the current context (line and column) as
2511 The exact position is referred to by
2513 The line is referred to by
2517 @LI{<character>}was restricted to lower-case letters.
2519 permits the use of any character.
2530 @deftypefn Command {[count]} {o}
2532 Enter input mode, appending text in a new line under the current line.
2534 @LI{count}is specified, the text input is repeatedly input
2535 @LI{count - 1}more times.
2538 @LI{count}specified to the
2540 command was ignored.
2543 Set to the last line upon which characters were entered.
2545 Set to the last character entered.
2559 @deftypefn Command {[buffer]} {p}
2561 Append text from a buffer.
2562 Text from the buffer (the unnamed buffer by default) is appended
2563 after the current column or, if the buffer is line oriented,
2564 after the current line.
2567 Set to the first line appended, if the buffer is line oriented,
2568 otherwise unchanged.
2570 Set to the first nonblank character of the appended text if the buffer
2571 is line oriented, otherwise, the last character of the appended text.
2577 @deftypefn Command {[count]} {r} {<character>}
2581 @LI{count}characters in the line are replaced with
2583 Replacing characters with
2584 @LI{<newline>}characters results in creating new, empty lines into the file.
2589 the command is cancelled.
2592 Unchanged unless the replacement character is a
2594 in which case it is set to the current line plus
2597 Set to the last character replaced,
2598 unless the replacement character is a
2600 in which case the cursor is in column 1 of the last line inserted.
2606 @deftypefn Command {[buffer] [count]} {s}
2609 @LI{count}characters in the current line starting with the current character.
2612 Set to the last line upon which characters were entered.
2614 Set to the last character entered.
2628 @deftypefn Command {[count]} {t} {<character>}
2631 @LI{count}times, through the current line for the character immediately
2637 command may be used as the motion component of other
2639 commands, in which case any text copied into a buffer is
2645 Set to the character
2647 the searched-for character.
2653 @deftypefn Command {} {u}
2655 Undo the last change made to the file.
2658 command alternates between these two states, and is its own inverse.
2659 When used after an insert that inserted text on more than one line,
2660 the lines are saved in the numeric buffers.
2664 command, when used immediately after the
2666 command, causes the change log to be rolled forward or backward,
2667 depending on the action of the
2672 Set to the position of the first line changed, if the reversal affects
2673 only one line or represents an addition or change; otherwise, the line
2674 preceding the deleted text.
2676 Set to the cursor position before the change was made.
2682 @deftypefn Command {[count]} {w}
2686 Move the cursor forward to the beginning of a word by repeating the
2687 following algorithm: if the current position is at the
2688 beginning of a word, move to the first character of the next word.
2689 If no subsequent word exists on the current line, move to the first
2690 character of the first word on the first following line that contains
2695 command may be used as the motion component of other
2697 commands, in which case any text copied into a buffer is
2701 Set to the line containing the word selected.
2703 Set to the first character of the word selected.
2709 @deftypefn Command {[buffer] [count]} {x}
2712 @LI{count}characters.
2713 The deletion is at the current character position.
2714 If the number of characters to be deleted is greater than or equal to
2715 the number of characters to the end of the line, all of the characters
2716 from the current cursor position to the end of the line are deleted.
2721 Unchanged unless the last character in the line is deleted and the cursor
2722 is not already on the first character in the line, in which case it is
2723 set to the previous character.
2729 @deftypefn Command {[buffer] [count]} y {motion}
2733 the text region specified by the
2739 Unchanged, unless the region covers more than a single line,
2740 in which case it is set to the line where the region starts.
2742 Unchanged, unless the region covers more than a single line,
2743 in which case it is set to the character were the region starts.
2749 @deftypefn Command {[count1]} {z} {[count2] type}
2751 Redraw the screen with a window
2752 @LI{count2}lines long, with line
2753 @LI{count1}placed as specified by the
2756 @LI{count1}is not specified, it defaults to the current line.
2758 @LI{count2}is not specified, it defaults to the current window size.
2761 @LI{type}characters may be used:
2765 @LI{count1}is specified, place the line
2766 @LI{count1}at the top of the screen.
2767 Otherwise, display the screen after the current screen, similarly to the
2770 @item <carriage-return>
2772 @LI{count1}at the top of the screen.
2775 @LI{count1}in the center of the screen.
2778 @LI{count1}at the bottom of the screen.
2781 @LI{count1}is specified, place the line that is at the top of the screen
2783 @LI{count1}is at the bottom of the screen, at the bottom of the screen,
2784 i.e. display the screen before the screen before
2786 Otherwise, display the screen before the current screen, similarly to the
2794 @LI{count1}is not specified and the
2795 @LI{type}character was either
2799 in which case it is set to the line before the first line on the
2800 previous screen or the line after the last line on the previous
2801 screen, respectively.
2803 Set to the first nonblank character in the line.
2809 @deftypefn Command {[count]} @{
2812 @LI{count}paragraphs.
2816 command is an absolute movement.
2819 command may be used as the motion component of other
2821 commands, in which case any text copied into a buffer is
2822 character oriented, unless the starting character is the first
2823 character on its line, in which case it is line oriented.
2826 Set to the line containing the beginning of the previous paragraph.
2828 Set to the first nonblank character in the line.
2836 @deftypefn Command {[count]} {|}
2840 position on the current line.
2844 command may be used as the motion component of other
2846 commands, in which case any text copied into a buffer is
2848 It is an error to use the
2850 command as a motion component and for the cursor not to move.
2855 Set to the character occupying the column position identified by
2857 if the position exists in the line.
2858 If the column length of the current line is less than
2860 the cursor is moved to the last character in the line.
2866 @deftypefn Command {[count]} @}
2869 @LI{count}paragraphs.
2873 command is an absolute movement.
2876 command may be used as the motion component of other
2878 commands, in which case any text copied into a buffer is
2879 character oriented, unless the starting character is at or
2880 before any nonblank characters in its line,
2881 in which case it is line oriented.
2884 Set to the line containing the beginning of the next paragraph.
2886 Set to the first nonblank character in the line.
2894 @deftypefn Command {[count]} {~}
2896 Reverse the case of the next
2897 @LI{count}character(s).
2898 This is the historic semantic for the
2900 command and it is only in effect if the
2904 Lowercase alphabetic characters are changed to uppercase,
2905 and uppercase characters are changed to lowercase.
2906 No other characters are affected.
2910 command did not take an associated count, nor did it move past the
2911 end of the current line.
2912 As it had no associated motion it was difficult to change the case
2913 of large blocks of text.
2916 if the cursor is on the last character of a line, and there are
2917 more lines in the file, the cursor moves to the next line.
2919 It is not an error to specify a count larger than the number of
2920 characters between the cursor and the end of the file.
2923 Set to the line of the character after
2924 @LI{count}characters, or, end of file.
2926 Set to the character after
2927 @LI{count}characters, or, end-of-file.
2935 @deftypefn Command {[count]} {~} {motion}
2937 Reverse the case of the characters in a text region specified by the
2940 Only in effect if the
2944 Lowercase characters are changed to uppercase,
2945 and uppercase characters are changed to lowercase.
2946 No other characters are affected.
2949 Set to the line of the character after the last character in the region.
2951 Set to the character after the last character in the region.
2959 @deftypefn Command {} {<interrupt>}
2961 Interrupt the current operation.
2962 Many of the potentially long-running
2964 commands may be interrupted using the terminal interrupt character.
2965 These operations include searches, file reading and writing, filter
2966 operations and map character expansion.
2967 Interrupts are also enabled when running commands outside of
2971 @LI{<interrupt>}character is used to interrupt while entering an
2973 command, the command is aborted, the cursor returns to its previous
2976 remains in command mode.
2979 @LI{<interrupt>}character is used to interrupt any
2980 operation, any changes made before the interrupt are left in place.
2983 Dependent on the operation being interrupted.
2985 Dependent on the operation being interrupted.
2990 @chapter Vi Text Input Commands
2992 The following section describes the commands available in the text
2999 implementations only permitted the characters inserted on the current
3001 In addition, only the
3002 @LI{<control-D>}erase character and the
3006 erase strings could erase autoindent characters.
3007 (Autoindent characters include both the characters inserted automatically
3008 at the beginning of an input line as well as characters inserted using the
3009 @LI{<control-T>}command.)
3010 This implementation permits erasure to continue past the beginning
3011 of the current line, and back to where text input mode was entered.
3012 In addition, autoindent characters may be erased using the standard
3014 For the line and word erase characters, reaching the autoindent
3017 boundary, denoting the end of the current word or line erase.
3018 Repeating the word or line erase key will erase the autoindent characters.
3024 @LI{<control-W>}as character and word erase characters, respectively, regardless of
3025 the current terminal settings.
3026 This implementation accepts, in addition to these two characters,
3027 the current terminal characters for those operations.
3029 @deftypefn Input {} {<nul>}
3031 If the first character of the input is a
3033 the previous input is replayed, as if just entered.
3036 @deftypefn Input {} {<control-D>}
3038 If the previous character on the line was an autoindent character,
3039 erase characters to move the cursor back to the column immediately
3040 after the previous (1-based) column which is a multiple of the
3043 This may result in any number of
3045 @LI{<space>}characters preceding the cursor being changed.
3049 option is set and the user is entering the first character in the line,
3050 @LI{<control-D>}is ignored.
3051 Otherwise, a literal
3052 @LI{<control-D>}character is entered.
3054 @cindex ^<control-D>
3055 @deftypefn Input {} {^<control-D>}
3057 If the previous character on the line was an autoindent character,
3058 erase all of the autoindent characters on the line.
3059 In addition, the autoindent level is reset to 0.
3061 @cindex 0<control-D>
3062 @deftypefn Input {} {0<control-D>}
3064 If the previous character on the line was an autoindent character,
3065 erase all of the autoindent characters on the line.
3066 The autoindent level is not altered.
3069 @deftypefn Input {} {<control-T>}
3073 @LI{<space>}characters to move the cursor forward to the column immediately
3074 after the next (1-based) column which is a multiple of the
3077 This may result in any number of
3079 @LI{<space>}characters preceding the cursor being changed.
3084 @LI{<control-T>}command to be used unless the cursor was at the first column of a new
3085 line or it was preceded only by autoindent characters.
3087 permits it to be used at any time during insert mode.
3090 @deftypefn Input {} {<erase>}
3093 @deftypefnx Input {} {<control-H>}
3094 Erase the last character.
3096 @cindex "<literal-next>"
3097 @deftypefn Input {} {<literal-next>}
3099 Quote the next character.
3100 The next character will not be mapped (see the
3102 command for more information)
3103 or interpreted specially.
3106 character will be displayed immediately as a placeholder,
3107 but will be replaced by the next character.
3110 @deftypefn Input {} {<escape>}
3112 If on the colon command line, and the
3114 edit option is set, behave as described for that option.
3115 Otherwise, if on the colon command line,
3116 execute the command.
3117 Otherwise, if not on the colon command line,
3118 resolve all text input into the file, and return to command mode.
3120 @cindex "<line erase>"
3121 @deftypefn Input {} {<line erase>}
3123 Erase the current line.
3125 @cindex "<control-W>"
3126 @deftypefn Input {} {<control-W>}
3128 @cindex "<word erase>"
3129 @deftypefnx Input {} {<word erase>}
3130 Erase the last word.
3131 The definition of word is dependent on the
3137 @cindex "<control-X>"
3138 @deftypefn Input {} {<control-X>[0-9A-Fa-f]+}
3140 Insert a character with the specified hexadecimal value into the text.
3141 The value is delimited by any non-hexadecimal character or the input
3142 of the maximum number of characters that can be translated into a single
3146 @deftypefn Input {} {<interrupt>}
3148 Interrupt text input mode, returning to command mode.
3150 @LI{<interrupt>}character is used to interrupt inserting text into the file,
3152 @LI{<escape>}character was used; all text input up to the interruption is
3153 resolved into the file.