Load font from filepath



  • Hi hi!

    I want to draw text on screen but from a font that is loaded from a local path rather than being pre-installed the traditional way. The reason being there are several hundred fonts and I want to loop through them. I'm thinking something along the LoadFont method you have in Processing. Is this possible?

    Thanks,

    Luke



  • hi @lnp,

    the font() command can take a font name OR a path to a font file as argument:

    font('myFolder/myFont.ttf')
    

    cheers!



  • I should've tried that myself. Thank you!


Log in to reply