Module for font rendering. Unicode is supported, but only left to right.
Filtering constants
type Filter* = enum {
nearest = 0
linear = 1
}
opaque Font
type Font* = struct { _: ^struct{} }
fn load
fn load*(path: str, size: th::fu, filter: Filter = Filter.linear): (Font, std::Err) {
fn Font.validate
fn (f: ^Font) validate*(): bool {
fn Font.draw
fn (f: ^Font) draw*(text: str, pos: th::Vf2, color: uint32, scale: th::fu = 1.0) {
fn Font.measure
fn (f: ^Font) measure*(text: str): th::Vf2 {