Text Alignment Problem when Outputting DWG
------------------------------------------

A problem can occur with Text Alignment for DWG output where the end
application is AutoCAD itself.

If the text is Left justified there is no problem.

Otherwise it is necessary for Arcv2CAD (or any application for that
matter) to know the exact width of characters in a font, in order to
get the alignment point exactly correct.

The technical reason for this is that AutoCAD only calculates the
alignment point (or justification point) when the text is originally
inserted.  This means that AutoCAD does not need to calculate the
alignment point each time it draws the text.  The drawback for other
applications that are attempting to produce DWG is that they must
also know the exact width dimensions of all the characters in a font
in order to pre-calculate the same alignment point.

The problem does not occur for DXF, because AutoCAD calculates
the alignment point in this case upon reading the DXF.

The problem will also not occur for most non-AutoCAD applications
that can read DWG, because they either calculate the alignment point
on the fly (eg QikDraw), or will calculate a correct alignment point
for the font being used upon reading the DWG file.


Solution 1
----------

The simplest solution is to use DXF output instead of DWG



Solution 2
----------

The second solution is only viable if you have access to the .SHX
font file which has been specified as the Text Labels font.

Arcv2CAD provides a font width lookup table in a file called
FONTWID.DAT.  This file contains the widths of the common fonts used
with AutoCAD (eg monotxt, simplex etc).


When Arcv2CAD is doing a translation it will look in this file to see
if the font dimensions for the specified Text Lables font exist in
this file.  If it is there then no problem.  If not, then Arcv2CAD
will issue a warning that the alignment may not be correct, and will
direct you to the file you are now reading for a remedy.


You can create a second lookup table that Arcv2CAD will look in.   
This is done using the utility called MKSHXTBL.EXE, and this utility
is located on the installation disk (for the licensed version of
Arcv2CAD only).  Copy this file to the directory where your .SHX
files are located, and run it from a DOS window (by typing
mkshxtbl).  The utility will create a new font width lookup table in
a file called ADSHXWID.DAT, and this file will contain the width
dimensions of all the .SHX files in that directory.  Copy this file
to the Arcv2CAD directory.  Now when you run Arcv2CAD, it will also
search this file for the character widths.

Note: this will only work for .SHX fonts.   For Postscript (.PBF)
fonts a convoluted workaraound is to compile the .PBF file to a .SHX
file.  For true type (.TTF) fonts we do not have any workaround,
always use DXF in this case.

