-
Notifications
You must be signed in to change notification settings - Fork 2
/
ansicol.h
59 lines (50 loc) · 1.36 KB
/
ansicol.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
/* Declarations for ANSI color stuff.
* Copyright (C) 2001, Guido Flohr <[email protected]>,
* all rights reserved.
*/
#ifndef tw_ansicol_h
# define tw_ansicol_h 1
#ifndef tw_textwin_h
# include "textwin.h"
#endif
#define ANSI_BLACK 0
#define ANSI_RED 1
#define ANSI_GREEN 2
#define ANSI_YELLOW 3
#define ANSI_BLUE 4
#define ANSI_MAGENTA 5
#define ANSI_CYAN 6
#define ANSI_WHITE 7
#define ANSI_DEFAULT 9
#define ANSI_DEFAULT_FGCOLOR ANSI_WHITE
#define ANSI_DEFAULT_BGCOLOR ANSI_BLACK
#define VDI_BLACK 1
#define VDI_RED 10
#define VDI_GREEN 11
#define VDI_YELLOW 14
#define VDI_BLUE 12
#define VDI_MAGENTA 15
#define VDI_CYAN 13
#define VDI_WHITE 8
#define VDI_BLACK_BRIGHT 9
#define VDI_RED_BRIGHT 2
#define VDI_GREEN_BRIGHT 3
#define VDI_YELLOW_BRIGHT 6
#define VDI_BLUE_BRIGHT 4
#define VDI_MAGENTA_BRIGHT 7
#define VDI_CYAN_BRIGHT 5
#define VDI_WHITE_BRIGHT 0
extern const int ansi2vdi[8];
extern const int vdi2ansi[8];
extern const int ansibright2vdi[8];
extern char* tw52_env;
extern char* tw100_env;
extern char* colorterm_env;
void init_ansi_colors (const short* __work_out);
void set_ansi_fg_color (TEXTWIN* __textwin, int __color);
void set_ansi_bg_color (TEXTWIN* __textwin, int __color);
void use_ansi_colors (TEXTWIN* __textwin, unsigned long __flag,
int* __fgcolor, int* __bgcolor,
int* __texteffects);
int get_ansi_color (int __color);
#endif