These tools are contained in wgtfnt10.zip. They require
a 80186 or higher CPU to execute and are to use from the DOS
command line interpreter:


COLORX:

COLORX is a color palette extractor for several bitmap file
formats. COLORX supports BMP, GIF, LBM and PCX graphics
formats.

FUNCTION:
If a true color bitmap file format like PPM is used every
pixel has its own RGB color triplet representing the color of
the pixel. In indexed color formats like GIF every pixel is
nothing else but an index to a color table holding the RGB
triplets of the pixels. This color table can be sorted in
various ways. Giving every pixel its own RGB triplet makes a
color table unnecessary. Therefore the sorting within the
color table is lost in a true color format. To preserve the
sorting COLORX was made. COLORX writes a PPM compatible
palette file (plain text/UNIX style) which can be used when
converting a PPM font matrix to the indexed WGT .SPR format.

USAGE:
COLORX srcfile.ext [destfile[.ext]] [-noscale]

If dest. file is left out dest. file name will be src. file 
name with .PAL extension.
If dest. extension is omitted dest. extension will be .PAL
If dest. file already exists, COLORX overwrites the file.

-noscale: a rather unimportant option. Most bitmap file
formats store R,G,B values ranging from (0,0,0) to
(255,255,255). Of course a VGA card can't take that. Therefore
the R,G,B values are automatically scaled to (0,0,0) -
(63,63,63) by COLORX. If you don't want this scaling you can
prevent it by setting the option -noscale.


WPLTOPAL:

WPLTOPAL converts a WGT palette file into a PPM palette file.

FUNCTION:
Use WPLTOPAL to convert a WGT palette file to a PPM palette file -
the palette file format FNTTOSPR works with.

USAGE:
WPLTOPAL srcfile[.ext] [destfile[.ext]]

If src. file extension is left out .WPL is used.

If dest. file name is omitted dest. file name will be src. file
name with .PAL extension.
If there is no dest. file name extension .PAL will be used.
If dest. file already exists it will be overwritten.


BMPTOPPM:

BMPTOPPM converts a OS/2 or Windows Bitmap to a Portable PixMap
- the graphics file format used by the FNTTOSPR conversion
utility.

FUNCTION:
The FNTTOSPR font conversion utility delivered in this package
requires a PPM file as input. However the PPM graphics format
is not well known on the PC platform and is therefore only
supported by a few programs. On the other hand the BMP
graphics file format is very popular among PC users and there
is a lot of software existing that converts almost any graphics
file to the BMP format.
BMPTOPPM can read OS/2 and Windows BMP files and convert them
into the PPM format used by FNTTOSPR. BMPTOPPM can read the
following BMP formats:

color depth (bits)	type		compression
===================================================
      1			OS/2 PM 1.2	RGB
      1			Windows 3.0	RGB
      4			OS/2 PM 1.2	RGB
      4			Windows 3.0	RGB
      4			Windows 3.0	RLE4 *)
      8			OS/2 PM 1.2	RGB
      8			Windows 3.0	RGB
      8			Windows 3.0	RLE8 *)
     24			OS/2 PM 1.2	RGB **)
     24			Windows 3.0	RGB **)

*) many programs can't compress bitmaps according to the RLE
   compression scheme correctly. Therefore it is not
   recommended to use this compression scheme when storing
   bitmaps.

**) BMPTOPPM can convert true color bitmaps to the PPM format.
    However if these true color bitmaps contain more than 256
    colors (they usually do) FNTTOSPR will refuse to work with
    them.

BMPTOPPM can process bitmaps with up to 4096x4096 pixels in
size without using extended or expanded memory or a temporary
file (Yeah! There is some black magic working for you).

USAGE:
BMPTOPPM srcfile[.ext] [destfile[.ext]] [-debug]

If src. file extension is left out .BMP is used.

If dest. file is left out dest. file name will be src. file 
name with .PPM extension.
If dest. extension is omitted .PPM will be used.
If dest. file already exists, BMPTOPPM will overwrite the file.

Options: -debug: displays some additional information about
	  the BMP bitmap file.


FNTTOSPR:

FNTTOSPR converts a PPM pixmap which contains a font matrix
into a WGT sprite file usable by the WGT sprite editor V4.0.

FUNCTION:
FNTTOSPR is a font OCR software which can convert fixed and
proportional width fonts into the WGT .SPR format. To use
this program it is required to create a font matrix bitmap and
save it as a PPM file. FNTTOSPR takes this PPM file and
writes the font information inside it into a WGT sprite file
which can be converted to a WGT font using the WGT sprite editor.
The PPM pixmap which shall be converted may not have more than
256 colors - otherwise FNTTOSPR will fail. The upper left pixel
of the PPM pixmap must have a color which is not being used in
the font characters (= must have the background color). If a
colormap is used color 0 (the first color in the PPM .PAL file)
must be the background color.
The font matrix bitmap you have to create must have a certain
appearance. In principle it looks like this for fixed width
fonts:

