Compare commits
1 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
7b536a7efa |
@@ -141,6 +141,11 @@ def run_case(char_by_char):
|
|||||||
assert len(screen.history) == 1, (tag, len(screen.history))
|
assert len(screen.history) == 1, (tag, len(screen.history))
|
||||||
assert screen.history[0][0].data == "a", tag
|
assert screen.history[0][0].data == "a", tag
|
||||||
|
|
||||||
|
# an explicit full-screen scroll region still feeds scrollback
|
||||||
|
proc, screen, stream = make(10, 3)
|
||||||
|
feed(stream, "\x1b[1;3ra\r\nb\r\nc\r\nd", char_by_char)
|
||||||
|
assert len(screen.history) == 1, (tag, len(screen.history))
|
||||||
|
|
||||||
# ED 3 clears history and fires callback
|
# ED 3 clears history and fires callback
|
||||||
cleared = []
|
cleared = []
|
||||||
proc = FakeProcess()
|
proc = FakeProcess()
|
||||||
|
|||||||
@@ -442,7 +442,9 @@ class VtScreen(pyte.Screen):
|
|||||||
|
|
||||||
def index(self):
|
def index(self):
|
||||||
"""Line feed; at the bottom of the primary screen the top row goes to scrollback."""
|
"""Line feed; at the bottom of the primary screen the top row goes to scrollback."""
|
||||||
if not self.alternate_buffer_mode and self.cursor.y == self.lines - 1 and self.margins is None:
|
# a region spanning the whole screen (CSI 1;<lines> r) is no region
|
||||||
|
full = self.margins is None or self.margins == (0, self.lines - 1)
|
||||||
|
if not self.alternate_buffer_mode and self.cursor.y == self.lines - 1 and full:
|
||||||
self.push_lines_into_history(1)
|
self.push_lines_into_history(1)
|
||||||
super().index()
|
super().index()
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user