clutchlog::fmt::color Struct Referenceabstract
Internal colors management in 256 and 16M colors modes.

Interface class for colors representation. More...

`#include <clutchlog.h>`

Inheritance diagram for clutchlog::fmt::color:
[legend]

## Detailed Description

Interface class for colors representation.

Definition at line 470 of file clutchlog.h.

## Public Member Functions

| color (ansi a, ground g)
| Constructor. More...
virtual bool | is_set () const =0
| Should return true if the underying representation encodes an existing color.
virtual std::ostream & | print_on (std::ostream &os) const =0
| Should print the underlying representation on the given stream.

## Public Attributes

ansi | mode
enum clutchlog::fmt::color::ground | type
| Type of color (foreground or background).

## Public Types

enum | ground { fore = 38, back = 48 }
| Codes for representing foreground or background.

## Friends

std::ostream & | operator<< (std::ostream &os, const color &c)
| Print the actually encoded escaped color sequence on the given stream.

## Constructor & Destructor Documentation

## color()

clutchlog::fmt::color::color | ( | ansi | a,
|  | ground | g
| ) |  |

inline

Constructor.

Parameters

  a | ANSI mode (i.e. number of colors).
  g | Color type (i.e. foreground or background).

Definition at line 484 of file clutchlog.h.

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

- clutchlog.h