Defined in pyglet.resource
Add a font resource to the application.
Fonts not installed on the system must be added to pyglet before they can be used with font.load. Although the font is added with its filename using this function, it is loaded by specifying its family name. For example:
resource.add_font('action_man.ttf')
action_man = font.load('Action Man')
Parameters: | name (str) – Filename of the font resource to add. |
---|