PC Logo Wiki
Advertisement

As you type, your commands are written in the Listener Window, no matter what its size. The Listener Window wraps the words as you type when they reach the edge of the window, but to Logo a command line is not complete until you press the ENTER key. When you press the ENTER key, Logo evaluates what you have typed and tries to carry out your commands. If your commands cause any text to appear, it appears in the Listener Window. Any Logo messages are displayed in the Listener Window.

The Listener Window has been designed to be intuitive to use--it "listens" for your commands and executes them as soon as you press ENTER. The Listener Window also includes several features, such as editing and recalling that make it a powerful as well as easy-to-use Logo element.

Editing in the Listener Window

If you want to change commands as you type them in the Listener Window, you can do so by utilizing special keys that allow you to change and adjust your commands prior to pressing ENTER.

The following are the line editor keys:

Backspace deletes character to the left of the cursor
Delete deletes character at cursor location
Left and Right cursor moves one character in the direction of the arrow
Home cursor moves to the beginning of the line
End cursor moves to the end of the line
Insert toggles between insert mode (cursor is small blinking underscore) and overwrite mode (cursor is large blinking rectangle)

Recalling Previous Commands

Rather than retyping, you can recall previous command lines that appear in the Listener Window even after you press ENTER. To do so, use the mouse or one of the keys described below to position the cursor somewhere in the line you want to recall.

Up and Down Moves the cursor up or down one line.
Page Up and Page Down Moves the cursor up or down one page.
Ctrl+Page Up Scrolls one page up.
Ctrl+Page Down Scrolls one page down.
Ctrl+Home Moves the cursor to the first line of the window.
Ctrl+End Moves the cursor to the last line of the window.

When you place the cursor anywhere in a line and press ENTER the line is copied to end of the text in the Listener Window and then executed. If you prefer you can have all the lines after the line you edit erased when you press ENTER by disabling the option Copy input lines to end of text in the dialog which appears when you choose the menu item Options/Environment....

Combining the recall capability with the line editing capability makes it simple to correct a mistake in Logo and issue the command again without retyping it. When you type a line of Logo commands and see an aspect that you want to change, move the cursor within the line of commands again. Use the line editor keys to make the change and then press ENTER to execute the commands as you have amended them.

The Listener Window retains approximately 100 lines of Logo commands giving you a long history of your Logo commands that you can edit. In addition to editing commands and executing them again, you can copy and paste them into an edit window to turn them into a procedure or save them as a file.

Advertisement