问题描述
我正在尝试在 python 中创建一个类似 spigot 的界面。到目前为止,这是我想出的:
from blessed import Terminal
import time
print("pre-init")
term = Terminal()
print("post-init")
line = term.get_location(timeout=5)[0]
print(term.move_xy(0,term.height - 1),end="")
while True:
time.sleep(0.2)
with term.location(0,line):
print("DATA TIIIIIME")
line+=1
此视频说明了这种方法的问题
当文本到达屏幕底部时,如何将提示保持在屏幕底部而不被覆盖?我希望它像正常的控制台输出一样向上滚动,而不是覆盖其他数据
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)