51#define RGB_TEXT(r, g, b) "\x1b[38;2;" #r ";" #g ";" #b "m"
61#define RGB_BG(r, g, b) "\x1b[48;2;" #r ";" #g ";" #b "m"
65 using ColorFunc = std::function<std::ostream&(std::ostream&)>;
85 std::ostream&
reset(std::ostream& stream);
107 std::ostream&
black(std::ostream& stream);
115 std::ostream&
red(std::ostream& stream);
123 std::ostream&
green(std::ostream& stream);
131 std::ostream&
yellow(std::ostream& stream);
139 std::ostream&
blue(std::ostream& stream);
147 std::ostream&
magenta(std::ostream& stream);
155 std::ostream&
cyan(std::ostream& stream);
163 std::ostream&
white(std::ostream& stream);
179 std::ostream&
brightRed(std::ostream& stream);
203 std::ostream&
brightBlue(std::ostream& stream);
219 std::ostream&
brightCyan(std::ostream& stream);
250 std::ostream&
brightRed(std::ostream& stream);
274 std::ostream&
brightBlue(std::ostream& stream);
282 std::ostream&
brightCyan(std::ostream& stream);
305 std::ostream&
bold(std::ostream& stream);
313 std::ostream&
dim(std::ostream& stream);
321 std::ostream&
underline(std::ostream& stream);
329 std::ostream&
blink(std::ostream& stream);
337 std::ostream&
reverse(std::ostream& stream);
345 std::ostream&
hidden(std::ostream& stream);
A namespace containing functions to set the background color in an output stream.
Definition colors.cpp:214
std::ostream & brightYellow(std::ostream &stream)
Set the background color to bright yellow.
Definition colors.cpp:236
std::ostream & brightGreen(std::ostream &stream)
Set the background color to bright green.
Definition colors.cpp:229
std::ostream & brightWhite(std::ostream &stream)
Set the background color to bright white.
Definition colors.cpp:257
std::ostream & brightBlack(std::ostream &stream)
Set the background color to bright black.
Definition colors.cpp:215
std::ostream & brightBlue(std::ostream &stream)
Set the background color to bright blue.
Definition colors.cpp:243
std::ostream & brightCyan(std::ostream &stream)
Set the background color to bright cyan.
Definition colors.cpp:250
std::ostream & brightRed(std::ostream &stream)
Set the background color to bright red.
Definition colors.cpp:222
A namespace containing functions to set the text color in an output stream.
Definition colors.cpp:93
std::ostream & brightWhite(std::ostream &stream)
Set the text color to bright white.
Definition colors.cpp:205
std::ostream & brightGreen(std::ostream &stream)
Set the text color to bright green.
Definition colors.cpp:170
std::ostream & white(std::ostream &stream)
Set the text color to white.
Definition colors.cpp:149
std::ostream & brightMagenta(std::ostream &stream)
Set the text color to bright magenta.
Definition colors.cpp:191
std::ostream & red(std::ostream &stream)
Set the text color to red.
Definition colors.cpp:107
std::ostream & keepOriginal(std::ostream &stream)
Does nothing.
Definition colors.cpp:94
std::ostream & brightCyan(std::ostream &stream)
Set the text color to bright cyan.
Definition colors.cpp:198
std::ostream & brightYellow(std::ostream &stream)
Set the text color to bright yellow.
Definition colors.cpp:177
std::ostream & brightBlack(std::ostream &stream)
Set the text color to bright black.
Definition colors.cpp:156
std::ostream & blue(std::ostream &stream)
Set the text color to blue.
Definition colors.cpp:128
std::ostream & cyan(std::ostream &stream)
Set the text color to cyan.
Definition colors.cpp:142
std::ostream & magenta(std::ostream &stream)
Set the text color to magenta.
Definition colors.cpp:135
std::ostream & green(std::ostream &stream)
Set the text color to green.
Definition colors.cpp:114
std::ostream & yellow(std::ostream &stream)
Set the text color to yellow.
Definition colors.cpp:121
std::ostream & brightRed(std::ostream &stream)
Set the text color to bright red.
Definition colors.cpp:163
std::ostream & brightBlue(std::ostream &stream)
Set the text color to bright blue.
Definition colors.cpp:184
std::ostream & black(std::ostream &stream)
Set the text color to black.
Definition colors.cpp:100
The namespace containing utility functions for the Steppable library.
Definition argParse.cpp:40
std::ostream & reset(std::ostream &stream)
Reset the text color and format to the default values.
Definition colors.cpp:85
std::function< std::ostream &(std::ostream &)> ColorFunc
Definition colors.hpp:65
bool isTerminal(const std::ostream &stream)
Check if the output stream is a terminal.
Definition colors.cpp:74