Add line numbers

This commit is contained in:
Zachary Yedidia
2016-03-19 09:24:04 -04:00
parent a5ddd9e521
commit 6a8b687acd
4 changed files with 47 additions and 11 deletions

View File

@@ -200,7 +200,7 @@ func (c *Cursor) Display() {
c.v.s.HideCursor()
} else {
voffset := NumOccurences(c.v.buf.lines[c.y][:c.x], '\t') * (tabSize - 1)
c.v.s.ShowCursor(c.x+voffset, c.y-c.v.topline)
c.v.s.ShowCursor(c.x+voffset+c.v.lineNumOffset, c.y-c.v.topline)
// cursorStyle := tcell.StyleDefault.Reverse(true)
// c.v.s.SetContent(c.x+voffset, c.y-c.v.topline, c.runeUnder(), nil, cursorStyle)
}