Classic Computer Magazine Archive ANTIC VOL. 2, NO. 1 / APRIL 1983

ATARI Printfont

by Jerry White

The ability to redefine ATARI's character set provides many exciting possibilities. Redefined characters can be used to create special symbols such as those used in mathematical calculations or chemical formulas. This same principle can be applied to create anything from a map to a monster. For example, character graphics are used to create the monsters in ATARI's Space Invaders, to create the terrain in APX's Eastern Front, and to create the puzzle parts in ARTWORX's Nominoes Jigsaw.

In standard printing practices, character sets are available on a font, which contains a complete assortment of any one size and style of type. For microcomputers there are various utility software products available that make character creation relatively easy. What is not so easy is to remember how each character has been redefined. ATARI Printfont can help you find these different characters in your font files.

Let's assume you've just created a font file where various characters will be combined to create four different space vehicles. You have redefined many of the lowercase letters and standard graphics characters. Now you want to define strings of the characters that form each ship. The problem is that you don't remember which characters create which ship.

The following program can provide a printed listing for quick and easy reference. The font file reads from Disk Drive One to list all 128 characters. You must have 24K RAM, a disk drive and an 80-column printer.

The program listing is welldocumented with REM statements. It is written in ATARI BASIC with one assembler subroutine. Stored in the string FL$, the assembler routine is used to transfer the disk font file into RAM. This could have been done with a FOR / NEXT loop and the GET command, but it would take at least ten seconds. The assembler routine works in less than two seconds.

Since this program listing will appear in a magazine, a routine was added to read the DATA from lines 500 and 510 to create the FL$ string. Once this has been done, you can eliminate this routine and permanently store the routine as a string in the program. To do this, add a STOP command as line 35. When you RUN the program and it stops at line 35, type PRINT FL$ [RETURN]. Move the cursor over the first character of the string which should be a small letter "h". While pressing [CTRL], press [INSERT] eight times. In the space we just created in front of the string, type "35 FL$ =" then press [RETURN].

Don't worry about the end quotes for the string because BASIC will do that for you. Now delete the FOR/ NEXT loop from line 30, leaving only the DIM and PRINT statements. You may also delete lines 500 and 510 since you won't be needing the DATA anymore, and don't forget to resave the program.

This assembler routine is set up to put the character set on Page 48 in memory, or beginning at RAM location 12288. If you'd like to use this routine to store a character set someplace else in another program, just change the fifteenth byte in the string as needed. You may find it worthwhile to keep the DATA statements, and change the last number in line 500 (48), to the desired page number in memory.

The rest of the program and its operation are relatively straightforward. Just remember that when you enter your font filename, you will be using Disk Drive One.