PDFium Delphi Component Docs

TryGetPdfDefaultTtfMapEntry function

Unit: PDFium
Reads one character-set and font-name pair from the PDFium default TrueType font map

Syntax

function TryGetPdfDefaultTtfMapEntry(Index: NativeUInt;
  out Entry: TPdfDefaultTtfMapEntry): Boolean;

Parameters

IndexNativeUInt
EntryTPdfDefaultTtfMapEntry

Return Value

Boolean

Description

TryGetPdfDefaultTtfMapEntry loads the selected PDFium module when necessary and reads the map entry at the zero-based Index through the native FPDF_GetDefaultTTFMapEntry export

On success Entry carries the Charset integer and the FontName string of the pair; on failure Entry is left at its default value

The function returns False when Index is at or beyond the count reported by PdfDefaultTtfMapCount or when the native entry pointer is nil

FontName stays empty when the native fontname pointer is nil even though the entry itself was returned

Remarks

Example

if TryGetPdfDefaultTtfMapEntry(0, Entry) then
  ShowMessage(Format('Charset %d: %s', [Entry.Charset, Entry.FontName]));

See Also

PdfDefaultTtfMapCount, ConfigureSystemFontProvider