repl.it
@pyelias/

terminal-thing

Python

No description

fork
loading
Files
  • main.py
  • thing.txt
main.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
ESCAPE = "\x1b"
CSI = f"{ESCAPE}["

def csi(cmd, *args):
  args = ";".join([str(arg) for arg in args])
  return f"{CSI}{args}{cmd}"

class Component():
  def __init__(self):
    self.new = []

class TextBox():
  def __init__(self, width, height=None):
    self.width = width
    self.height = height
    self.text = ""
  
  def set_text()
?