From d21900836f89b2bf9cd55ff1708a4619c8b89656 Mon Sep 17 00:00:00 2001 From: polwex Date: Mon, 20 Oct 2025 13:13:39 +0700 Subject: neoinit --- ocaml/lib/dill.mli | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 ocaml/lib/dill.mli (limited to 'ocaml/lib/dill.mli') diff --git a/ocaml/lib/dill.mli b/ocaml/lib/dill.mli new file mode 100644 index 0000000..f78bba8 --- /dev/null +++ b/ocaml/lib/dill.mli @@ -0,0 +1,30 @@ +(** Dill - Terminal I/O driver using Eio *) + +open Noun + +type belt = + | Aro of [`d | `l | `r | `u] + | Bac + | Ctl of char + | Del + | Met of char + | Ret + | Txt of string list + +type blit = + | Lin of string + | Klr of noun + | Mor of blit list + | Hop of int + | Clr + +type effect = { + wire: noun; + blit: blit; +} + +val render_blit : stdout:_ Eio.Flow.sink -> blit -> unit +val make_belt_event : noun -> belt -> noun +val parse_input : string -> belt +val input_loop : stdin:_ Eio.Flow.source -> state:State.t -> wire:noun -> (noun -> unit) -> unit +val render_effects : stdout:_ Eio.Flow.sink -> noun -> unit -- cgit v1.2.3