@ @|$

@ !"#$%&'()*+,-./ $
@0123456789:;<=>? $
@@ABCDEFGHIJKLMNO $
@PQRSTUVWXYZ[\]^_ $
@abcdefghijklmno $
@pqrstuvwxyz{|}~  $

The first character line in a font matrix bitmap is the 'sync
line'. It contains sync characters which are required for the
font OCR process.
The first character in a fixed width font sync line (the
'master sync') has to occupy (at least a part of) the leftmost
column of the fixed font character matrix. The @ character in
the Windows fixedSys font fullfills this condition. But you
may have to use other characters for other fixed width fonts.
The master sync has to be connected horizontally. For example
" can never be a valid master sync since there is a gap
between the two quotes.
The next character in the sync line is always the space char.
After the space char the master sync character has to follow.
Following the 2nd master sync are two auxiliary sync chars:
The first auxiliary sync character has to occupy (at least a
part of) the bottom row of the fixed font character matrix.
| does this in the Windows fixedSys font case.
The second auxiliary sync has to occupy (at least a part of)
the top row of the fixed font character matrix. $ does this in
the Windows fixedSys font case.
After the sync line leave one line blank.
Now the font data lines follow. Each font data line begins
with the master sync. Immediately after the master sync the
character data follows. Each line has to contain 16 'data'
characters. After the 16 data characters a space follows and
after the space the auxiliary sync #2. The font data lines may
not overlap. The data chars are stored in the font data lines
in increasing ASCII code order - beginning from ASCII code
20h (SPACE char).
You don't have to define always six font data lines. If a
font only contains uppercase characters you may only define
four font data lines for example.
However there MUST be always 16 data chars in a font data line.
If the last font data line contains less than 16 data
characters fill it up with spaces so that the auxiliary sync #2
is always at data character position 18. It is also required
that the last font data line contains auxiliary sync #1. If
it isn't there already put it after auxiliary sync #2 at data
character position 19.
FNTTOSPR is very sensitive to the appearance of the master
sync. The master sync must always look the same in each font
data line - otherwise FNTTOSPR will fail.
Take a look at fixedsys.wri and fixedsys.bmp to become
familiar with the conversion of fixed width fonts.

The font matrix bitmap for a proportional width font may look
like this:

A A |$

A ! ' # $ % & ' ( ) * + , - . / $
A 0 1 2 3 4 5 6 7 8 9 : ; < = > ? $
A @ A B C D E F G H I J K L M N O $
A P Q R S T U V W X Y Z [ \ ] ^ _ $
A  a b c d e f g h i j k l m n o $
A p q r s t u v w x y z { | } ~ $

Note: In a proportional width font matrix ALL characters have
to be connected horizontally. Take a look at the font data
line #1. " is replaced by ' to fullfill this condition.

