amanoese / tinyfont

Text library for TinyGo displays

Home Page:https://tinygo.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

TinyFont

CircleCI

TinyFont is a font/text package for TinyGo displays. It is heavily based on Adafruit's GFX library.

example

This package is experimental and may change in the future. It has not been optimized for speed or memory..

Faster compilation

During compilation, tinygo will go through all the font files in a package and them discard them if not used. To improve compilation time considerably, move the files you are going to use to a new package.

About the fonts

The fonts compiled here were just converted or made compatible, and the original authors should be given proper credit. Each font is under its own license, and while most of them are under an open license, there might be differences in its usage and conditions.

Generate your own font

You can use tinyfontgen to generate a tinyfont from a bdf font.

https://github.com/tinygo-org/tinyfont/tree/rune/cmd/tinyfontgen

Incompatibility warning

This package contains incompatible changes from previous versions.

  • The argument has been changed from []byte to string.
    • You can simply add a string() cast.
  • The Font struct has been changed.
    • If you are creating your own fonts, you need to modify them.
    • You may find this script helpful for font conversion.

License

This project is licensed under the BSD 3-clause license, just like the Go project itself.

About

Text library for TinyGo displays

https://tinygo.org

License:BSD 3-Clause "New" or "Revised" License


Languages

Language:Go 99.9%Language:Makefile 0.1%