module HexaPDF::FontLoader::FromFile

This module interprets the font name as file name and tries to load it.

Public Class Methods

call(document, name, subset: true, **)

Loads the given font by interpreting the font name as file name.

The file object representing the font file is not closed and if needed must be closed by the caller once the font is not needed anymore.


The PDF document to associate the font object with.


The file name.


Specifies whether the font should be subset if possible.