Again, the first line in the matrix is the 'sync line'. It
holds special 'sync' characters which are required for the
font OCR process. The first character in the sync line is the
'master sync'. For a proportional width font it is required
that the x-spacing between two master syncs printed immediately
after each other is 0 (this means: in this situation the
master syncs should 'stick' together but should not overlap).
'A' fullfills this condition in the TrueType Arial font case.
After the master sync the space character follows and again a
master sync. The next two characters are the auxiliary syncs
#1 and #2:
The first auxiliary sync character has to occupy (at least a
part of) the bottom row of the prop. font character matrix.
| does this in the Windows TTF Arial font case.
The second auxiliary sync has to occupy (at least a part of)
the top row of the prop. font character matrix. $ does this in
the Windows TTF Arial font case.
After the sync line leave one line blank.
Now the font data lines follow. Each font data line begins
with a master sync. Then the character data follows. Note
that there is a space between each character in the font data
lines to prevent overlapping of characters. Each font data
line must contain 16 data characters. After the 16 data chars
follows the auxiliary sync #2. You will notice that font data
line #1 contains only 15 data characters. This is due to the
fact that the sync line's space character will be inserted by
FNTTOSPR at the beginning of the first font data line - giving
in summary 16 data characters for the 1st font data line as
well. The font data lines may not overlap. The data chars are
stored in the font data lines in increasing ASCII code order -
beginning from ASCII code 21h ('!' char).
You don't have to define always six font data lines. If a
font only contains uppercase characters you may only define
four font data lines for example.
However there must be always 16 data chars in a font data line
(except the font data line which would contain ASCII code 20h
- the SPACE character. The space character will always be
inserted from the sync line at logical font matrix/ASCII 
code 20h. Therefore this line may only contain 15 data 
chars).
If the last font data line contains less than 16 data
characters fill it up with auxiliary sync #2's so that it
contains at least 16 data chars (- in this case count the
auxiliary sync #2 as a data character). Also auxiliary sync #1
has to appear in the last font data line. If it isn't there
already put it after the last auxiliary sync #2 (of course you
have to leave a space between auxiliary sync #2 and auxiliary
sync #1).
FNTTOSPR is very sensitive to the appearance of the master
sync. The master sync must always look the same in each font 
data line - otherwise FNTTOSPR will fail.
Take a look at arial24.wri and arial24.bmp to become familiar
with the conversion of proportional width fonts.

USAGE:
FNTTOSPR srcfile[.ext] [destfile[.ext]] [@[colormap[.ext]]] [-option] [-option] ...

If src. file extension is left out .PPM / .PNM is used.

If dest. file name is left out src. file name will be used
with .SPR extension.
If dest. file extension is omitted .SPR will be used.
If dest. file already exists FNTTOSPR will overwrite the file.

If no PPM colormap is specified, FNTTOSPR will create the
index color table directly from the PPM file. This index
color table is sorted by the first appearance of each color
in the PPM file.
If @ is found in the argument list without a colormap name
src. file name will be used with .PAL extension as colormap
file name.
If a colormap file name is specified, but without extension,
.PAL extension will be assumed.
If a PPM colormap is specified FNTTOSPR will sort the colors
of the font according to their order in the colormap. Using a
colormap can slow down the conversion process significantly.
COLORX can be used to extract a colormap of the processed font
out of BMP, GIF, LBM and PCX files.
Note: FNTTOSPR automatically optimizes the palette that is
passed with the @ option. This means that two or more identical
colors will be represented by only one color entry in the final
sprite colormap.

Options: -debug: displays some additional information about
	  the font conversion process.
	 -fixed: instructs FNTTOSPR to create a fixed width
	  font. By default FNTTOSPR attempts to create a
	  proportional width font.
	 -starthh: hh stands for a hex value from 00-f0. This
	  option tells FNTTOSPR which ASCII code the first
	  data character in the first font data line has. If
	  you want to create a font which consists only of the
	  numbers 0-9 you naturally want to start from ASCII
	  code 30h which is the code for '0'. The default
	  start character (= first data font line, first data
	  character) is 20h (SPACE). Refer to ASCII code
	  tables for further information.
	 -spcdd,dd: dd stands for a decimal number from 0 to
	  99. You can add an artificial spacing between
	  characters by specifying this option. While not often
	  used with fixed width fonts it is required for
	  proportional width fonts to create a spacing between
	  the characters so that they do not stick together.
	  The first decimal value is the spacing in x direction,
	  the second decimal value of the option the spacing in
	  y direction. The default value for spacing in the x/y
	  direction is 0/0.
	  WGT version: If -spcdd,dd is used the artificial
	  spacing will be done in the background color (color 0)
	  unless the -coff option is found in the argument list.
	  If this is the case the spacing will be done in the
	  color passed with the -coff switch. If -zrz is active,
	  too it forces FNTTOSPR to do the spacing in color 0.
	 -lum: sort colors of the font by increasing luminance.
	  Color 0 will have the lowest luminance and color 255
	  the highest luminance (if the font has 256 colors).
	  If you are using this option the color with the
	  lowest luminance must be the background color of the
	  font matrix if FNTTOSPR should work properly.
	  This option can only be used in conjunction with
	  a PPM colormap which can be specified by @. If no
	  colormap for the PPM file is available the PPM
	  file itself can be used as a colormap (which takes
	  FNTTOSPR some time to compute).
	 -coffddd: ddd stands for a decimal value ranging from
	  0 to 255. This option is for use with graphic systems
	  that support local color palettes. In a local palette
	  graphics system every object has its own color property.
	  Think of a background picture transition from a jungle
	  to a river. The jungle background picture has its color
	  property of say 64 colors - the river background has a
	  64 color property as well. To transite smoothly between
	  the two backgrounds it is required that both color
	  palettes have different color index numbers - otherwise
	  the palette of the river would overwrite the palette
	  of the jungle and the picture would have a messy color
	  appearance. To assign both background pictures different
	  color index numbers use -coffddd with ddd as starting
	  color index number. Example:
	  To assign the jungle picture the colors 64-127 use
	  -coff64 for it.
	  To assign the river picture the colors 128-191 use
	  -coff128 for it.
	  The default -coff value is 0 - meaning no color
	  transition takes place.
	 -zrz: this option is used in conjunction with the -coff
	  switch. In some graphics systems color index 0 has a
	  special substance - as transparent color for example.
	  If this is the case it is most often not desired to
	  transition color 0 with the other colors when using the
	  -coff option. Adding the -zrz parameter leaves color 0
	  untouched while all other colors are transitioned.


SHAREWARE LIMITATIONS:
----------------------

FNTTOSPR (Shareware):
FNTTOSPR will convert max. 64 characters from a PPM font matrix
pixmap to a WGT .SPR font. The -starthh option is disabled.
FNTTOSPR will assume that the first data character to convert
has the ASCII code 20h (SPACE).

