mirror of
https://github.com/OpenDiablo2/OpenDiablo2
synced 2025-02-03 07:07:25 -05:00
hotfix: font table editor: added methods GetSize, and GetFrameIndex to font glyph
This commit is contained in:
parent
6a94dfcfcf
commit
1d12c2036a
@ -35,12 +35,20 @@ func (fg *fontGlyph) setHeight(h int) {
|
|||||||
fg.height = h
|
fg.height = h
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (fg *fontGlyph) GetSize() (w, h int) {
|
||||||
|
return fg.width, fg.height
|
||||||
|
}
|
||||||
|
|
||||||
|
func (fg *fontGlyph) GetFrameIndex() int {
|
||||||
|
return fg.frame
|
||||||
|
}
|
||||||
|
|
||||||
// Font represents a displayable font
|
// Font represents a displayable font
|
||||||
type Font struct {
|
type Font struct {
|
||||||
unknownHeaderBytes []byte
|
unknownHeaderBytes []byte
|
||||||
sheet d2interface.Animation
|
sheet d2interface.Animation
|
||||||
table []byte
|
table []byte
|
||||||
glyphs map[rune]*fontGlyph
|
Glyphs map[rune]*fontGlyph
|
||||||
color color.Color
|
color color.Color
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user