home *** CD-ROM | disk | FTP | other *** search
/ The Datafile PD-CD 4 / DATAFILE_PDCD4.iso / unix / riscbsd / datafile / usd / 15_vi / vi_chars_t < prev    next >
Encoding:
Text File  |  1996-10-12  |  31.2 KB  |  925 lines

  1.  
  2.  
  3.  
  4.  
  5.  
  6.  
  7. Appendix: character functions
  8.  
  9.      This  appendix  gives the uses the editor makes of each
  10. character.  The characters are presented in their  order  in
  11. the  ASCII  character  set:   Control characters come first,
  12. then most special characters, then  the  digits,  upper  and
  13. then lower case characters.
  14.  
  15.      For  each  character we tell a meaning it has as a com-
  16. mand and any meaning it has during an  insert.   If  it  has
  17. only  meaning  as  a  command,  then only this is discussed.
  18. Section numbers in parentheses indicate where the  character
  19. is  discussed; a `f' after the section number means that the
  20. character is mentioned in a footnote.
  21.  
  22. ^@             Not a command character.   If  typed  as  the
  23.                first   character   of  an  insertion  it  is
  24.                replaced with the last text inserted, and the
  25.                insert  terminates.   Only 128 characters are
  26.                saved from the last insert; if  more  charac-
  27.                ters  were  inserted  the  mechanism  is  not
  28.                available.  A ^@ cannot be part of  the  file
  29.                due to the editor implementation (7.5f).
  30.  
  31. ^A             Unused.
  32.  
  33. ^B             Backward  window.   A count specifies repeti-
  34.                tion.  Two lines of continuity  are  kept  if
  35.                possible (2.1, 6.1, 7.2).
  36.  
  37. ^C             Unused.
  38.  
  39. ^D             As  a  command, scrolls down a half-window of
  40.                text.  A count gives the number of  (logical)
  41.                lines to scroll, and is remembered for future
  42.                ^D and ^U commands  (2.1,  7.2).   During  an
  43.                insert,  backtabs over autoindent white space
  44.                at the beginning of a line (6.6,  7.5);  this
  45.                white space cannot be backspaced over.
  46.  
  47. ^E             Exposes  one  more  line  below  the  current
  48.                screen in the file, leaving the cursor  where
  49.                it is if possible.  (Version 3 only.)
  50.  
  51. ^F             Forward  window.   A  count specifies repeti-
  52.                tion.  Two lines of continuity  are  kept  if
  53.                possible (2.1, 6.1, 7.2).
  54.  
  55. ^G             Equivalent  to  :fCR,  printing  the  current
  56.                file, whether it has been modified, the  cur-
  57.                rent  line  number and the number of lines in
  58.                the file,  and  the  percentage  of  the  way
  59.                through the file that you are.
  60.  
  61.  
  62.  
  63.  
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70.                              -2-
  71.  
  72.  
  73. ^H (BS)        Same  as  left  arrow.   (See  h).  During an
  74.                insert, eliminates the last input  character,
  75.                backing  over  it  but  not  erasing  it;  it
  76.                remains so you can see what you typed if  you
  77.                wish  to type something only slightly differ-
  78.                ent (3.1, 7.5).
  79.  
  80. ^I (TAB)       Not a command character.   When  inserted  it
  81.                prints  as  some  number of spaces.  When the
  82.                cursor is at a tab character it rests at  the
  83.                last  of  the spaces which represent the tab.
  84.                The spacing of tabstops is controlled by  the
  85.                tabstop option (4.1, 6.6).
  86.  
  87. ^J (LF)        Same as down arrow (see j).
  88.  
  89. ^K             Unused.
  90.  
  91. ^L             The ASCII formfeed character, this causes the
  92.                screen to be cleared and  redrawn.   This  is
  93.                useful after a transmission error, if charac-
  94.                ters typed by a program other than the editor
  95.                scramble  the  screen,  or  after  output  is
  96.                stopped by an interrupt (5.4, 7.2f).
  97.  
  98. ^M (CR)        A carriage return advances to the next  line,
  99.                at  the first non-white position in the line.
  100.                Given a count, it advances  that  many  lines
  101.                (2.3).   During  an  insert,  a CR causes the
  102.                insert to continue onto another line (3.1).
  103.  
  104. ^N             Same as down arrow (see j).
  105.  
  106. ^O             Unused.
  107.  
  108. ^P             Same as up arrow (see k).
  109.  
  110. ^Q             Not a command character.  In input  mode,  ^Q
  111.                quotes  the  next  character, the same as ^V,
  112.                except that some teletype  drivers  will  eat
  113.                the ^Q so that the editor never sees it.
  114.  
  115. ^R             Redraws the current screen, eliminating logi-
  116.                cal lines not corresponding to physical lines
  117.                (lines  with  only  a  single  @ character on
  118.                them).  On hardcopy terminals in  open  mode,
  119.                retypes the current line (5.4, 7.2, 7.8).
  120.  
  121. ^S             Unused.  Some teletype drivers use ^S to sus-
  122.                pend output until pressed.^Qis
  123.  
  124. ^T             Not a command character.  During  an  insert,
  125.                with  autoindent  set and at the beginning of
  126.                the line, inserts shiftwidth white space.
  127.  
  128.  
  129.  
  130.  
  131.  
  132.  
  133.  
  134.  
  135.  
  136.                              -3-
  137.  
  138.  
  139. ^U             Scrolls the screen  up,  inverting  ^D  which
  140.                scrolls down.  Counts work as they do for ^D,
  141.                and the previous scroll amount is  common  to
  142.                both.   On  a  dumb  terminal,  ^U will often
  143.                necessitate clearing and redrawing the screen
  144.                further back in the file (2.1, 7.2).
  145.  
  146. ^V             Not  a  command  character.   In  input mode,
  147.                quotes the next character so that it is  pos-
  148.                sible  to  insert  non-printing  and  special
  149.                characters into the file (4.2, 7.5).
  150.  
  151. ^W             Not a command character.  During  an  insert,
  152.                backs  up  as  b  would  in command mode; the
  153.                deleted characters remain on the display (see
  154.                ^H) (7.5).
  155.  
  156. ^X             Unused.
  157.  
  158. ^Y             Exposes  one  more  line  above  the  current
  159.                screen, leaving the cursor  where  it  is  if
  160.                possible.   (No  mnemonic value for this key;
  161.                however, it is next to ^U which scrolls up  a
  162.                bunch.)  (Version 3 only.)
  163.  
  164. ^Z             If  supported  by  the Unix system, stops the
  165.                editor, exiting to the top level shell.  Same
  166.                as :stopCR.  Otherwise, unused.
  167.  
  168. ^[ (ESC)       Cancels a partially formed command, such as a
  169.                z when no following character  has  yet  been
  170.                given;  terminates  inputs  on  the last line
  171.                (read by commands such as : /  and  ?);  ends
  172.                insertions  of  new text into the buffer.  If
  173.                an ESC is given  when  quiescent  in  command
  174.                state,  the  editor rings the bell or flashes
  175.                the screen.  You can  thus  hit  ESC  if  you
  176.                don't  know what is happening till the editor
  177.                rings the bell.  If you don't know if you are
  178.                in  insert  mode  you can type ESCa, and then
  179.                material to be input; the  material  will  be
  180.                inserted correctly whether or not you were in
  181.                insert mode when you started (1.5, 3.1, 7.5).
  182.  
  183. ^\             Unused.
  184.  
  185. ^]             Searches for the word which is after the cur-
  186.                sor as a tag.  Equivalent to typing :ta, this
  187.                word, and then a CR.  Mnemonically, this com-
  188.                mand is ``go right to'' (7.3).
  189.  
  190. ^^             Equivalent to :e #CR, returning to the previ-
  191.                ous  position  in  the  last  edited file, or
  192.                editing a file which you specified if you got
  193.  
  194.  
  195.  
  196.  
  197.  
  198.  
  199.  
  200.  
  201.  
  202.                              -4-
  203.  
  204.  
  205.                a `No write since last change diagnostic' and
  206.                do not want to have to  type  the  file  name
  207.                again  (7.3).  (You have to do a :w before ^^
  208.                will work in this case.  If you do  not  wish
  209.                to  write  the  file  you  should  do :e! #CR
  210.                instead.)
  211.  
  212. ^_             Unused.  Reserved as  the  command  character
  213.                for the Tektronix 4025 and 4027 terminal.
  214.  
  215. SPACE          Same as right arrow (see l).
  216.  
  217. !              An  operator,  which processes lines from the
  218.                buffer with reformatting commands.  Follow  !
  219.                with the object to be processed, and then the
  220.                command name terminated by  CR.   Doubling  !
  221.                and  preceding  it  by  a  count causes count
  222.                lines to be filtered; otherwise the count  is
  223.                passed  on  to  the object after the !.  Thus
  224.                2!}fmtCR reformats the next two paragraphs by
  225.                running them through the program fmt.  If you
  226.                are  working on LISP, the command !%grindCR,*
  227.                given at the beginning of  a  function,  will
  228.                run the text of the function through the LISP
  229.                grinder (6.7, 7.3).  To read a  file  or  the
  230.                output  of  a  command into the buffer use :r
  231.                (7.3).  To simply execute a  command  use  :!
  232.                (7.3).
  233.  
  234. "              Precedes a named buffer specification.  There
  235.                are named buffers 1-9 used for saving deleted
  236.                text and named buffers a-z into which you can
  237.                place text (4.3, 6.3)
  238.  
  239. #              The macro character which, when followed by a
  240.                number, will substitute for a function key on
  241.                terminals without function  keys  (6.9).   In
  242.                input  mode, if this is your erase character,
  243.                it will delete the last character  you  typed
  244.                in  input mode, and must be preceded with a \
  245.                to insert it, since it  normally  backs  over
  246.                the last input character you gave.
  247.  
  248. $              Moves to the end of the current line.  If you
  249.                :se listCR, then the end of each line will be
  250.                shown  by  printing  a $ after the end of the
  251.                displayed text in the line.  Given  a  count,
  252.                advances  to  the  count'th  following end of
  253.                line; thus 2$ advances to the end of the fol-
  254.                lowing line.
  255.  
  256. -----------
  257. *Both fmt and grind are Berkeley programs and  may
  258. not be present at all installations.
  259.  
  260.  
  261.  
  262.  
  263.  
  264.  
  265.  
  266.  
  267.  
  268.                              -5-
  269.  
  270.  
  271. %              Moves  to  the parenthesis or brace { } which
  272.                balances the parenthesis or brace at the cur-
  273.                rent cursor position.
  274.  
  275. &              A  synonym for :&CR, by analogy with the ex &
  276.                command.
  277.  
  278. '              When followed by a ' returns to the  previous
  279.                context at the beginning of a line.  The pre-
  280.                vious context is  set  whenever  the  current
  281.                line  is  moved  in a non-relative way.  When
  282.                followed by a letter a-z, returns to the line
  283.                which  was  marked  with this letter with a m
  284.                command, at the first non-white character  in
  285.                the  line.  (2.2,  5.3).   When  used with an
  286.                operator such as d, the operation takes place
  287.                over complete lines; if you use `, the opera-
  288.                tion takes place from the exact marked  place
  289.                to  the  current  cursor  position within the
  290.                line.
  291.  
  292. (              Retreats to the beginning of a  sentence,  or
  293.                to  the  beginning  of a LISP s-expression if
  294.                the lisp option is set.  A sentence ends at a
  295.                .  ! or ? which is followed by either the end
  296.                of a line or by two spaces.   Any  number  of
  297.                closing  )  ]  "  and ' characters may appear
  298.                after the . ! or ?, and before the spaces  or
  299.                end  of  line.  Sentences also begin at para-
  300.                graph and section boundaries (see  {  and  [[
  301.                below).  A count advances that many sentences
  302.                (4.2, 6.8).
  303.  
  304. )              Advances to the beginning of a  sentence.   A
  305.                count  repeats  the  effect.  See ( above for
  306.                the definition of a sentence (4.2, 6.8).
  307.  
  308. *              Unused.
  309.  
  310. +              Same as CR when used as a command.
  311.  
  312. ,              Reverse of the last f F t or T command, look-
  313.                ing the other way in the current line.  Espe-
  314.                cially useful after hitting too many ;  char-
  315.                acters.  A count repeats the search.
  316.  
  317. -              Retreats  to  the  previous line at the first
  318.                non-white character.  This is the inverse  of
  319.                + and RETURN.  If the line moved to is not on
  320.                the  screen,  the  screen  is  scrolled,   or
  321.                cleared  and redrawn if this is not possible.
  322.                If a  large  amount  of  scrolling  would  be
  323.                required  the  screen  is  also  cleared  and
  324.                redrawn, with the current line at the  center
  325.  
  326.  
  327.  
  328.  
  329.  
  330.  
  331.  
  332.  
  333.  
  334.                              -6-
  335.  
  336.  
  337.                (2.3).
  338.  
  339. .              Repeats  the  last  command which changed the
  340.                buffer.   Especially  useful  when   deleting
  341.                words   or   lines;   you   can  delete  some
  342.                words/lines and then hit . to delete more and
  343.                more  words/lines.   Given a count, it passes
  344.                it on to the command  being  repeated.   Thus
  345.                after  a  2dw,  3.  deletes three words (3.3,
  346.                6.3, 7.2, 7.4).
  347.  
  348. /              Reads a string from  the  last  line  on  the
  349.                screen, and scans forward for the next occur-
  350.                rence of this string.  The normal input edit-
  351.                ing sequences may be used during the input on
  352.                the bottom line; an returns to command  state
  353.                without  ever  searching.   The search begins
  354.                when you hit CR to terminate the pattern; the
  355.                cursor  moves  to  the  beginning of the last
  356.                line  to  indicate  that  the  search  is  in
  357.                progress;  the  search may then be terminated
  358.                with a DEL or RUB, or by backspacing when  at
  359.                the  beginning  of the bottom line, returning
  360.                the cursor to its initial position.  Searches
  361.                normally  wrap  end-around  to  find a string
  362.                anywhere in the buffer.
  363.  
  364.                When  used  with  an  operator  the  enclosed
  365.                region  is  normally affected.  By mentioning
  366.                an offset from the line matched by  the  pat-
  367.                tern   you   can  force  whole  lines  to  be
  368.                affected.  To do this give a pattern  with  a
  369.                closing  a closing / and then an offset +n or
  370.                -n.
  371.  
  372.                To include the  character  /  in  the  search
  373.                string,  you  must escape it with a preceding
  374.                \.  A ^  at  the  beginning  of  the  pattern
  375.                forces the match to occur at the beginning of
  376.                a line only; this speeds the search.  A $  at
  377.                the  end  of  the pattern forces the match to
  378.                occur at  the  end  of  a  line  only.   More
  379.                extended  pattern  matching is available, see
  380.                section 7.4; unless you set nomagic  in  your
  381.                .exrc file you will have to preceed the char-
  382.                acters . [ * and ~ in the search pattern with
  383.                a  \ to get them to work as you would naively
  384.                expect (1.5, 2,2, 6.1, 7.2, 7.4).
  385.  
  386. 0              Moves to the first character on  the  current
  387.                line.   Also  used, in forming numbers, after
  388.                an initial 1-9.
  389.  
  390.  
  391.  
  392.  
  393.  
  394.  
  395.  
  396.  
  397.  
  398.  
  399.  
  400.                              -7-
  401.  
  402.  
  403. 1-9            Used to form numeric  arguments  to  commands
  404.                (2.3, 7.2).
  405.  
  406. :              A  prefix  to  a set of commands for file and
  407.                option manipulation and escapes to  the  sys-
  408.                tem.   Input  is given on the bottom line and
  409.                terminated with an CR, and the  command  then
  410.                executed.   You  can return to where you were
  411.                by hitting DEL or RUB if you hit  :  acciden-
  412.                tally (see primarily 6.2 and 7.3).
  413.  
  414. ;              Repeats  the last single character find which
  415.                used f F t or T.  A count iterates the  basic
  416.                scan (4.1).
  417.  
  418. <              An  operator  which  shifts  lines  left  one
  419.                shiftwidth,  normally  8  spaces.   Like  all
  420.                operators, affects lines when repeated, as in
  421.                <<.  Counts are passed through to  the  basic
  422.                object,  thus  3<<  shifts  three lines (6.6,
  423.                7.2).
  424.  
  425. =              Reindents line for LISP, as though they  were
  426.                typed  in with lisp and autoindent set (6.8).
  427.  
  428. >              An operator  which  shifts  lines  right  one
  429.                shiftwidth, normally 8 spaces.  Affects lines
  430.                when repeated as in >>.   Counts  repeat  the
  431.                basic object (6.6, 7.2).
  432.  
  433. ?              Scans  backwards, the opposite of /.  See the
  434.                / description above for details  on  scanning
  435.                (2.2, 6.1, 7.4).
  436.  
  437. @              A  macro  character  (6.9).   If this is your
  438.                kill character, you must escape it with  a  \
  439.                to  type  it in during input mode, as it nor-
  440.                mally backs over the input you have given  on
  441.                the current line (3.1, 3.4, 7.5).
  442.  
  443. A              Appends  at the end of line, a synonym for $a
  444.                (7.2).
  445.  
  446. B              Backs up a word, where words are composed  of
  447.                non-blank  sequences,  placing  the cursor at
  448.                the beginning of the word.  A  count  repeats
  449.                the effect (2.4).
  450.  
  451. C              Changes  the  rest of the text on the current
  452.                line; a synonym for c$.
  453.  
  454. D              Deletes the rest of the text on  the  current
  455.                line; a synonym for d$.
  456.  
  457.  
  458.  
  459.  
  460.  
  461.  
  462.  
  463.  
  464.  
  465.  
  466.                              -8-
  467.  
  468.  
  469. E              Moves  forward  to the end of a word, defined
  470.                as blanks and non-blanks, like B  and  W.   A
  471.                count repeats the effect.
  472.  
  473. F              Finds a single following character, backwards
  474.                in the current line.  A  count  repeats  this
  475.                search that many times (4.1).
  476.  
  477. G              Goes  to  the  line number given as preceding
  478.                argument, or the end of the file if  no  pre-
  479.                ceding count is given.  The screen is redrawn
  480.                with the new current line in  the  center  if
  481.                necessary (7.2).
  482.  
  483. H              Home arrow.  Homes the cursor to the top line
  484.                on the screen.  If a count is given, then the
  485.                cursor  is  moved to the count'th line on the
  486.                screen.  In any case the cursor is  moved  to
  487.                the  first  non-white  character on the line.
  488.                If used as the target of  an  operator,  full
  489.                lines are affected (2.3, 3.2).
  490.  
  491. I              Inserts at the beginning of a line; a synonym
  492.                for ^i.
  493.  
  494. J              Joins together lines,  supplying  appropriate
  495.                white  space:  one  space  between words, two
  496.                spaces after a ., and no spaces at all if the
  497.                first  character  of the joined on line is ).
  498.                A count causes that many lines to  be  joined
  499.                rather than the default two (6.5, 7.1f).
  500.  
  501. K              Unused.
  502.  
  503. L              Moves the cursor to the first non-white char-
  504.                acter of the last line on the screen.  With a
  505.                count, to the first non-white of the count'th
  506.                line from the bottom.  Operators affect whole
  507.                lines when used with L (2.3).
  508.  
  509. M              Moves  the  cursor  to the middle line on the
  510.                screen, at the first  non-white  position  on
  511.                the line (2.3).
  512.  
  513. N              Scans  for the next match of the last pattern
  514.                given to / or ?, but in  the  reverse  direc-
  515.                tion; this is the reverse of n.
  516.  
  517. O              Opens  a  new line above the current line and
  518.                inputs text there up to an ESC.  A count  can
  519.                be used on dumb terminals to specify a number
  520.                of lines to  be  opened;  this  is  generally
  521.                obsolete, as the slowopen option works better
  522.                (3.1).
  523.  
  524.  
  525.  
  526.  
  527.  
  528.  
  529.  
  530.  
  531.  
  532.                              -9-
  533.  
  534.  
  535. P              Puts the last deleted text back  before/above
  536.                the  cursor.   The  text  goes  back as whole
  537.                lines above the cursor if it was  deleted  as
  538.                whole  lines.  Otherwise the text is inserted
  539.                between the characters before and at the cur-
  540.                sor.  May be preceded by a named buffer spec-
  541.                ification "x to retrieve the contents of  the
  542.                buffer; buffers 1-9 contain deleted material,
  543.                buffers a-z are  available  for  general  use
  544.                (6.3).
  545.  
  546. Q              Quits  from  vi  to ex command mode.  In this
  547.                mode, whole lines form commands, ending  with
  548.                a  RETURN.   You can give all the : commands;
  549.                the editor supplies the : as a prompt  (7.7).
  550.  
  551. R              Replaces  characters on the screen with char-
  552.                acters you type  (overlay  fashion).   Termi-
  553.                nates with an ESC.
  554.  
  555. S              Changes  whole  lines,  a  synonym for cc.  A
  556.                count substitutes for that many  lines.   The
  557.                lines  are  saved in the numeric buffers, and
  558.                erased on the screen before the  substitution
  559.                begins.
  560.  
  561. T              Takes  a  single following character, locates
  562.                the character before the cursor in  the  cur-
  563.                rent  line,  and places the cursor just after
  564.                that character.  A count repeats the  effect.
  565.                Most useful with operators such as d (4.1).
  566.  
  567. U              Restores the current line to its state before
  568.                you started changing it (3.5).
  569.  
  570. V              Unused.
  571.  
  572. W              Moves forward to the beginning of a  word  in
  573.                the  current line, where words are defined as
  574.                sequences of blank/non-blank  characters.   A
  575.                count repeats the effect (2.4).
  576.  
  577. X              Deletes  the  character before the cursor.  A
  578.                count repeats the effect, but only characters
  579.                on the current line are deleted.
  580.  
  581. Y              Yanks  a  copy  of  the current line into the
  582.                unnamed buffer, to be put back by a  later  p
  583.                or  P; a very useful synonym for yy.  A count
  584.                yanks that many lines.  May be preceded by  a
  585.                buffer  name  to  put  lines  in  that buffer
  586.                (7.4).
  587.  
  588.  
  589.  
  590.  
  591.  
  592.  
  593.  
  594.  
  595.  
  596.  
  597.  
  598.                             -10-
  599.  
  600.  
  601. ZZ             Exits the editor.  (Same as  :xCR.)   If  any
  602.                changes have been made, the buffer is written
  603.                out to the current  file.   Then  the  editor
  604.                quits.
  605.  
  606. [[             Backs up to the previous section boundary.  A
  607.                section begins at each macro in the  sections
  608.                option, normally a `.NH' or `.SH' and also at
  609.                lines which which start with a  formfeed  ^L.
  610.                Lines  beginning  with  {  also stop [[; this
  611.                makes it  useful  for  looking  backwards,  a
  612.                function  at  a  time, in C programs.  If the
  613.                option lisp is set, stops at each  (  at  the
  614.                beginning  of  a line, and is thus useful for
  615.                moving  backwards  at  the  top  level   LISP
  616.                objects. (4.2, 6.1, 6.6, 7.2).
  617.  
  618. \              Unused.
  619.  
  620. ]]             Forward  to  a section boundary, see [[ for a
  621.                definition (4.2, 6.1, 6.6, 7.2).
  622.  
  623. ^              Moves to the first non-white position on  the
  624.                current line (4.4).
  625.  
  626. _              Unused.
  627.  
  628. `              When  followed by a ` returns to the previous
  629.                context.  The previous context is  set  when-
  630.                ever  the  current  line  is  moved in a non-
  631.                relative way.  When followed by a letter a-z,
  632.                returns to the position which was marked with
  633.                this letter with a m command.  When used with
  634.                an  operator  such  as d, the operation takes
  635.                place from the exact marked place to the cur-
  636.                rent  position within the line; if you use ',
  637.                the operation takes place over complete lines
  638.                (2.2, 5.3).
  639.  
  640. a              Appends arbitrary text after the current cur-
  641.                sor position; the insert  can  continue  onto
  642.                multiple  lines  by  using  RETURN within the
  643.                insert.  A count causes the inserted text  to
  644.                be  replicated, but only if the inserted text
  645.                is all on one line.  The insertion terminates
  646.                with an ESC (3.1, 7.2).
  647.  
  648. b              Backs  up  to  the beginning of a word in the
  649.                current  line.   A  word  is  a  sequence  of
  650.                alphanumerics, or a sequence of special char-
  651.                acters.  A count repeats the effect (2.4).
  652.  
  653. c              An  operator  which  changes  the   following
  654.                object, replacing it with the following input
  655.  
  656.  
  657.  
  658.  
  659.  
  660.  
  661.  
  662.  
  663.  
  664.                             -11-
  665.  
  666.  
  667.                text up to an ESC.  If more than  part  of  a
  668.                single  line  is  affected, the text which is
  669.                changed away is saved in  the  numeric  named
  670.                buffers.  If only part of the current line is
  671.                affected,  then  the  last  character  to  be
  672.                changed  away  is  marked  with a $.  A count
  673.                causes that many objects to be affected, thus
  674.                both  3c)  and c3) change the following three
  675.                sentences (7.4).
  676.  
  677. d              An  operator  which  deletes  the   following
  678.                object.   If  more  than  part  of  a line is
  679.                affected, the text is saved  in  the  numeric
  680.                buffers.  A count causes that many objects to
  681.                be affected; thus 3dw  is  the  same  as  d3w
  682.                (3.3, 3.4, 4.1, 7.4).
  683.  
  684. e              Advances to the end of the next word, defined
  685.                as for b and w.  A count repeats  the  effect
  686.                (2.4, 3.1).
  687.  
  688. f              Finds  the first instance of the next charac-
  689.                ter following the cursor on the current line.
  690.                A count repeats the find (4.1).
  691.  
  692. g              Unused.
  693.  
  694.                Arrow keys h, j, k, l, and H.
  695.  
  696. h              Left  arrow.   Moves the cursor one character
  697.                to the left.   Like  the  other  arrow  keys,
  698.                either  h,  the left arrow key, or one of the
  699.                synonyms (^H) has the  same  effect.   On  v2
  700.                editors,  arrow keys on certain kinds of ter-
  701.                minals (those which  send  escape  sequences,
  702.                such as vt52, c100, or hp) cannot be used.  A
  703.                count repeats the effect (3.1, 7.5).
  704.  
  705. i              Inserts text  before  the  cursor,  otherwise
  706.                like a (7.2).
  707.  
  708. j              Down  arrow.   Moves the cursor one line down
  709.                in the same column.  If the position does not
  710.                exist,  vi  comes as close as possible to the
  711.                same column.  Synonyms include ^J  (linefeed)
  712.                and ^N.
  713.  
  714. k              Up  arrow.  Moves the cursor one line up.  ^P
  715.                is a synonym.
  716.  
  717. l              Right arrow.  Moves the cursor one  character
  718.                to the right.  SPACE is a synonym.
  719.  
  720.  
  721.  
  722.  
  723.  
  724.  
  725.  
  726.  
  727.  
  728.  
  729.  
  730.                             -12-
  731.  
  732.  
  733. m              Marks  the  current position of the cursor in
  734.                the mark register which is specified  by  the
  735.                next  character a-z.  Return to this position
  736.                or use with an operator using ` or ' (5.3).
  737.  
  738. n              Repeats the last /  or  ?  scanning  commands
  739.                (2.2).
  740.  
  741. o              Opens  new lines below the current line; oth-
  742.                erwise like O (3.1).
  743.  
  744. p              Puts text after/below the  cursor;  otherwise
  745.                like P (6.3).
  746.  
  747. q              Unused.
  748.  
  749. r              Replaces  the  single character at the cursor
  750.                with a single character you  type.   The  new
  751.                character  may be a RETURN; this is the easi-
  752.                est way to split  lines.   A  count  replaces
  753.                each  of  the following count characters with
  754.                the single character given; see R above which
  755.                is  the  more  usually  useful iteration of r
  756.                (3.2).
  757.  
  758. s              Changes the single character under the cursor
  759.                to the text which follows up to an ESC; given
  760.                a count, that many characters from  the  cur-
  761.                rent line are changed.  The last character to
  762.                be changed is marked with $ as in c (3.2).
  763.  
  764. t              Advances the cursor upto the character before
  765.                the  next  character typed.  Most useful with
  766.                operators such as d and c to delete the char-
  767.                acters  up to a following character.  You can
  768.                use . to delete more if this  doesn't  delete
  769.                enough the first time (4.1).
  770.  
  771. u              Undoes  the  last  change made to the current
  772.                buffer.  If repeated, will alternate  between
  773.                these  two  states,  thus is its own inverse.
  774.                When used after an insert which inserted text
  775.                on more than one line, the lines are saved in
  776.                the numeric named buffers (3.5).
  777.  
  778. v              Unused.
  779.  
  780. w              Advances to the beginning of the  next  word,
  781.                as defined by b (2.4).
  782.  
  783. x              Deletes  the  single character under the cur-
  784.                sor.  With a count deletes deletes that  many
  785.                characters  forward from the cursor position,
  786.                but only on the current line (6.5).
  787.  
  788.  
  789.  
  790.  
  791.  
  792.  
  793.  
  794.  
  795.  
  796.                             -13-
  797.  
  798.  
  799. y              An operator, yanks the following object  into
  800.                the unnamed temporary buffer.  If preceded by
  801.                a named buffer specification, "x, the text is
  802.                placed  in  that  buffer  also.   Text can be
  803.                recovered by a later p or P (7.4).
  804.  
  805. z              Redraws the  screen  with  the  current  line
  806.                placed  as specified by the following charac-
  807.                ter: RETURN specifies the top of the  screen,
  808.                . the center of the screen, and - at the bot-
  809.                tom of the screen.   A  count  may  be  given
  810.                after  the z and before the following charac-
  811.                ter to specify the new screen  size  for  the
  812.                redraw.   A count before the z gives the num-
  813.                ber of the line to place in the center of the
  814.                screen  instead  of the default current line.
  815.                (5.4)
  816.  
  817. {              Retreats to the beginning of the beginning of
  818.                the  preceding paragraph.  A paragraph begins
  819.                at each macro in the paragraphs option,  nor-
  820.                mally  `.IP',  `.LP', `.PP', `.QP' and `.bp'.
  821.                A paragraph also begins  after  a  completely
  822.                empty line, and at each section boundary (see
  823.                [[ above) (4.2, 6.8, 7.6).
  824.  
  825. |              Places the cursor on  the  character  in  the
  826.                column specified by the count (7.1, 7.2).
  827.  
  828. }              Advances  to  the beginning of the next para-
  829.                graph.  See { for the definition of paragraph
  830.                (4.2, 6.8, 7.6).
  831.  
  832. ~              Unused.
  833.  
  834. ^? (DEL)       Interrupts  the  editor, returning it to com-
  835.                mand accepting state (1.5, 7.5)
  836.  
  837.  
  838.  
  839.  
  840.  
  841.  
  842.  
  843.  
  844.  
  845.  
  846.  
  847.  
  848.  
  849.  
  850.  
  851.  
  852.  
  853.  
  854.  
  855.  
  856.  
  857.  
  858.  
  859.  
  860.  
  861.  
  862.                             -14-
  863.  
  864.  
  865.                .
  866.  
  867.  
  868.  
  869.  
  870.  
  871.  
  872.  
  873.  
  874.  
  875.  
  876.  
  877.  
  878.  
  879.  
  880.  
  881.  
  882.  
  883.  
  884.  
  885.  
  886.  
  887.  
  888.  
  889.  
  890.  
  891.  
  892.  
  893.  
  894.  
  895.  
  896.  
  897.  
  898.  
  899.  
  900.  
  901.  
  902.  
  903.  
  904.  
  905.  
  906.  
  907.  
  908.  
  909.  
  910.  
  911.  
  912.  
  913.  
  914.  
  915.  
  916.  
  917.  
  918.  
  919.  
  920.  
  921.  
  922.  
  923.  
  924.  
  925.