package textutils_kernel

  1. Overview
  2. Docs
Text output utilities

Install

Dune Dependency

Authors

Maintainers

Sources

textutils_kernel-v0.16.0.tar.gz
sha256=621e8ecf031ceac0dbb70a5ac4d8ef6add20cf387844402a3fb9e149870ad131

doc/textutils_kernel.text_block/Text_block/Boxed/index.html

Module Text_block.BoxedSource

Combinators for building up cell structures separated by box characters: e.g.

  let a = text "A" in
  let b = text "B" in
  let c = text "C" in
  boxed Boxed.(hcat [vcat [cell a; cell b]; c])

and

  let a = text "A" in
  let b = text "B" in
  let c = text "C" in
  boxed Boxed.(hcat [
    vcat [cell a; cell b];
    c;
    vcat [cell b; cell a]
  ])

produce

┌───┬───┐ ┌───┬───┬───┐ │ A │ │ │ A │ │ B │ ├───┤ C │ and ├───┤ C ├───┤ │ B │ │ │ B │ │ A │ └───┴───┘ └───┴───┴───┘

respectively.

Sourcetype outer_t := t
Sourcetype t
Sourceval sexp_of_t : t -> Sexplib0.Sexp.t
Sourceval cell : ?hpadding:int -> ?vpadding:int -> outer_t -> t

An outlined table cell, possibly with extra space (padding) on the sides.

hpadding defaults to 1. vpadding defaults to 0.

Sourceval vcat : ?align:halign -> t list -> t

Vertical concatenation with inserts horizontal separator lines.

Sourceval hcat : ?align:valign -> t list -> t

horizontal concatenation with inserts vertical separator lines.

OCaml

Innovation. Community. Security.