~sbinet/star-tex

07784b723473e269417134b56617a233efa6dc2d — Sebastien Binet 4 months ago 7e43f74
tfm: export Font.Checksum method

Signed-off-by: Sebastien Binet <s@sbinet.org>
1 files changed, 5 insertions(+), 0 deletions(-)

M font/tfm/font.go
M font/tfm/font.go => font/tfm/font.go +5 -0
@@ 85,6 85,11 @@ func (fnt *Font) Name() string {
	return fnt.body.header.fontID
}

// Checksum returns the checksum of the TeX font metrics file.
func (fnt *Font) Checksum() uint32 {
	return fnt.body.header.chksum
}

// NumGlyphs returns the number of glyphs in this font.
func (fnt *Font) NumGlyphs() int {
	return int(fnt.hdr.ec) + 1 - int(fnt.hdr.bc)