mirror of
https://github.com/hajimehoshi/ebiten.git
synced 2026-04-22 15:57:15 +08:00
text/v2: use font.NewFace instead of &font.Face{}
Updates go-text/typesetting#237
This commit is contained in:
@@ -160,7 +160,7 @@ func NewGoTextFaceSource(source io.Reader) (*GoTextFaceSource, error) {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
s := newGoTextFaceSource(&font.Face{Font: f})
|
||||
s := newGoTextFaceSource(font.NewFace(f))
|
||||
return s, nil
|
||||
}
|
||||
|
||||
@@ -182,7 +182,7 @@ func NewGoTextFaceSourcesFromCollection(source io.Reader) ([]*GoTextFaceSource,
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
s := newGoTextFaceSource(&font.Face{Font: f})
|
||||
s := newGoTextFaceSource(font.NewFace(f))
|
||||
sources[i] = s
|
||||
}
|
||||
return sources, nil
|
||||
|
||||
Reference in New Issue
Block a user