Contents Introduction 3 Getting started 3 Feel free to experiment 4 The document and the display 5 The commands 5 Formatting 9 Mailmerge 12 Summary of commands 14 - 1 - Copyright (C) 1983 by MiCROL. All rights reserved. See cassette copyright notice for further information. Published and printed in England. MiCROL (UK Mail Order) 38 Burleigh Street Cambridge CB1 1DG Subject to statutory limitation MiCROL accepts no liability for loss, loss of profit, or consequential damage arising from the use of THE WORD PROCESSOR or from information contained in this manual. It is the purchaser's responsibility to ensure suitability for purpose. - 2 - Introduction The Word Processor will enable you to write, print and store documents up to about four thousand words long. Like most word processing programs, The Word Processor has two parts. The first part is the text editor, which will take the text you type and place it in the computer's memory, and has a variety of commands for editing the document. The second part is the formatter, which takes the document in memory, reformats it to fit the margins and other formatting options you have chosen, and prints it. The printing can take place either on the printer, or on the screen if you want to see how a document will look without wasting paper. Getting started Use the command LOAD "wp" to load The Word Processor. It will take about thirty seconds to load, and will run automatically. If an 'Out of memory' error message appears you are probably using a 16K Spectrum: The Word Processor will work only on a 48K machine. Remember to turn the tape recorder off after the program has loaded. When this has happened the screen should be blank apart from the words 'Line 0' and 'The Word Processor (C) 1983 MiCROL' at the top of the screen and, just underneath, a single underscore. You now have an empty area to put text into. The top line says you are 'on' line zero, but there is really no line zero: this just means you are at the beginning of the document, which at the moment is empty. The underscore character (_) is the cursor and this always points at the line you are 'on'. To enter text, press ENTER. A flashing L will appear at the bottom of the screen: this is the normal entry cursor. Type 'Mary had a little lamb' and press ENTER. You will see the text appear at the top of the screen, and the line cursor (the _) will move down to point at the new line. Now try typing something longer than thirtytwo characters, which is the width of the screen. Type 'Its fleece as white as snow, And everywhere that Mary went, The lamb was sure to go'. This brings the word-wrap feature into play: words which would be broken at the ends of lines are wrapped round on to the following line. The screen should now show: - 3 - Line 4 add text (ENTER to stop) Mary had a little lamb Its fleece as white as snow, And everywhere that Mary went, The lamb was sure to go The new text has been split into three lines, and the cursor is now on line 4. To stop entering text, press ENTER in response to the L prompt at the bottom of the screen, without typing in any text. This will change the second line of the display to 'ENTER=type arrows=move d=delete' which is always shown when The Word Processor is expecting a command rather than text. Try the other two things listed on the second line. 'arrows=move' means that if you press the 6 key, which has a down arrow printed above it on the keyboard, the cursor will move down one line. The 7 key moves the cursor up one line. If you use CAPS SHIFT with these commands, the cursor moves eight lines instead of just one. The other two arrow keys, 5 and 8, move you to the beginning and end of the document respectively. Do not use SHIFT with these. 'd=delete' means that if you press the D key while in command mode, the line the cursor is on will be deleted. Using these few commands you can familiarise yourself with entering text and simple editing. The ENTER, command will insert text at the cursor position in the document, so if you want to go back and add some more text before the end, just move the cursor to the right place, then press ENTER. Two special cases worth mentioning: to append text to the document, press 8 then ENTER; to add text before the start of the document, press 5 then ENTER. Feel free to experiment You cannot harm The Word Processor by pressing any key in sight, simply to see what it does. If you see a question you do not understand, press ENTER to get back to the ordinary command level. If you press BREAK, or press CAPS SHIFT and 6 while entering text at the bottom of the screen, The Word Processor will stop with a Sinclair BASIC report. To restart the program, type 'GO TO rs'. This restarts with no loss of text. If you delete a line accidentally, you can bring it back by moving the cursor up one line by pressing 7, then pressing Y ('yank' or retrieve). The Y command will retrieve the last line deleted using the D command. - 4 - The document and the screen display You can have a document up to 950 lines long in memory. The text part of the screen display is only nineteen lines long, so the screen acts as a 'window' looking at the local area of the text, which will always include the cursor. The screen display is automatically adjusted as you move around the document. The commands 5 (unshifted): Move the cursor to the beginning of the document. 6 (unshifted): Move the cursor down one line, unless the cursor is at the end of the document. 6 (with CAPS SHIFT): Move the cursor down 8 lines, or to the end of the document, whichever is nearer. 7 (unshifted): Move the cursor up one line, unless the cursor is at the beginning of the document (on 'line 0'). 7 (with CAPS SHIFT): Move the cursor up eight lines, or to the beginning of the document, whichever is nearer. 8 (unshifted): Move the cursor to the end of the document. A ('again'): repeat the last find or replace operation, with the same options as before, except that in the case of a repeated F (find) command the search will start at the line after the current line, and in the case of a repeated R (replace) command the search will start on the current line. B: Mark the beginning of a block, for use by the C (block copy) and Z (block delete) commands. The block will be shaded yellow on the screen. To turn the beginning marker off, set it to line zero. This means that if you wish to mark a block starting at the beginning of the document, you should press B when you are on line one, not line zero. BREAK: you can stop The Word Processor by pressing the Spectrum BREAK key (CAPS SHIFT with SPACE). If this happens accidentally, restart by typing 'GO TO rs'. If you wish to make a copy of The Word Processor, press BREAK, type CLEAR (the X key) (note that this will destroy any document in memory) then use the command 'SAVE "wp" LINE 1'. Pressing BREAK, then typing RUN, is the way to clear all the data from the file and start again. - 5 - C: Copy the marked block (see the B and E commands) to the cursor position. This will only work if the block markers have been set using the B and E commands. This command will only work properly if the cursor is outside the block to be copied. A block can be copied as many times as necessary, and the receiving position may be before or after the block to be copied. To move a block, rather than just copying it, use the C command immediately followed by the Z (block delete) command. D: Delete the cursor line and close up the text. The cursor will stay where it is, but will be on a different piece of text: the line which was moved up to fill the gap. An exception is deletion of the last line of the document, which moves the cursor back to the new last line. To delete a small group of lines, put the cursor on the first line of the group and press D repeatedly. To delete a large group of lines, use the Z (block delete) command. The last line deleted using the D command can be retrieved using the Y ('yank') command. This also gives a method of copying or moving single lines. E: Mark the end of a block, for use by the C (block copy) and Z (block delete) commands. The block will be shaded yellow on the screen. To turn the end marker off, set it to line zero. ENTER: Enter text at the cursor position. You can type as much text as you like before pressing ENTER again to place it in the document, but in practice you will find it best not to type in more than five lines in one chunk, because the input routine slows down at about that point. The text at the bottom of the screen can be edited before it goes into the text by using the usual Spectrum delete (CAPS SHIFT with zero) and arrow keys (CAPS SHIFT with 6 and 7). Any piece of text you enter which is longer than 32 characters (the width of the screen) will be split into separate lines, without breaking any words. To stop entering text, press ENTER as soon as the flashing L appears at the bottom of the screen. F: Find. First you will be asked 'find:'. Type in the sequence of characters you are looking for. The question 'options:' will appear: press ENTER for a straightforward search of the entire document. If you enter no options, the search will start at the top of the document, and all character positions will be searched. However, you may type in a sequence of characters specifying one or both of the two non-standard options. 'h' means 'start the search here (on the current line) not at the beginning of the document'. 's' means 'search only at the start of each line. If the two options are combined they may be typed either as 'sh' or 'hs'. - 6 - A successful search will result in the cursor being moved to the line containing the target of the search. If the search fails, an appropriate message appears and the cursor does not move. The 'find' command makes no distinction between capitals and small letters. Sometimes you will want to find something without knowing exactly how it is spelt. For example, you might want to find the first occurrence of either 'practise' or 'practice'. When you answer the 'find:' question, type a question mark for any character you are unsure of: in this case, type 'practi?e'. The question mark is known as the wild card character. You can have as many question marks as you like in one 'find' string. A question mark will match any character. L: Load a document from tape. Asks you for the name of the file to load, and searches for a file created by the S (save) command. If the file is found, the document in memory is deleted and replaced by the new file. If you possess The Database, another MiCROL product, you can load files saved by The Database, provided they are not longer than 950 lines. All files saved by The Word Processor can be loaded by The Database. P: Format and print the document, either on the ZX printer or on the screen. Press P again to confirm that you wish to print (in case you pressed P by mistake) then check the display of the printing format to see if you want to make any changes. If you want to change any item, press the number to the left of the item, then type the new value. When everything is satisfactory press ENTER. You will be asked two more questions: whether you want the document to be printed on the printer (the alternative is to print it on the screen only, to check the formatting without wasting paper) and what heading should appear at the top of every page. If you do not want a running heading just press ENTER. The text will now appear on the screen or the printer. You can control the format of the text via commands embedded in it, as well as via the 'printing format' menu. To leave a blank line, just enter a line consisting of a single space. This will appear as a blank line on the screen. To force the next line of text to appear on a new line, insert a line consisting of a single full stop (.) at the appropriate point. To centre a line, place the characters '.c' on a line of their own - 7 - immediately above the line to be centred. These and the other embedded formatting commands are explained in more detail under 'Formatting' below. To break out of printing, press BREAK, then type 'GO TO rs'. R: Replace string. This command uses exactly the same prompts as the F (find) command (see above), but if the search is successful you will be asked for a new string, and the target string will be replaced by whatever you type in. If the result of the replacement is longer than 32 characters, word-wrap will operate and the new line will be split into two or more lines. To delete a string, replace it with nothing: press ENTER in response to 'replace with:'. S: Save document. You will be asked for a file name, and the document in memory will be saved to tape. The time taken to save varies with the length of the document: document of 500 lines will take about a minute to save. The file format is compatible with The Database: see under the L (load) command above. SPACE: Space left. Pressing the space key will display a message saying how many lines are left for text. The document can be up to 950 lines long, so this number will always be 950 minus the length of the document. You can see how long the document is by pressing 8 to move to the end, then looking at the line number, shown at the top of the screen. T: type lines on the ZX printer. This simple command prints whatever you enter on the printer. It allows you to add extra headings, footnotes and postscripts to any document you print, whenever you like. Word-wrap does not operate on this command: you can only type 32 characters at a time. You can type as many lines as you like. Go back to the main command level by entering an empty line. Y: 'yank' (retrieve) deleted line. The last line deleted can be retrieved an automatically reinserted by pressing Y. This not only enables you to recover from errors, but allows you to move a line by deleting it and reinserting it somewhere else, and copy a line by deleting it, then retrieving it more than once, perhaps in several different places. Z: 'zap' - delete marked block. This command will only work if the boundaries bf a block have been marked using the B and E commands. The Word Processor asks for confirmation, then deletes the block and closes up the document. - 8 - Formatting The simplest way of formatting your document is to use the 'what you see is what you get' formatting method. This only applies to a limited extent, but is adequate for most purposes. Using this method, you type your text into the document, leaving a blank line on the screen (by typing a single space, then pressing ENTER) every time you want a blank line to appear on the printed document. If you wish to leave a few spaces at the beginning of a paragraph, just type the spaces in at the start of the line, and they will be preserved at print time. This last feature, however, only applies to text which will appear at the start of a line in the printed document. It is important to remember that text can be entered in completely 'ragged' format. If you type a sentence so that each word is on a separate line, the words will be collected together so that lines are properly filled when the document is printed. This means that when you edit a paragraph using the R (replace) command, you need not worry about rearranging it so that each line has the maximum number of words in. While the 'what you see is what you get' method, in combination with the 'printing format' menu are adequate for simple formatting, other techniques must be used to achieve more complex formats. There are a series of commands which you can place in the text itself to control formatting as the document is printed. Each of these embedded commands starts with a full stop and must occupy a line of its own. The following example shows various embedded commands in use. The raw file as it appears on the screen is shown first, followed by the printed result. .p1 .j1 . c This Heading is Centred This is a piece of ordinary text, justified and printed over a width of 32 characters. .j0 This section is not justified, but left with a ragged right edge. .j1 - 9 - .i10 You can easily indent the text by ten characters. .i0 .w16 This paragraph is printed over on the left hand side of the page. .i16 .w16 And this paragraph is printed on the right hand side. .f0 If you wish, you can turn formatting off entirely, to allow you to position things like 2 e=mc manually. If formatting is off, no justification will be done. .fl .i0 This appears on the printer as: page 1 This heading is centred This is a piece of ordinary text, justified and printed over a width of 32 characters. This section is not justified, but left with a ragged right edge. You can easily indent the text by ten - 10 - characters. This paragraph is printed over on the left hand side of the page. And this paragraph is printed on the right hand side. If you wish, you can turn formatting off entirely, to allow you to position things like 2 e=mc manually. If formatting is off, no justification will be done. Here is a complete list of the embedded formatting commands and their effects: . (just a full stop): Start the next piece of text on a new line. .An prompt: print the prompt or question on the screen and ask the user for variable n, for use in mailmerge. N must be between zero and nine. See 'Mailmerge' below. .C: centre the following line, within the existing margins. .FO: turn formatting off. If formatting is off, lines of text will be printed just as they are, without word-wrap or justification. This is useful for printing tables, graphic designs and other items needing careful manual formatting. .F1: turn formatting on. You need only use it if formatting has been turned off by .F0. .In : indents by n characters. Resets the current line length to 32-n. To turn off indentation, use .I0. - 11 - .J0: turn off justification. Following text will be printed with a ragged right margin. .J1: turn on justification. Following text will be printed with an even right margin. .Ln: set the current page length to n lines. This number does not include the inter-page gap or top margin set by .T. .Pn: set the page number to n, so that the next page printed will be numbered n. .P0 turns page numbering off. .Tn: set the top margin or inter-page gap to n lines. .Wn: set the page width or line length to n characters. Any nonexistent embedded commands will be ignored, except that they will have the effect of the '.' command in starting a new line of printed output. Avoid setting the line length to less than 2, the page length to less than 1, or the inter-page gap to less than 3. If you do one of these things accidentally and the system seems to hang up, press BREAK, then type 'GO TO rs', then edit the text in the normal way. Mailmerge The mailmerge facilities of The Word Processor allow you to create a standard 'skeleton' document, then add the variable information when the document is printed. The best way to explain this is by means of an example. Suppose you have received a lot of presents from distant relatives at Christmas, and you want to write thankyou letters to them all. If you were fiery lazy, you could create a standard letter using The Word Processor, and print as many copies as you liked, adding the variable information, such as the name of the person you are writing to, when the document is printed. If you created a document which looked like this on the screen: - 12 - .a0 name of addressee .a1 present .a2 adjective Dear \0, . thank you for the \1 you so kindly sent me for Christmas. I have found it \2. Your present was especially welcome, because I have been meaning to buy a \1 myself for some time. Yours ever, Johnny the three '.a' commands would result in you being asked the three questions next to them when the document was printed. The answer you give to the question printed by '.a1' will be used to replace every following occurrence of the sequence '\1' in the text. Similarly, the answers given to the questions printed by '.a0' and '.a2' will replace the sequences '\0' and '\2' in the text. There are ten possible '.a' commands, .a0 to .a9, and ten corresponding symbols for substitution, \O to \9. If you printed the document shown above and gave the answers 'Uncle Fred', 'hippopotamus' and 'rather frolicsome' to the questions, the printed result would be: Dear Uncle Fred, thank you for the hippopotamus you so kindly sent me for Christmas. I have found it rather frolicsome. Your present was especially welcome, because I have been meaning to buy a hippopotamus myself for some time. Yours ever, Johnny. When you use mailmerge, remember that mailmerge does not operate if formatting has been turned off using .f0, and that the answer to a question asked by the '.a' command cannot be longer than 32 characters. Also, remember to put your '.a' commands before any text which is to receive substitutions. - 13 - Summary of commands ARROW KEYS: 7 and 6 (unshifted) move up and down one line, or (shifted) move up and down eight lines. 5 and 8 (unshifted) move to the beginning and end of the document. A: 'again' - repeat the last find or replace, using the same options, but starting from the current position. B: mark the beginning of a block. BREAK: stop The Word Processor. 'GO TO rs' restarts. C: copy marked block to cursor position. D: delete the current line and close up the gap. See Y. ENTER: enter text at the cursor position (i.e. after the current line). F: Find string. If you press ENTER in response to 'options:', F searches all positions in document. See 'The commands' for details of options. L: Load file from tape. If the load is successful, any previous document is deleted. P: print document. See 'The commands' and 'Formatting' for details. R: replace string. Like F (find) but asks 'replace with:' if the search succeeds. S: save file on tape. T: type line or lines on the printer. Y: 'yank' - retrieve last line deleted. Z: 'zap' - delete marked block. Asks for confirmation. - 14 -