package mosaic

  1. Overview
  2. Docs
Terminal UI framework for OCaml with The Elm Architecture

Install

dune-project
 Dependency

Authors

Maintainers

Sources

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

doc/mosaic.ui/Mosaic_ui/Text/Fragment/index.html

Module Text.Fragment

type t = fragment
val text : ?style:Ansi.Style.t -> string -> t

text ?style s is a text fragment containing s. When style is provided, it overrides the inherited style for this fragment.

val span : ?style:Ansi.Style.t -> t list -> t

span ?style children is a container grouping children under an optional shared style.

Attribute builders

Each wraps children in a span with a single attribute set.

val bold : t list -> t
val italic : t list -> t
val underline : t list -> t
val dim : t list -> t
val inverse : t list -> t
val hidden : t list -> t
val strikethrough : t list -> t

Combination builders

val bold_italic : t list -> t
val bold_underline : t list -> t
val italic_underline : t list -> t
val bold_italic_underline : t list -> t

Color builders

val fg : Ansi.Color.t -> t list -> t

fg color children sets the foreground color.

val bg : Ansi.Color.t -> t list -> t

bg color children sets the background color.

val color : Ansi.Color.t -> t list -> t

color is fg.

val bg_color : Ansi.Color.t -> t list -> t

bg_color is bg.

val styled : Ansi.Style.t -> t list -> t

styled style children wraps children with the full style.