feat: support a Clear command

This commit is contained in:
Raphael 'kena' Poss
2022-08-25 19:13:30 +02:00
committed by Christian Muehlhaeuser
parent 37b79f55f1
commit 6e1065830a
5 changed files with 29 additions and 0 deletions

View File

@@ -245,6 +245,14 @@ func (r *standardRenderer) repaint() {
r.lastRender = ""
}
func (r *standardRenderer) clearScreen() {
r.mtx.Lock()
defer r.mtx.Unlock()
r.out.ClearScreen()
r.out.MoveCursor(1, 1)
}
func (r *standardRenderer) altScreen() bool {
return r.altScreenActive
}