Input Line Editing

A-Shell, like AMOS, supports two similar but distinct input modes, known as "line mode", and "image mode". In line mode, the operating system is in charge of the details of keyboard entry, passing an entire line to the application after the user hits the line termination key (typically Enter). In image mode, the application is fully in charge of input, processing each character as it is typed.

In the UNIX world, line mode is typically known as "canonical" (or "cooked") mode, and "image mode" is known as "raw" mode. So much for terminology standardization.

As a technical aside, in actuality all input within A-Shell is in image (or raw) mode, from the operating system’s perspective. A-Shell itself then simulates line mode based on the application context.

Although line mode and image mode are not easy to distinguish from the user’s point of view, the important distinction is that in line mode, you have the ability to recall prior lines of input using Ctrl+R (sometimes mapped to the Page-Up key). This is particularly useful when working at the dot prompt, since it is common to have a typo in a complicated command cause the command to be rejected. Rather than re-typing the entire command line, you can hit Ctrl+R (or the Page-Up key), and then use the line editing keys to correct the mistake. You can also hit Ctrl+T (or Page-Down) to cycle forwards through the last several command lines entered.