diff options
author | Christopher Speller <crspeller@gmail.com> | 2017-02-02 09:32:00 -0500 |
---|---|---|
committer | Harrison Healey <harrisonmhealey@gmail.com> | 2017-02-02 09:32:00 -0500 |
commit | 701d1ab638b23c24877fc41824add66232446676 (patch) | |
tree | ec120c88d38ac9d38d9eabdd3270b52bb6ac9d96 /vendor/github.com/golang/freetype/truetype/glyph.go | |
parent | ca3211bc04f6dea34e8168217182637d1419f998 (diff) | |
download | chat-701d1ab638b23c24877fc41824add66232446676.tar.gz chat-701d1ab638b23c24877fc41824add66232446676.tar.bz2 chat-701d1ab638b23c24877fc41824add66232446676.zip |
Updating server dependancies (#5249)
Diffstat (limited to 'vendor/github.com/golang/freetype/truetype/glyph.go')
-rw-r--r-- | vendor/github.com/golang/freetype/truetype/glyph.go | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/vendor/github.com/golang/freetype/truetype/glyph.go b/vendor/github.com/golang/freetype/truetype/glyph.go index c2935a58e..6157ad83e 100644 --- a/vendor/github.com/golang/freetype/truetype/glyph.go +++ b/vendor/github.com/golang/freetype/truetype/glyph.go @@ -209,6 +209,7 @@ func (g *GlyphBuf) load(recursion uint32, i Index, useMyMetrics bool) (err error g.addPhantomsAndScale(len(g.Points), len(g.Points), true, true) copy(g.phantomPoints[:], g.Points[len(g.Points)-4:]) g.Points = g.Points[:len(g.Points)-4] + // TODO: also trim g.InFontUnits and g.Unhinted? return nil } @@ -282,6 +283,10 @@ func (g *GlyphBuf) loadSimple(glyf []byte, ne int) (program []byte) { program = glyf[offset : offset+instrLen] offset += instrLen + if ne == 0 { + return program + } + np0 := len(g.Points) np1 := np0 + int(g.Ends[len(g.Ends)-1]) |