Do not send history buf in alternate screen mode

This commit is contained in:
Kovid Goyal
2018-02-14 20:46:12 +05:30
parent 9c21610215
commit 807c8f9005
2 changed files with 8 additions and 1 deletions

View File

@@ -318,7 +318,7 @@ class Window:
def as_text(self, as_ansi=False, add_history=False):
lines = []
self.screen.as_text(lines.append, as_ansi)
if add_history:
if add_history and not self.screen.is_using_alternate_linebuf():
h = []
self.screen.historybuf.as_text(h.append, as_ansi)
lines = h + lines