Procedure features: FONTFILE statement
This example shows how to add a single font file to the SAS registry.
Specify a font file to add. The FONTFILE statement specifies the complete path to a single font file.
proc fontreg; fontfile ' your-font-file '; run;
NOTE: PROCEDURE PRINTTO used (Total process time): real time 0.03 seconds cpu time 0.00 seconds 20 proc fontreg; 21 fontfile your-font-file ; 22 run; SUMMARY: Files processed: 1 Unusable files: 0 Files identified as fonts: 1 Fonts that were processed: 1 Fonts replaced in the SAS registry: 0 Fonts added to the SAS registry: 1 Fonts that could not be used: 0 NOTE: PROCEDURE FONTREG used (Total process time): real time 0.17 seconds cpu time 0.03 seconds
Procedure features:
MSGLEVEL= option
FONTPATH statement
This example shows how to add all valid font files from two different directories and how to write detailed information to the SAS log.
Write complete details to the SAS log. The MSGLEVEL=VERBOSE option writes complete details about what fonts were added, what fonts were not added, and what font files were not understood .
proc fontreg msglevel=verbose;
Specify the directories to search for valid fonts. You can specify more than one directory in the FONTPATH statement. Each directory must be enclosed in quotation marks. If you specify more than one directory, then you must separate the directories with a space.
fontpath ' your-font-directory-1 '' your-font-directory-2 '; run;
NOTE: PROCEDURE PRINTTO used (Total process time): real time 0.03 seconds cpu time 0.00 seconds 34 proc fontreg msglevel=verbose; 35 fontpath ' your-font-directory-1 ' 36 ' your-font-directory-2 '; 37 run; ERROR: FreeType base module FT_New_Face -- unknown file format. WARNING: A problem was encountered with file your-font-directory-2 \SCRIPT.FON. NOTE: The font Albertus Extra Bold (Style: Regular, Weight: Bold) has been added to the SAS Registry at [CORE\PRINTING\FREETYPE\FONTS\<ttf> Albertus Extra Bold]. Since it is a TRUETYPE font, it must be referenced as <ttf> Albertus Extra Bold in SAS. The font resides in file your-font-directory-1 \albr85w.ttf. . . . more log entries . . . SUMMARY: Files processed: 138 Unusable files: 4 Files identified as fonts: 134 Fonts that were processed: 134 Fonts replaced in the SAS registry: 0 Fonts added to the SAS registry: 127 Fonts that could not be used: 7 NOTE: PROCEDURE FONTREG used (Total process time): real time 7.11 seconds cpu time 3.80 seconds
Procedure features:
MODE= option
TRUETYPE statement
This example reads all the TrueType Fonts in the specified directory and replaces those that already exist in the SAS registry.
Replace existing fonts only. The MODE=REPLACE option limits the action of the procedure to replacing fonts that are already defined in the SAS registry. New fonts will not be added.
proc fontreg mode=replace;
Specify a directory that contains TrueType font files. Files in the directory that are not recognized as being TrueType font files are ignored.
truetype ' your-font-directory '; run;
53 proc fontreg mode=replace; 54 truetype ' your-font-directory '; 55 run; SUMMARY: Files processed: 49 Unusable files: 4 Files identified as fonts: 45 Fonts that were processed: 39 Fonts replaced in the SAS registry: 39 Fonts added to the SAS registry: 0 Fonts that could not be used: 0 NOTE: PROCEDURE FONTREG used (Total process time): real time 1.39 seconds cpu time 0.63 seconds