Documentation ¶
Index ¶
- Variables
- type FontMaker
- func (me *FontMaker) FileSize(path string) (int64, error)
- func (me *FontMaker) GetInfoFromTrueType(fontpath string, fontmaps []FontMap) (TtfInfo, error)
- func (me *FontMaker) GetResults() []string
- func (me *FontMaker) GoStructName(name string) string
- func (me *FontMaker) LoadMap(encodingpath string) ([]FontMap, error)
- func (me *FontMaker) MakeDefinitionFile(gofontname string, mappath string, exportfile string, encode string, ...) (string, error)
- func (me *FontMaker) MakeFont(fontpath string, mappath string, encode string, outfolderpath string) error
- func (me *FontMaker) MakeFontDescriptor(info TtfInfo) (string, error)
- func (me *FontMaker) MakeFontEncoding(mappath string, fontmaps []FontMap) (string, error)
- func (me *FontMaker) MakeWidthArray(widths map[int]int64) (string, error)
- func (me *FontMaker) MultiplyAndRound(k float64, v int64) int64
- func (me *FontMaker) MultiplyAndRoundWithUInt64(k float64, v uint64) int64
- func (me *FontMaker) Round(value float64) int64
- type FontMap
- type TTFParser
- func (me *TTFParser) ArrayPadUint(arr []uint64, size uint64, val uint64) ([]uint64, error)
- func (me *TTFParser) BytesToString(b []byte) string
- func (me *TTFParser) CompareBytes(a []byte, b []byte) bool
- func (me *TTFParser) FTell(fd *os.File) (uint64, error)
- func (me *TTFParser) Parse(fontpath string) error
- func (me *TTFParser) ParseCmap(fd *os.File) error
- func (me *TTFParser) ParseHead(fd *os.File) error
- func (me *TTFParser) ParseHhea(fd *os.File) error
- func (me *TTFParser) ParseHmtx(fd *os.File) error
- func (me *TTFParser) ParseMaxp(fd *os.File) error
- func (me *TTFParser) ParseName(fd *os.File) error
- func (me *TTFParser) ParseOS2(fd *os.File) error
- func (me *TTFParser) ParsePost(fd *os.File) error
- func (me *TTFParser) PregReplace(pattern string, replacement string, subject string) (string, error)
- func (me *TTFParser) Read(fd *os.File, length int) ([]byte, error)
- func (me *TTFParser) ReadShort(fd *os.File) (int64, error)
- func (me *TTFParser) ReadULong(fd *os.File) (uint64, error)
- func (me *TTFParser) ReadUShort(fd *os.File) (uint64, error)
- func (me *TTFParser) Seek(fd *os.File, tag string) error
- func (me *TTFParser) Skip(fd *os.File, length int64) error
- type TtfInfo
- func (me TtfInfo) GetBool(key string) (bool, error)
- func (me TtfInfo) GetInt64(key string) (int64, error)
- func (me TtfInfo) GetInt64s(key string) ([]int64, error)
- func (me TtfInfo) GetMapIntInt64(key string) (map[int]int64, error)
- func (me TtfInfo) GetString(key string) (string, error)
- func (me TtfInfo) PushBool(key string, val bool)
- func (me TtfInfo) PushBytes(key string, val []byte)
- func (me TtfInfo) PushInt64(key string, val int64)
- func (me TtfInfo) PushInt64s(key string, val []int64)
- func (me TtfInfo) PushMapIntInt64(key string, val map[int]int64)
- func (me TtfInfo) PushString(key string, val string)
- func (me TtfInfo) PushUInt64(key string, val uint64)
Constants ¶
This section is empty.
Variables ¶
View Source
var ERROR_FONT_LICENSE_DOES_NOT_ALLOW_EMBEDDING = errors.New("Font license does not allow embedding")
View Source
var ERROR_INCORRECT_MAGIC_NUMBER = errors.New("Incorrect magic number")
View Source
var ERROR_NO_GET_WRONG_TYPE = errors.New("get wrong type")
View Source
var ERROR_NO_KEY_FOUND = errors.New("no key found")
View Source
var ERROR_NO_UNICODE_ENCODING_FOUND = errors.New("No Unicode encoding found")
View Source
var ERROR_POSTSCRIPT_NAME_NOT_FOUND = errors.New("PostScript name not found")
View Source
var ERROR_UNEXPECTED_SUBTABLE_FORMAT = errors.New("Unexpected subtable format")
Functions ¶
This section is empty.
Types ¶
type FontMaker ¶
type FontMaker struct {
// contains filtered or unexported fields
}
func NewFontMaker ¶
func NewFontMaker() *FontMaker
func (*FontMaker) GetInfoFromTrueType ¶
func (*FontMaker) GetResults ¶
func (*FontMaker) GoStructName ¶
func (*FontMaker) MakeDefinitionFile ¶
func (*FontMaker) MakeFontDescriptor ¶
func (*FontMaker) MakeFontEncoding ¶
func (*FontMaker) MakeWidthArray ¶
func (*FontMaker) MultiplyAndRound ¶
func (*FontMaker) MultiplyAndRoundWithUInt64 ¶
type TTFParser ¶
func (*TTFParser) ArrayPadUint ¶
func (*TTFParser) BytesToString ¶
func (*TTFParser) PregReplace ¶
type TtfInfo ¶
type TtfInfo map[string]interface{}
func NewTtfInfo ¶
func NewTtfInfo() TtfInfo
func (TtfInfo) PushInt64s ¶
func (TtfInfo) PushString ¶
func (TtfInfo) PushUInt64 ¶
Click to show internal directories.
Click to hide internal directories.