Enha: explicit app.Draw per textView update for smooth streaming
This commit is contained in:
5
tui.go
5
tui.go
@@ -324,8 +324,11 @@ func init() {
|
|||||||
SetDynamicColors(true).
|
SetDynamicColors(true).
|
||||||
SetRegions(true).
|
SetRegions(true).
|
||||||
SetChangedFunc(func() {
|
SetChangedFunc(func() {
|
||||||
|
// INFO:
|
||||||
// https://github.com/rivo/tview/wiki/Concurrency#event-handlers
|
// https://github.com/rivo/tview/wiki/Concurrency#event-handlers
|
||||||
// app.Draw() // already called by default per tview specs
|
// although already called by default per tview specs
|
||||||
|
// calling it explicitly makes text streaming to look more smooth
|
||||||
|
app.Draw()
|
||||||
})
|
})
|
||||||
notificationWidget = tview.NewTextView().
|
notificationWidget = tview.NewTextView().
|
||||||
SetTextAlign(tview.AlignCenter).
|
SetTextAlign(tview.AlignCenter).
|
||||||
|
|||||||
Reference in New Issue
Block a user