mirror of
https://github.com/hajimehoshi/ebiten.git
synced 2024-11-10 04:57:26 +01:00
parent
2e363cc19b
commit
f0396ba915
@ -190,14 +190,8 @@ func (g *GoTextFaceSource) shape(text string, face *GoTextFace) ([]shaping.Outpu
|
||||
Language: language.Language(face.Language.String()),
|
||||
}
|
||||
|
||||
var inputs []shaping.Input
|
||||
if face.Direction.isHorizontal() {
|
||||
// shaping.Segmenter is not used for horizontal texts so far due to a bug (go-text/typesetting#127).
|
||||
inputs = []shaping.Input{input}
|
||||
} else {
|
||||
var seg shaping.Segmenter
|
||||
inputs = seg.Split(input, &singleFontmap{face: face.Source.f})
|
||||
}
|
||||
inputs := seg.Split(input, &singleFontmap{face: face.Source.f})
|
||||
|
||||
if face.Direction == DirectionRightToLeft {
|
||||
// Reverse the input for RTL texts.
|
||||
|
Loading…
Reference in New Issue
Block a user