OscProb
colormod.h
Go to the documentation of this file.
1
//#include <ostream>
2
3
namespace
Color
{
4
5
enum
Code
{
6
FG_RED
= 31,
7
FG_GREEN
= 32,
8
FG_BLUE
= 34,
9
FG_DEFAULT
= 39,
10
BG_RED
= 41,
11
BG_GREEN
= 42,
12
BG_BLUE
= 44,
13
BG_DEFAULT
= 49
14
};
15
16
string
Modifier
(
string
s,
Code
code) {
17
return
"\033["
+ to_string(code) +
"m"
+ s +
"\033[0m"
;
18
}
19
20
static
const
string
FAILED
=
Modifier
(
"FAILED:"
,
FG_RED
);
21
static
const
string
PASSED
=
Modifier
(
"PASSED:"
,
FG_GREEN
);
22
23
}
Color
Definition:
colormod.h:3
Color::Modifier
string Modifier(string s, Code code)
Definition:
colormod.h:16
Color::Code
Code
Definition:
colormod.h:5
Color::BG_BLUE
@ BG_BLUE
Definition:
colormod.h:12
Color::BG_DEFAULT
@ BG_DEFAULT
Definition:
colormod.h:13
Color::FG_GREEN
@ FG_GREEN
Definition:
colormod.h:7
Color::BG_GREEN
@ BG_GREEN
Definition:
colormod.h:11
Color::FG_DEFAULT
@ FG_DEFAULT
Definition:
colormod.h:9
Color::FG_BLUE
@ FG_BLUE
Definition:
colormod.h:8
Color::BG_RED
@ BG_RED
Definition:
colormod.h:10
Color::FG_RED
@ FG_RED
Definition:
colormod.h:6
Color::PASSED
static const string PASSED
Definition:
colormod.h:21
Color::FAILED
static const string FAILED
Definition:
colormod.h:20
test
colormod.h
Generated by
1.9.4