APPLICATION NOTE #162 CREATING A PT (PRINT TYPE) TABLE TO DEFINE ADDITIONAL FONTS Rev. 01 XyWrite uses PT (Print Type) tables for easy switching between two or more fonts. Due to space limitations on our master disks, standard XyWrite printer files are not set up to access all the fonts or attributes that are available with your printer. Instead, the printer files define the attributes and fonts, and provide sample PT tables. Generally, PT=1 is Pica, PT=2 is Elite, and PT=3 is Proportional (providing your printer is capable of this output). You can use these samples to create additional PT tables. FONTS AND ATTRIBUTES In order to get the most from your printer, you need to add PT tables for the other available fonts and attributes. The first section of each printer file lists all fonts and attributes available. For XyWrite purposes, a font is a type style such as Pica, Elite, Helvetica, or Times. An attribute is a printer effect that is added to a font to modify its appearance. Common attributes are Underline, Bold, NLQ (Near Letter Quality), Superscript, and Subscript. Fonts and attributes vary from printer to printer. In fact, what's defined as an attribute in one printer file may be a font in another printer file. For example, in many laser printers Bold is an actual font or type style (e.g., HELVETICA-BOLD), while in dot matrix printers Bold is an attribute produced by having the printer overprint each character (e.g., PICA+BOLD). Notice that font names use hyphens between words, while attributes are separated from the font name by a plus sign. When you are modifying printer files, the distinction between fonts and attributes is an important one. ADDING A PT (PRINT TYPE) TABLE You can use the PT tables already in your printer file as building blocks to create tables for other fonts. For example, if you use the printer file 3EPSONFX.PRN and you want to create a PT table to access the compressed font, first call your printer file to the screen. Type: F5ca 3epsonfx.prn Note the font names listed at the beginning of the file. You must use these exact names. To create a print type table for compressed in this printer file, you would use the font name COMPRESSED. The easiest way to create a new PT table is to define and copy an old PT table and substitute the new font name. Locate the line PT=3 and place your cursor on the letter P. Press F1 to define the beginning of the table. Move the cursor past the mode statements and the comment line (;{ESC-27}) and press F1 again to close the defined block. Now press F7 to copy the table and press F3 to restore the defined text. (Make sure after you copy the table that the lines before and after are preceded by a semicolon.) Renumber the new PT table. You can use any available number between 1 and 255 (with the exception of PT=32). We recommend that you use the next available number (in this case, PT=4). Next, change the font name from PROPORTIONAL to COMPRESSED. The new PT table should look like the one shown below. ; PT=4 MD NM+COMPRESSED MD BO+COMPRESSED+EMPHASIZED+DOUBLE MD UL+COMPRESSED+UNDERLINE MD RV+COMPRESSED+FORMS MD BU+COMPRESSED+EMPHASIZED+DOUBLE+UNDERLINE MD BR+COMPRESSED+ITALIC MD SU+COMPRESSED+SUPERSCRIPT MD SD+COMPRESSED+SUBSCRIPT MD MM+MICRO It is not necessary to change any of the mode statements or attributes, although you can modify them if you wish. You can also delete unnecessary mode statements, as long as you have a definition for normal mode (MD NM) in every PT table. (If there is an MD MM statement in the PT table, you must retain that statement as well.) When you have completed the changes, store and load the edited printer file. If you get an error message, the most likely cause is a misspelled font or attribute name. Be sure the names you used in the new PT tables are exactly as listed at the beginning of the file. Make any necessary changes and reload the file. When you want to access this font in your text file: Type: F5pt 4