AddTrueTypeCollectionFontFromFile
Page manipulation
Description
Embeds one face of a TrueType collection from a raw TTC, WOFF 1.0 or WOFF2 container
Syntax
Delphi
Function AddTrueTypeCollectionFontFromFile(Const FileName: WideString; FaceIndex: Integer): Integer;Parameters
| FileName | Path to a raw or web-font collection |
|---|---|
| FaceIndex | 0-based face inside the collection |
Return value
The font id, or 0 when the file cannot be read or the index is negative
Remarks
FaceIndex zero keeps the historical first-face behaviour of AddTrueTypeFontFromFile; an index past the last face falls back to the last face. WOFF2 input requires Windows 10 version 1703 or later