table-layout-0.9.0.1: Format tabular data as grid or table.

Safe HaskellSafe
LanguageHaskell2010

Text.Layout.Table.Cell.Formatted

Description

Provides formatting to an instance of Cell. For example, in a unix terminal one could use the following:

>>> buildCell (formatted "\ESC[31m" "Hello World!" "\ESC[0m") :: String
Hello World!

The text then appears in dull red.

Synopsis

Documentation

formatted Source #

Arguments

:: String

Prefix text directives for formatting.

-> a

The content to be formatted.

-> String

Suffix text directives for formatting.

-> Formatted a 

Create a formatted value with formatting directives that are applied to the whole value. The actual formatting has to be done by the backend.

plain :: a -> Formatted a Source #

Create a value from content that is kept plain without any formatting.