Skip to content

Instantly share code, notes, and snippets.

@jaraco
Created August 1, 2023 20:42
Show Gist options
  • Save jaraco/1f44ee3b00d57c2f86fd999201db9bcb to your computer and use it in GitHub Desktop.
Save jaraco/1f44ee3b00d57c2f86fd999201db9bcb to your computer and use it in GitHub Desktop.
#!python3
import curses
import time
screen = curses.initscr()
screen.clear()
pad = curses.newpad(100, 100)
for line in range(1, 100):
pad.addstr(line - 1, 0, f'line {line}')
screen.setscrreg(1, 19)
pad.refresh(5, 0, 2, 0, 19, 100)
time.sleep(2)
pad.refresh(10, 0, 2, 0, 19, 100)
time.sleep(2)
curses.endwin()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment