The SAS Output Delivery System and reporting techniques

ODS PDF in Calibri Font

Reply
N/A
Posts: 1

ODS PDF in Calibri Font

Hi,

I am generating a PDF output using ODS PDF.I need the PDF output in calibri Font. I have researched on the Google but have not come across a solution for this. Can you please help me out.

Thanks

Hoor

SAS Super FREQ
Posts: 8,862

Re: ODS PDF in Calibri Font

Hi:

  This is an old posting on a different forum, but it was just one of many I found that indicated Adobe might have some issues using Calibri: http://forums.arcgis.com/threads/17743-Calibri-Font-issues-in-PDF-after-ArcMap-Export

  However, if you want to use Calibri and are using PROC REPORT (or PROC PRINT or PROC TABULATE), you can use STYLE= overrides as shown in the program below for PROC REPORT. Otherwise, if you look on support.sas.com, your other alternative is to use a style template change to modify the font list used by the ODS style template, as described here:

http://support.sas.com/kb/24/217.html (instead of the REPLACE statement, use the STYLE statement if using SAS 9.2 or higher)

http://support.sas.com/kb/24/493.html (again, use STYLE instead of REPLACE if 9.2 or higher)

http://support.sas.com/kb/24/321.html (how to embed fonts in PDF shows Verdana)

cynthia

ods _all_ close;
options nodate nonumber;

 

ods pdf file='c:\temp\use_calibri1.pdf';

proc report data=sashelp.shoes nowd
     style(header)={font_face='Calibri' font_size=12pt}
     style(column)={font_face='Calibri' font_size=12pt};
  where region contains 'Europe';
  title f='Calibri' h=14pt '1) My Calibri Title';
  column region product sales inventory;
  define region / group;
  define product / group;
  break after region/summarize;
run;
ods pdf close;

N/A
Posts: 1

Re: ODS PDF in Calibri Font

Posted in reply to Cynthia_sas

Hi cynthia,

I have run the above code and got warning message but Output file seem to be in Calibri font.

"WARNING: Font specification "Calibri" failed. Using default font family instead."

Can you please help me to sort out this warning?

Thanks and Regards,

Kamalakar

SAS Super FREQ
Posts: 708

Re: ODS PDF in Calibri Font

hi Kamalakar

this message indicates, that the font was not found in the SAS registry. To see which fonts are defined in the SAS registry, you can use the following code:

proc registry
 
startat="\CORE\PRINTING\FREETYPE\FONTS"
 
list
;
run;

Then check the log. All the fonts that are on your system are usually registered during the install process of SAS.

However you can register fonts later using Proc FONTREG, see sample below

proc fontreg
 
mode=add
 
msglevel=normal
 
usesashelp
;
  truetype "c:\windows\fonts";
run;

Please also check the documention for Proc REGISTRY and Proc FONTREG for more information.

Bruno

Ask a Question
Discussion stats
  • 3 replies
  • 1703 views
  • 0 likes
  • 4 in conversation