FPDFText_LoadStandardFont function

  1. @Native<FPDF_FONT Function(FPDF_DOCUMENT document, FPDF_BYTESTRING font)>(FPDF_DOCUMENT, FPDF_BYTESTRING)>()
FPDF_FONT FPDFText_LoadStandardFont(
  1. FPDF_DOCUMENT document,
  2. FPDF_BYTESTRING font
)

Experimental API. Loads one of the standard 14 fonts per PDF spec 1.7 page 416. The preferred way of using font style is using a dash to separate the name from the style, for example 'Helvetica-BoldItalic'.

document - handle to the document. font - string containing the font name, without spaces.

The loaded font can be closed using FPDFFont_Close().

Returns NULL on failure.

Implementation

@ffi.Native<FPDF_FONT Function(FPDF_DOCUMENT, FPDF_BYTESTRING)>()
external FPDF_FONT FPDFText_LoadStandardFont(
  FPDF_DOCUMENT document,
  FPDF_BYTESTRING font,
);