Carolyn's Corner - April, 1992

Last month I described the creation of a custom printer driver for AtariWriter Plus, using the decimal codes from your printer manual for fonts, line spacing, etc. Occasionally, even a custom driver may not offer enough choices to designate the codes for all the special effects you might want to include in some of your documents. This need not be a problem, because AtariWriter Plus offers a way to embed any special codes that you may need.

Look in your printer manual for "Control Codes" or "Escape Codes." All but a few of these codes begin with the ESCAPE character (ASCII 27). Let's say you want to print a chart with several columns, and you know from experience with your printer that the chart will be better aligned vertically if you use unidirectional printing instead of the default bi-directional printing. You can enter the required decimal codes in your text using [CNTRL-O]. (That's the letter "O", not a zero.) From now on I will indicate [CNTRL-O] as {O}.

On the blank line just before your chart begins, type {O}27{O}85{O}1. (This is the code for an Epson printer or compatible.) On the blank line following your chart, type the same code except for the final "1". Replace that with a zero. This will cause subsequent printing to be done in the faster bi-directional mode.

Sometimes you want to italicize a few words in the body of your text. Just enter {O}27{O}52 before the words to be italicized and {O}27{O}53 after.

Your printer can print characters that are not found on 8-bit Atari keyboards. Here are some that are occasionally needed:

     {O}96  will print:  `
     {O}123 will print:  {
     {O}125 will print:  }
     {O}126 will print:  ~

Once when I needed to print the cents sign, I typed the following: c{O}8/. This caused my printer to print the letter "c", backspace, and type the slash over it. Printing A{O}8v will result in a star character if you're using a font with serifs. There are other combinations you can use with the backspace (ASCII 8) to make do when you want a special character that isn't normally available. Experiment.

You can make your printer sound a beep with {O}7, although I don't know why you would want to. Maybe to let yourself know when the printer had arrived at a particular page that you wanted to check before continuing.

Changing most fonts, line spacing, underlining, etc., is more simply accomplished by using the AtariWriter Plus codes. However, if you want to print double-high characters, or add special effects such as shadow or outline (if available on your printer), embed the required decimal codes in your text using {O} before each one.

If the effect you are after is one that you want to use throughout your document (such as NLQ), here is a tip: Put the required code in a header line. In that way, if you start a printout from other than the first page, the special code will still be in effect.

When you check your document with Print Preview, you will find that embedded CONTROL-O codes cause some lines to appear too long. That's because AtariWriter assumes that these codes will not be printed in themselves and, therefore, correctly shows your text appearing on the lines on which it will be printed.

Because the codes are somewhat of a distraction when proofreading your text from the edit screen, you may want to enter your text without the codes and then go back and enter them later, after the proofreading. And, by the way, the codes themselves do not cause the printer to do a linefeed, but if they are alone on a line that ends with a carriage return, a blank line will be printed. Often that is what you want. If, for any reason you don't want that blank line, delete the carriage return and let the codes precede the first word on the next line.

There is another situation in which the [CNTRL-O] function comes in handy. If you use {G}4 for a superscripted number 2, for instance, referring to a footnote, you might type the following:{G}42{G}1

However, when you try to use Print Preview or actually print your document, you will get the error INVALID TYPE FONT. That's because the program thinks you are asking for font 42. Either you must leave a space between the 4 and the 2, or you must designate the 2 as {O}50 (if you don't want the space):{G}4{O}52{G}1

The ASCII codes for the digits 0 through 9 are 48 through 57, inclusive.

I hope the above suggestions will help you produce professional-quality documents with AtariWriter Plus.

Return to Articles index