-
Notifications
You must be signed in to change notification settings - Fork 1
/
GCP_Style.h
109 lines (91 loc) · 2.76 KB
/
GCP_Style.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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
#ifndef GCP_StyleH
#define GCP_StyleH
#include "GCP_SPointer.h"
#include "GCP_Constants.h"
namespace gcp
{
class GCP_Style;
typedef GCP_SPointer<GCP_Style> gcp_spStyle;
enum GCPE_StyleType
{
E_DEFAULT,
E_BUTTON,
E_BUTTONWHITE,
E_PANELBLACK,
E_MESSAGEBOX
};
class GCP_Style : public GCP_SPointerBase
{
public:
GCP_Style(GCPE_StyleType sType = E_DEFAULT)
{
//Default options
backgroundColor = c_white;
backgroundMouseHoverColor = c_white;
backgroundDisabledColor = c_dkgrey;
drawTextBorder = false;
drawTextBackground = false;
drawTextBackgroundAlpha = 255;
textColor = c_black;
textMouseHoverColor = c_black;
textDisabledColor = c_grey;
borderColor = c_black;
textFieldColor = c_orange;
headBackground = c_black;
headInactiveColor = c_grey;
headButtonBackground = c_white;
borderWidth = 2;
roundCff = 7;
font.size = 14;
switch (sType)
{
case E_BUTTON:
textColor = c_white;
backgroundColor = c_black;
textMouseHoverColor = c_black;
backgroundMouseHoverColor = c_white;
font.align = E_CENTER;
break;
case E_BUTTONWHITE:
textColor = c_black;
textMouseHoverColor = c_white;
backgroundColor = c_white;
backgroundMouseHoverColor = c_aquadark;
font.align = E_CENTER;
break;
case E_PANELBLACK:
textColor = c_white;
backgroundColor = c_black;
textMouseHoverColor = c_white;
backgroundMouseHoverColor = c_black;
font.size = 20;
font.align = E_CENTER;
break;
case E_MESSAGEBOX:
font.align = E_CENTER;
break;
default:
break;
}
}
public:
GCP_Font font;
GCP_Color backgroundColor; //Ôîí
GCP_Color backgroundMouseHoverColor; //Ôîí ďđč íŕâĺäĺíčč
GCP_Color backgroundDisabledColor; //Ôîí âűęëţ÷ĺííîăî ĺëĺěĺíňŕ
GCP_Color textColor; //Öâĺň ňĺęńňŕ
GCP_Color textMouseHoverColor; //Öâĺň ňĺęńňŕ ďđč íŕâĺäĺíčč
GCP_Color textDisabledColor; //Öâĺň âűęëţ÷ĺííîăî ĺëĺěĺíňŕ
GCP_Color borderColor; //Öâĺň đŕěęč
GCP_Color textFieldColor; //Öâĺň ňĺęńňŕ â ďîë˙ő ââîäŕ
GCP_Color headBackground; //Ôîí çŕăîëîâęŕ (â ôîđěŕő)
GCP_Color headInactiveColor; //Ôîí çŕăîëîâęŕ íĺŕęňčâíîăî ýëĺěĺíňŕ
GCP_Color headButtonBackground; //Ôîí ęíîďîę đŕńďîëîćĺííűő â çŕăîëîâęĺ (ęđĺńňčę íŕ ôîđěĺ)
short borderWidth; //Ňîëůčíŕ đŕěîę
short roundCff; //Ęîýôôčöčĺíň îęđóăëĺíč˙ óăëîâ
bool drawTextBorder; //Đčńîâŕňü đŕěęó âîęđóă ňĺęńňŕ
bool drawTextBackground; //Đčńîâŕňü ôîí ďîä ňĺęńňîě
gcpUint8 drawTextBackgroundAlpha; //Ďđîçđŕ÷íîńňü ôîíŕ ňĺęńňŕ
};
}
#endif