font

package
v0.0.0-...-e9d5adc Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 16, 2022 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Data

type Data struct {
	CharWidth  int
	CharHeight int
	XOffset    int
	YOffset    int
	Glyphs     map[uint32]*Glyph
}

func GetFontByName

func GetFontByName(name string) *Data

func (*Data) GetGlyph

func (d *Data) GetGlyph(unicode uint32) *Glyph

type Glyph

type Glyph struct {
	Name string
	Data [][]byte
}

func (*Glyph) DrawAt

func (g *Glyph) DrawAt(x, y int, c color.RGBA, pixels []byte, imgWidth int)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL