notty

Declaring terminals
IN THIS PACKAGE
Module Notty . Render
val to_buffer : Buffer.t -> Cap.t -> (int * int) -> (int * int) -> image -> unit

to_buffer buf cap (x, y) (w, h) i writes the string representation of i to buf, as interpreted by cap.

It renders the w * h rectangle of i, offset by (x, y) from the top left.

val pp : Cap.t -> Format.formatter -> image -> unit

pp cap ppf i renders i to the pretty-printer ppf.

Note pp is generally meant for development and debugging. It tries to be reasonable, but dedicated IO modules handle the actual output better.