True) or merely referenced and resolved at view time from the operating system (False).property FontIsEmbedded[Index: Integer]: Boolean; // read only
FontIsEmbedded reports whether the font referenced by the text page object at the given index carries its actual glyph program inside the PDF file. An embedded font travels with the document and renders identically on any platform; a non-embedded (referenced-only) font relies on the viewer finding a font of the same name installed locally, and may be substituted on display.
The indexer is the 0-based page-object index (0..ObjectCount - 1). Non-text objects always return False. A page must be active before reading the property.
Embedding can be full (every glyph from the source font is present) or subset (only the glyphs actually used appear, with a six-letter prefix added to the base name); both forms count as embedded here. For PDF/A compliance every font must be embedded — this property is a quick auditing tool for that requirement.
| Index | 0-based page-object index in the range 0..ObjectCount - 1. |
True return does not say whether the embedding is full or subset — inspect FontBaseName for a ABCDEF+ prefix to detect a subset.FontData only returns data when the font is embedded.False.var
I, EmbeddedCount, TextCount: Integer;
begin
Pdf1.PageNumber := 1;
EmbeddedCount := 0;
TextCount := 0;
for I := 0 to Pdf1.ObjectCount - 1 do
if Pdf1.ObjectType[I] = otText then
begin
Inc(TextCount);
if Pdf1.FontIsEmbedded[I] then Inc(EmbeddedCount);
end;
ShowMessage(Format('%d of %d text objects use embedded fonts',
[EmbeddedCount, TextCount]));
end;