summaryrefslogtreecommitdiff
path: root/ycurses/src/curses/color.h
blob: a59727c0a798e5d901201929e8d07fa3e34e75fd (plain)
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

#ifndef COLOR_H
#define COLOR_H

#include "incl.h"

using namespace std;

const short Red = COLOR_RED;
const short Green = COLOR_GREEN;
const short Yellow = COLOR_YELLOW;
const short Blue = COLOR_BLUE;
const short Cyan = COLOR_CYAN;
const short Magenta = COLOR_MAGENTA;
const short White = COLOR_WHITE;
const short Black = COLOR_BLACK;

class color 
{
 private:
  void init();  

  static int i_pair_count;
  short i_pair;
  short i_foreground;
  short i_background;
  static bool b_activated;

  friend class curses;

 public:
  color(short i, short j);
  ~color();
  void enable();
  void disable();
  short get_num() { return i_pair; }
};

#endif