ASM 3500 DXF to GDSII Bidirectional Translator

Text Conversion and Fonts

Often when designing a layout in AutoCAD (or other program that produces DXF) the user wishes that text be converted into GDSII. ASM 3500 has a number of different methods for text conversion and the user can choose between them depending on the application.


Each string of text in a DXF file carries with it a STYLE Attribute. The STYLE Attribute then contains a pointer or link to a font: detailed instructions on how to construct each character. When AutoCAD was initially released, it used its own proprietary fonts known as SHX fonts. These fonts were built on the assumption that text was drawn with a pen plotter so the fonts defined the path (or stroke) that the pen plotter should follow. The "width" or "weight" of the stroke was determined by the diameter of the pen; not in software.

AutoCAD's STYLE dialog box. You can see the various attributes that can be associated with a given style. In this example, the STYLE called Arial points to the font called Arial. A DXF file can have multiple STYLEs in it.

Once AutoCAD moved from the DOS environment into the Windows operating system, it slowly started making use of Window's native fonts, known as True Type fonts (TTF). For the most part, these fonts are not stroke based - instead they define fillable regions that the plotting device will fill on its own, one way or another. We call these outline fonts or fillable fonts.

fillable font (TTF) vs stroke font (SHX)

Stroke Font Thickness

How do stroke fonts get the stroke thickenss since the font itself does not contain that information? The translator assigns the thickness. But we don't assign a fixed value because the same stroke thickness is not appropriate depending on the height of the text. For most stroke fonts, a stroke weight (text height/stroke diameter) should be approximately 1/7 to 1/10. So ASM3500 enables the user to enter the "weight" of text height to stroke diameter.

Left:stroke weight good:(10:1)

Middle:stroke weight too big:(4.5:1)

Right:stroke weight too small (21:1)

examples of different stroke weights


Text strings in GDSII also have a font attribute - however other than the attribute itself, there are no standard GDSII fonts that describe how to render the text. GDSII requires each string of text to be assigned to one of four fonts: 0,1,2,3. But it is up to the program that displays the GDSII to actually render the text. Artwork's GDSII viewing software, Qckvu3, uses .SHX fonts to render the text on screen.

When converting from DXF to GDSII the user first must decide: Do I want strings of text in my GDSII output or do I want the text to be converted to geometries such as boundaries or paths? ASM 3500 can do either. (But not both at the same time.)

DXF2GDS Text Settings Dialog

This dialog is used to control how text is converted from DXF to GDSII.

DXF2GDS Text Settings Dialog

• Translate Text to GDS Text Font

If this is selected, then strings of text in DXF will be converted to strings of text in GDSII.

DXF Style
The translator will show each DXF text STYLE

The translator shows the FONT linked to the DXF text STYLE

GDS Font
The user can assign one of the four available GDS Fonts to a DXF STYLE

GDS Font Scale Divisor
This value can be used to divide the "height" of the DXF font by a user specified amount. Default = 1.

• Convert DXF Text to Stroked Text and Boundaries

If this option is checked, then DXF text will be converted either to stroked paths (if the font is an SHX font) or to boundaries (if the font is TTF). Please note that TTF support requires a separate license feature. If you don't have the license then the TTF support section will be grayed out.

TTF Support

Primary Font Directory

Your TTF fonts are likely located in the directory where Windows stores its font files. This is typically C:\Windows\Fonts. So you probably want to specify your Primary font directory using this path/location.

Secondary Font Directory

If for some reason you keep additional TTF fonts in a different directory, you can specify that directory in the Secondary Font Directory.

TTF fonts will be converted into boundaries in GDSII. ASM3500 will automatically handle the clear areas inside of characters by using re-entrant boundary as needed.

Example of a cut-line (re-entrant boundary) on a character with holes.

SHX Support

DXF text strings that use SHX fonts are converted into GDSI paths with round end caps.

Primary Font Directory
The first directory to search for the SHX font that matches the text's FONT attribute.

Secondary Font Directory
The second directory to search for the SHX font that matches the text's FONT attribute.

Stroke Text Weight
A parameter that tells ASM3500 how "thick" to make the stroke. This parameter is the ratio of the text height to the stroke diameter. Typical values range from about 6-10. This parameter is a way to make text of varying heights render nicely.

example of a stroked text (SHX) as it appears in GDSII

Temporary Working Font Directory

When ASM3500 works with TTF fonts, it first converts the TTF into SHX. The converted SHX file is stored in the Temporary Working Font Directory along with a table that marks that font name as an outline font (as opposed to a stroked font which is the default for SHX fonts.)

Later references to strings with the same TTF font don't require a font conversion if ASM3500 finds the SHX equivalent in the temporary working font directory.

ASM3500 should have write privileges to this directory.

• Convert DXF Text to Boundaries Using Block Font - Pgfont.shx

This is a legacy option used before TTF fonts were available. It was intended for GDSII files that were going to be fractured into pattern generator code for mask making. Pattern generators created masks by printing a series of rectangles onto the glass substrate. As they were very slow, one wanted a font that would print efficiently, even if it was not very pretty. Artwork created its own special font, PGFONT.SHX which accomplished this.

example of the PGFONT output in GDSII