col256: Apply 256-color formatting

View source: R/fmt.R

col256R Documentation

Apply 256-color formatting

Description

Apply 256-color formatting

Usage

col256(text, col = "79", bg = FALSE, output_type = NULL)

Arguments

text

Character: Text to color

col

Character or numeric: Color (ANSI 256-color code, hex for HTML)

bg

Logical: If TRUE, apply as background color

output_type

Character ("ansi", "html", "plain") or NULL: Output type. If NULL, resolved via get_output_type().

Value

Character: Formatted text with 256-color styling

Author(s)

EDG

Examples

col256("Hello", col = 160, output_type = "ansi")

rtemis.core documentation built on Sept. 20, 2026, 9:06 a.m.