Fix rare problem with tabs and horizontal scrolling

This commit is contained in:
Zachary Yedidia
2017-05-05 11:34:14 -04:00
parent a6ee75a9cf
commit 57110c98e4

View File

@@ -38,7 +38,7 @@ func visualToCharPos(visualIndex int, lineN int, str string, buf *Buffer, tabsiz
lastWidth = width
rw = 0
if c == '\t' {
rw := tabsize - (lineIdx % tabsize)
rw = tabsize - (lineIdx % tabsize)
width += rw
} else {
rw = runewidth.RuneWidth(c)