Helpers for working with terminal cell tuples.
Each cell is {grapheme, fg, bg, flags} where:
grapheme— UTF-8 binary (empty for blank cells)fg/bg—{r, g, b}tuples ornilflags— bitmask of style attributes
Flag bits
| Bit | Attribute |
|---|---|
| 0 | bold |
| 1 | italic |
| 2 | faint |
| 3 | underline |
| 4 | strikethrough |
| 5 | inverse |
| 6 | blink |
| 7 | overline |
Summary
Functions
Returns the background color or nil.
Returns true if the cell is blank (empty grapheme, no styling).
Returns the foreground color or nil.
Returns the raw flags bitmask.
Returns the grapheme string.
Types
@type color() :: {0..255, 0..255, 0..255} | nil
@type t() :: {binary(), color(), color(), non_neg_integer()}
Functions
Returns the background color or nil.
Returns true if the cell is blank (empty grapheme, no styling).
Returns the foreground color or nil.
@spec flags(t()) :: non_neg_integer()
Returns the raw flags bitmask.
Returns the grapheme string.