MCPcopy Create free account
hub / github.com/bpython/bpython / move_screen_up

Method move_screen_up

bpython/curtsiesfrontend/repl.py:1602–1620  ·  view source on GitHub ↗
(current_line_start_row)

Source from the content-addressed store, hash-verified

1600 # unhighlighting parens in buffer
1601
1602 def move_screen_up(current_line_start_row):
1603 # move screen back up a screen minus a line
1604 while current_line_start_row < 0:
1605 logger.debug(
1606 "scroll_offset was %s, current_line_start_row " "was %s",
1607 self.scroll_offset,
1608 current_line_start_row,
1609 )
1610 self.scroll_offset = self.scroll_offset - self.height
1611 current_line_start_row = len(self.lines_for_display) - max(
1612 -1, self.scroll_offset
1613 )
1614 logger.debug(
1615 "scroll_offset changed to %s, "
1616 "current_line_start_row changed to %s",
1617 self.scroll_offset,
1618 current_line_start_row,
1619 )
1620 return current_line_start_row
1621
1622 if self.inconsistent_history and not self.history_already_messed_up:
1623 logger.debug(INCONSISTENT_HISTORY_MSG)

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected