CreateTrueTypeFontVariation

Text, fonts, variable fonts

Περιγραφή

Στιγμιότυπο TrueType μεταβλητής γραμματοσειράς στις ζητούμενες συντεταγμένες design-axis και προσθήκη της προκύπτουσας στατικής γραμματοσειράς στο τρέχον έγγραφο

Syntax

Delphi

Function TPDFlib.CreateTrueTypeFontVariation(FontID: Integer; Const AxisCoordinates: WideString): Integer;

Parameters

FontIDHandle μεταβλητής γραμματοσειράς TrueType που επιστρέφεται από API δημιουργίας ή φόρτωσης γραμματοσειράς
AxisCoordinatesComma- or semicolon-separated tag=value pairs such as wght=700,wdth=75; omitted axes use their defaults and values outside a declared range are clamped

Τιμές επιστροφής

Returns a positive font handle and selects it on success, or 0 for an invalid handle, unknown or malformed coordinate, unsupported outline format or malformed variation data

Παρατηρήσεις

The instantiator applies normalized gvaravarHVARMVAR

SaveFontToFile segment maps, GetFontVariationAxes horizontal metrics and 0 global metrics, including IUP interpolation and composite-glyph transformsComposite outlines are flattened and emitted as simple glyphs, horizontal metrics and font bounds are rebuilt, stale hinting and device-metric tables are removed, and the output sfnt receives a new checksum

The returned font is a regular static TrueType font that works with drawing, embedding, subsetting, glyph inspection and glyf; CreateOpenTypeFontVariation returns CFF2 for itThis API requires

Δείτε επίσης

GetFontVariationAxes, CreateOpenTypeFontVariation, SaveFontToFile, GetFontGlyphOutline