File tree Expand file tree Collapse file tree 1 file changed +2
-0
lines changed
Expand file tree Collapse file tree 1 file changed +2
-0
lines changed Original file line number Diff line number Diff line change @@ -158,6 +158,7 @@ func (s *cursedRenderer) close() (err error) {
158158 // we're in alt screen mode or not to avoid leaving the cursor in the
159159 // middle in terminals that don't support alt screen mode.
160160 s .scr .MoveTo (0 , s .cellbuf .Height ()- 1 )
161+ _ = s .scr .Flush () // we need to flush to write the cursor movement
161162 if lv .AltScreen {
162163 enableAltScreen (s , false , true )
163164 } else {
@@ -627,6 +628,7 @@ func (s *cursedRenderer) clearScreen() {
627628}
628629
629630// enableAltScreen sets the alt screen mode.
631+ // Note that this writes to the buffer directly if write is true.
630632func enableAltScreen (s * cursedRenderer , enable bool , write bool ) {
631633 if enable {
632634 enterAltScreen (s , write )
You can’t perform that action at this time.
0 commit comments