converting TTF font to use in espruino

Posted on
  • the quality is poor but maybe someone will see some potential and improve upon it. https://github.com/jose1711/espruino_scripts

    also, img2espruino_font.py is basically an offline version of http://ebfc.mattbrailsford.com/ which was giving me errors for some images.

  • Great, thanks! It's really useful to be able to convert pretty much any font!

  • I was just looking into good bitmap fonts and found that Nordic SDK 15 has GFX and Font support described here and they suggest The Dot Factory generator which is really neat. Runs on Windows but thanks to it it can generate truetype fonts into C soruce code and the quality is very good - typically fonts like Tahoma include hints for (previously patented) bytecode hinting interpreter and that feature is often turned off in freetype builds on linux producing ugly fonts at small sizes.

    There are lot of settings how to generate the font into C source so e.g empty parts are removed while keeping info about each character width/height. Never heard of it before and love it.

  • That looks really cool - thanks for the link!

    For the more recent fonts I added I'd been grabbing and converting specific bitmap fonts from https://github.com/Tecate/bitmap-fonts

    For the bigger fonts working from TrueType would be great, but IMO for the smaller ones if at all possible it's probably safer to use a bitmap font that's been designed to be rendered at 1bpp

  • Post a reply
    • Bold
    • Italics
    • Link
    • Image
    • List
    • Quote
    • code
    • Preview
About

converting TTF font to use in espruino

Posted by Avatar for jose1711 @jose1711

Actions