package matrix

  1. Overview
  2. Docs
Fast, modern terminal toolkit for OCaml

Install

dune-project
 Dependency

Authors

Maintainers

Sources

mosaic-0.1.0.tbz
sha256=9e4e90d17f9b2af1b07071fe425bc2c519c849c4f1d1ab73cde512be2d874849
sha512=06e9c4a741590942e81a27738d0b5c0413fafec8cf3b7dae047ad69f155e7b718aa4223818dc161b7d028efffcfd3365905e264d6fd31d453910ddfa91dcf9b9

doc/matrix.grid/Grid/Border/index.html

Module Grid.BorderSource

Box-drawing border character sets.

Box-drawing border character sets.

A border defines the 11 Unicode scalars needed to draw a complete box: four corners, horizontal and vertical edges, four T-junctions, and a cross intersection.

Borders

Sourcetype t = {
  1. top_left : Uchar.t;
  2. top_right : Uchar.t;
  3. bottom_left : Uchar.t;
  4. bottom_right : Uchar.t;
  5. horizontal : Uchar.t;
  6. vertical : Uchar.t;
  7. top_t : Uchar.t;
  8. bottom_t : Uchar.t;
  9. left_t : Uchar.t;
  10. right_t : Uchar.t;
  11. cross : Uchar.t;
}

The type for border character sets.

Presets

Sourceval single : t

Light box drawing: ┌ ┐ └ ┘ ─ │ ┬ ┴ ├ ┤ ┼

Sourceval double : t

Double box drawing: ╔ ╗ ╚ ╝ ═ ║ ╦ ╩ ╠ ╣ ╬

Sourceval rounded : t

Rounded box drawing: ╭ ╮ ╰ ╯ ─ │ ┬ ┴ ├ ┤ ┼

Sourceval heavy : t

Heavy box drawing: ┏ ┓ ┗ ┛ ━ ┃ ┳ ┻ ┣ ┫ ╋

Sourceval ascii : t

ASCII fallback: + + + + - | + + + + +.

Sourceval empty : t

Invisible border (spaces).

Customizing

Sourceval modify : ?top_left:Uchar.t -> ?top_right:Uchar.t -> ?bottom_left:Uchar.t -> ?bottom_right:Uchar.t -> ?horizontal:Uchar.t -> ?vertical:Uchar.t -> ?top_t:Uchar.t -> ?bottom_t:Uchar.t -> ?left_t:Uchar.t -> ?right_t:Uchar.t -> ?cross:Uchar.t -> t -> t

modify ?top_left ... base is base with the specified characters overridden.

Sides

Sourcetype side = [
  1. | `Top
  2. | `Right
  3. | `Bottom
  4. | `Left
]

The type for box sides.

Sourceval all : side list

all is [\`Top; \`Right; \`Bottom; \`Left].