X-Git-Url: http://git.iain.cx/?a=blobdiff_plain;f=screen%2Fscreen.go;h=4d40793d3404d827d20571d2f8cdcbb660988464;hb=HEAD;hp=251ca8778824cda9ca3f7c045f913002eb62b517;hpb=e5c137e9e63fff4093a152ade0eb105ba43237b2;p=pstop.git diff --git a/screen/screen.go b/screen/screen.go index 251ca87..4d40793 100644 --- a/screen/screen.go +++ b/screen/screen.go @@ -98,6 +98,14 @@ func (s *TermboxScreen) PrintAt(x int, y int, text string) { s.Flush() } +// Clear EOL +func (s *TermboxScreen) ClearLine(x int, y int) { + for i := x; i < s.width; i++ { + termbox.SetCell(i, y, ' ', termbox.ColorDefault, termbox.ColorDefault) + } + s.Flush() +} + // set the screen size func (s *TermboxScreen) SetSize(width, height int) { // if we get bigger then clear out the bottom line