Now the natural question arises, how does one know that there aren't blanks hidden in the virtual territory? Here is a command to answer that question.
So now your program should look like this:
#include
<stdio.h>
main()
{
printf("Hello stedi"\n);
}
The next logical question one might ask is this: what happens if you
type a character somewhere out in the middle of the virtual territory
(where the cursor is now)? After all, a line of a program is only
defined by the actual characters that are in it. The answer is quite
simple. The editor fills lines in with blanks where necessary in order
to maintain a completely intuitive connection between the position of
the cursor on the screen and the file being visually represented.
To see this at work, try the following. With the cursor in the virtual territory of line 4 and the Alt-T option on,
#include
<stdio.h>
main()
{
printf("Hello stedi"\n);
}
If you are worried about having extra blanks at the ends of lines, there is a command for stripping them off. (The command also removes unnecessary blanks which occur in the field of a tab.)
This command, which is called `tab trim' is performed as follows:
Command | Action |
Ctrl-<Delete> | deletes the line the cursor is in |
Ctrl-D | deletes everything in the current |
line to the right of the cursor. | |
<Insert> | inserts a line above the cursor. |
Shift-<Insert> | inserts a line below the cursor. |
In both instances of insert, the cursor will be repositioned at the beginning of the new line.
The editor also contains an undo function governed by the <Undo> key. This key recovers certain types of deletions which have been made.