THPDFPage.GetWideCharAdvances Method

Version 2.1102.0 adds ordinary native CFF2 text and portable CFF1 font embedding. Registered names select the frozen font bytes directly; cmap and hmtx supply glyphs and metrics, with per-font BMP/SMP mappings and a CIDFontType0C stream retaining all original glyph slots

Measures a Unicode string in the current font: TotalWidth receives its width and Advances the advance of each character, in the page units of THotPDF.Resolution (1/Resolution inch), the same units as the drawing coordinates

Declaration

function GetWideCharAdvances(const Text: WideString; out TotalWidth: Single; out Advances: array of Single): boolean;

Unit

HPDFDoc

Parameters

NamePurpose
TextInput used by GetWideCharAdvances
TotalWidthInput used by GetWideCharAdvances
AdvancesInput used by GetWideCharAdvances

Return value

Returns True when the text could be measured

Usage notes

Related APIs