|
|
A single Unicode font, due to its large character set, is capable of supporting all languages and platforms. Unicode shape definition files are virtually identical in format and syntax to regular AutoCAD shape definition files.
The main difference is in the syntax of the font header as shown in the following code:
*UNIFONT,6,font-name
above,below,modes,encoding,type,0
The font-name, above, below, and modes parameters are the same as in regular fonts. The remaining two parameters are defined as follows:
Another important difference is the handling of the code 7 subshape reference. If a shape description includes a code 7 subshape reference, the data following the code 7 is interpreted as a two-byte value. This affects the total number of data bytes (defbytes) in the shape description header. For example, the following shape description is found in the romans.shp file:
*00080,4,keuroRef
7,020AC,0
The second field in the header represents the total number of bytes in the shape description. If you are not used to working with Unicode font descriptions, you may be inclined to use three bytes rather than four, but this would cause an error during the compiling of the SHP file. This is true even if the shape number you are referencing is not in the two-byte range (below 255); the compiler always uses two bytes for this value, so you must account for that in the header.
The only other difference between Unifont shape definitions and regular shape definitions is the shape numbers. The Unifont shape definitions that AutoCAD provides use hexadecimal shape numbers as opposed to decimal values. Although hexadecimal numbers are not required, their use makes it easier to cross-reference the shape numbers with the \U+ control character values.