<< Click to Display Table of Contents >> VpeSetFontControl |
![]() ![]() ![]() |
[VPE Professional Edition and above]
Allows to set several parameters for an individual font. This function overrides the settings of VpeSetEmbedAllFonts() and VpeSetSubsetAllFonts().
void VpeSetFontControl(
VpeHandle hDoc,
LPCSTR font_name,
LPCSTR subst_font_name,
int do_embed,
int do_subset
)
VpeHandle hDoc
Document Handle
LPCSTR font_name
the font you want to set the parameters for
LPCSTR subst_font_name
the font with which you want to substitute the original font with
int do_embed
Value |
Description |
True |
if the font is a True-Type font, it will be embedded into the document |
False |
the font will not be embedded into the document |
int do_subset
Value |
Description |
True |
if the font is a True-Type font, and it is embedded, it will be subsetted |
False |
the font will not be subsetted |
Remarks:
You can call this method repeatedly for each font you want to set individual parameters for. The settings can be deleted by calling the method VpeResetFontControl().
Whilst the settings for font substitution of this method are only active during the export to PDF documents, there is a second method to substitute fonts VpeSetFontSubstitution(), which is always active.
For important details about fonts and font handling, please see the Programmer's Manual, chapter "Programming Techniques", subchapter "Fonts and Font Handling".
Example:
VpeSetFontControl(hDoc, "Arial", "Helvetica", FALSE, FALSE);
VpeSetFontControl(hDoc, "Times New Roman", "Times", FALSE, FALSE);
Instructs VPE to substitute "Arial" with "Helvetica" and "Times New Roman" with "Times".
Since Helvetica as well as Times are PostScript fonts, VPE can neither embed nor subset them. But because both fonts are standard Base 14 PostScript fonts, they are supported by PDF Readers on any platform, so embedding (and therefore subsetting) is not required.