ImageFont.truetype
requires a filename to work, such as:
font = ImageFont.truetype("ariblk.ttf") # Arial Black
Is there a way with PIL
, to load a font by name, rather than filename?
Context: I would like to load a bold (with heavy weight) sans-serif font, that would work on any platform Windows, Linux, Mac.
I don't think ImageFont.truetype("ariblk.ttf")
will work cross-platform, is it possible to load it with ImageFont.truetype("Arial Black")
or, better, ImageFont.truetype("sans-serif;bold")
that would work on all platforms?