fix tab character when printing

cc #496
This commit is contained in:
Gokcehan 2021-01-18 21:27:34 +03:00
parent d6c5590ad0
commit 2af2c6de31

2
ui.go
View File

@ -211,7 +211,7 @@ func (win *win) print(screen tcell.Screen, x, y int, st tcell.Style, s string) t
for { for {
rc, wc := utf8.DecodeRuneInString(s[i+w:]) rc, wc := utf8.DecodeRuneInString(s[i+w:])
if rc == gEscapeCode || runewidth.RuneWidth(rc) != 0 { if rc == gEscapeCode || rc == '\t' || runewidth.RuneWidth(rc) != 0 {
break break
} }
comb = append(comb, rc) comb = append(comb, rc)