ctlseqs: add initial ctlseqs

Signed-off-by: Tim Culverhouse <tim@timculverhouse.com>
This commit is contained in:
Tim Culverhouse 2024-01-19 10:41:22 -06:00
parent 74d55aaa19
commit 76b2bf7bbc
2 changed files with 17 additions and 0 deletions

16
src/ctlseqs.zig Normal file
View file

@ -0,0 +1,16 @@
// Queries
pub const primary_device_attrs = "\x1b[c";
pub const tertiary_device_attrs = "\x1b[=c";
pub const xtversion = "\x1b[>0q";
// Key encoding
pub const csi_u = "\x1b[?u";
pub const csi_u_push = "\x1b[>{d}u";
pub const csi_u_pop = "\x1b[<u";
// Cursor
pub const cup = "\x1b[{d};{d}H";
// alt screen
pub const smcup = "\x1b[?1049h";
pub const rmcup = "\x1b[?1049l";

View file

@ -16,6 +16,7 @@ test {
_ = @import("Tty.zig");
_ = @import("Window.zig");
_ = @import("cell.zig");
_ = @import("ctlseqs.zig");
_ = @import("queue.zig");
_ = @import("vaxis.zig");
}