Пример #1
0
def step_impl(ctx, key):
    mappings = {
        "enter": b"\x0a",
        "up":    b"\x1b[A",
        "down":  b"\x1b[B",
        "right": b"\x1b[C",
        "left":  b"\x1b[D",
        "esc":   b"\x1b",
        "c-c":   b"\x03",
        "c-d":   b"\x04",
        "c-p":   b"\x10",
        "c-q":   b"\x11",
    }
    util.write(ctx.pty, mappings[key.lower()])
Пример #2
0
def step_impl(ctx, key):
    mappings = {
        "enter": b"\x0a",
        "up": b"\x1b[A",
        "down": b"\x1b[B",
        "right": b"\x1b[C",
        "left": b"\x1b[D",
        "esc": b"\x1b",
        "c-c": b"\x03",
        "c-d": b"\x04",
        "c-p": b"\x10",
        "c-q": b"\x11",
    }
    util.write(ctx.pty, mappings[key.lower()])
Пример #3
0
def step_impl(ctx, text):
    util.write(ctx.pty, text.encode())
Пример #4
0
def step_impl(ctx, text):
    util.write(ctx.pty, text.encode())
Пример #5
0
def step_impl(ctx, text):
    util.write(ctx.pty, text)
Пример #6
0
def step_impl(ctx, text):
    util.write(ctx.pty, text)