mirror of https://github.com/rivo/tview.git
TextView now reindexes only on width changes if wrapping is enabled.
This commit is contained in:
parent
1ee0c559cc
commit
6ffb56ee2a
|
@ -660,7 +660,7 @@ func (t *TextView) Draw(screen tcell.Screen) {
|
|||
t.pageSize = height
|
||||
|
||||
// If the width has changed, we need to reindex.
|
||||
if width != t.lastWidth {
|
||||
if width != t.lastWidth && t.wrap {
|
||||
t.index = nil
|
||||
}
|
||||
t.lastWidth = width
|
||||
|
|
Loading…
Reference in New Issue