HIPO  4.3.0
High Performance Output data format for experimental physics
ascii::Foreground Class Reference

ANSI foreground color escape sequence generator. More...

#include <color.h>

Static Public Member Functions

template<typename T >
static Foreground From (T color)
 Create a Foreground color from a color value. More...
 

Friends

std::ostream & operator<< (std::ostream &os, const Foreground &val)
 Output the foreground color escape sequence to an output stream. More...
 

Detailed Description

ANSI foreground color escape sequence generator.

Generates ANSI escape sequences for foreground colors supporting standard colors, 256-color mode, and true color (RGB).

Definition at line 154 of file color.h.

Member Function Documentation

◆ From()

template<typename T >
static Foreground ascii::Foreground::From ( color)
inlinestatic

Create a Foreground color from a color value.

Supports Color, Color256, and RGB types through template specialization.

Template Parameters
Tthe color type (Color, Color256, or RGB)
Parameters
colorthe color value
Returns
a Foreground object configured with the given color

Definition at line 164 of file color.h.

Friends And Related Function Documentation

◆ operator<<

std::ostream& operator<< ( std::ostream &  os,
const Foreground val 
)
friend

Output the foreground color escape sequence to an output stream.

Parameters
osthe output stream
valthe foreground color to output
Returns
the output stream

Definition at line 172 of file color.h.


The documentation for this class was generated from the following file: