Fix stringwidth build

This commit is contained in:
Zachary Yedidia
2017-02-03 07:32:48 -05:00
parent c3a165e61d
commit 28af256be0

View File

@@ -174,7 +174,7 @@ func StringWidth(str string, tabsize int) int {
switch ch {
case '\t':
ts := tabsize - (lineIdx % tabsize)
sw += ts - 1
sw += ts
lineIdx += ts
case '\n':
lineIdx = 0