Windows Fonts - v14


 

General

This document provides an overview for the implementation of a new functionality that has been introduced in Eagle V14 to enable the use of Windows Fonts for Annotation and Dimension items.  Using Windows Fonts makes a significant improvement in different processes of the drawing life-cycle. The Display process is greatly enhanced both in terms of the quality of the graphic and performance in rendering, since individual text is no longer displayed via software drawing each segment that makes up the individual character, but instead by using directly one GDI call for each annotation line.

 

Additionally, the process is also enhanced by the fact that it is no longer limited to using Eagle-Font files, this having the double positive effect of removing the need for creating proprietary Font files for fonts that differ from standard Eagle fonts but also allowing transparent access to all the True Type Fonts (TTF) available to Windows OS, including both, proportional and non-proportional fonts.

The Export process is also enhanced with the possibility of defining a suitable match between the Windows fonts that are used for the Display process and the corresponding fonts used in AutoCAD through the standard TABFONT configuration file.  Also special characters like degree symbol and similar can now be properly exported without the need of pre-processors to replace such characters.

 

The Plotting process is also enhanced with the capability of using the same Windows Fonts that are defined for the Display process in the generated output file on the device..

 

Finally, this functionality represents is a significant step in the direction of supporting UNICODE, since the direct use of GDI for displaying individual lines of text provides a fundamental block for displaying characters in any Windows-supported font.

 

Display process

With respect to the Display process, the following new functionality have been introduced.

The FONT command now allows redefining FONT 1.

The FONT command has been changed to allow the definition of Windows fonts.

When the font file is defined without an extension like “.fnt” in the name then a Windows font is assumed, i.e.:

FONT <n>=<font name>

These font names may or may not include blank characters. For example:

 

 

Sample Code :

 

 

FONT 2=Verdana

FONT 3=Berlin Sans FB

FONT 4=-eaglepath/bft/stdfont.fnt

 

This example underlines the possibility to define both font types at macro level however the font choice for drawings documents should be to use either Windows fonts or Eagle fonts rather than a hybrid mix.

 

Windows fonts are used when FIRMWARE T is set.  Eagle starts by default using Eagle fonts,  SOFTWARE T is active.   If Eagle fonts are found in the document when FIRMWARE T is activated then the default Windows “Courier New” is used as the corresponding font.   As an aside, note that DASH, HATCH and Polygon FILL the default is FIRMWARE.

 

A new SET has been introduced to implement transparency for Windows fonts:

 

Prototype :

 

 

 

SET

TEXTTRANSP = ON | OFF

 

At the program starts up the TEXTTRANSP value is ON.

 

When this value is set to OFF then the firmware annotations are OPAQUE. This functionality can be used together with the DISORDER command to “hide” geometries placed below annotations.

 

When issuing the FIRMWARE T or SOFTWARE T commands a redraw is automatically invoked.

Special characters are automatically converted on the fly during the Display process. In particular we note that Eagle provides an implicit handling of the following:

 

‘@'  represents         'Ø' (diameter sign)

'~A' represents          '°' (degree sign)

'~B' represents          '’' (minutes sign)

'~C' represents           '”' (seconds sign)

'~D' represents          '±' (plus-minus sign)

 

The above characters are handled through the usual Eagle-Font file when SOFTWARE T is specified, while they are converted into the corresponding graphic sign when FIRMWARE T is specified.

Export process

The Export process has been enhanced with the possibility of defining a proper match between the Windows fonts used for the Display process and the corresponding fonts to be used in AutoCAD. This is implemented through the standard TABFONT configuration file.

In addition, special characters like the degree symbol and similar can now be properly exported creating DXF or DWG files without the need of pre-processors to replace these characters

Plotting process

In respect to the Plotting process, a new pair of utilities has been released for Xplot and Winplot: Xplot V.7.2.1 and Winplot V.2.1.7.

When using Xplot the user can specify “SET FONT -1”. If this setting is issued then the generated output file includes extra information describing the font associated to each individual text and this in turn is used later in the plotting process by Winplot. This particular fact highlights the issue that output files produced by Xplot V7.2.1 should only be used in conjunction with Winplot V.2.1.7 or greater.

When Winplot finds font information related to text to be plotted it then uses Windows Fonts for rendering that text.

 

A new section in the WINPLOT. INI file, called [DefaultFonts], has been defined that enables configuration of the Windows fonts that must be used for plotting. For example:

 

INI Sample :

 

 

[DefaultFonts]

FONT 1 = Courier New
FONT 2 = Verdana

FONT 3 = Harlow Solid Italic

FONT 4 = Berlin Sans FB

etc.

 

Once again reiterating, only output files coming from Xplot V.7.2.1 or greater can be used for this new functionality.