Previous Page | Next Page

The FONTREG Procedure

Concepts: FONTREG Procedure


Supported Font Types and Font Naming Conventions

When a font is added to the SAS registry, the font name is prefixed with a three-character tag, enclosed in angle brackets (< >), that indicates the font type. For example, if you add the TrueType font Arial to the SAS registry, then the name in the registry is <ttf> Arial. This naming convention enables you to add and distinguish between fonts that have the same name but are of different types. When you specify a font in a SAS program (for example, in the TEMPLATE procedure or in the STYLE= option in the REPORT procedure), use the tag to distinguish between fonts that have the same name:

proc report data=grocery nowd
            style(header)=[font_face='<ttf> Palatino Linotype'];
run;

If you do not include a tag in your font specification, then SAS searches the registry for fonts with that name. If more than one font with that name is found, then SAS uses the font that has the highest rank in the following table.

Supported Font Types
Rank Type Tag File extension(s)
1 TrueType <ttf>
.ttf
2 Type1 <at1>
.pfa

.pfb

Note:   SAS does not support any type of nonscalable fonts that require Free-Type font-rendering. Even if they are recognized as valid fonts, they will not be added to the SAS registry.  [cautionend]

Font files that are not produced by major vendors can be unreliable, and in some cases SAS might not be able to use them.

The following SAS output methods and device drivers can use FreeType font-rendering:


Removing Fonts from the SAS Registry

You can remove a font from the SAS registry in the following ways:

To remove a font by using the SAS Registry Editor, select Solutions [arrow] Accessories [arrow] Registry Editor. Alternatively, you can type regedit in the command window or Command ===> prompt.

SAS Registry Editor

[SAS Registry Editor]

In the left pane of the Registry Editor window, navigate to the [CORE\PRINTING\FREETYPE\FONTS] key. Select the font that you want to delete, and use one of these methods to delete it:

To delete a font by using PROC REGISTRY, submit a program similar to the following example. This example removes the <ttf> Arial font.

/* Write the key name for the font to an external file */
proc registry export='external-filename'
              startat='core\printing\freetype\fonts\<ttf> Arial';
run;

/* Remove the "<ttf> Arial" font from the SAS registry */
proc registry uninstall='external-filename' fullstatus;
run;

To delete a font by using the REMOVE statement in PROC FONTREG, see the REMOVE Statement.

For more information about PROC REGISTRY, see The REGISTRY Procedure.


Font Aliases and Locales

The FONTFILE, FONTPATH, and TRUETYPE statements support aliases and locales. If the font being processed contains a localized name in the same locale as the current SAS session, then an alias of that localized name will be added to the SAS registry to reference the font family.

Previous Page | Next Page | Top of Page