GlistEngine
Loading...
Searching...
No Matches
gGUIProgressBar.h
Go to the documentation of this file.
1/****************************************************************************
2 * Copyright (c) 2014 Nitra Games Ltd., Istanbul, Turkey *
3 * *
4 * Permission is hereby granted, free of charge, to any person obtaining a *
5 * copy of this software and associated documentation files (the *
6 * "Software"), to deal in the Software without restriction, including *
7 * without limitation the rights to use, copy, modify, merge, publish, *
8 * distribute, distribute with modifications, sublicense, and/or sell *
9 * copies of the Software, and to permit persons to whom the Software is *
10 * furnished to do so, subject to the following conditions: *
11 * *
12 * The above copyright notice and this permission notice should not be *
13 * deleted from the source form of the Software. *
14 * *
15 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS *
16 * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF *
17 * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. *
18 * IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, *
19 * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR *
20 * OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR *
21 * THE USE OR OTHER DEALINGS IN THE SOFTWARE. *
22 * *
23 * Except as contained in this notice, the name(s) of the above copyright *
24 * holders shall not be used in advertising or otherwise to promote the *
25 * sale, use or other dealings in this Software without prior written *
26 * authorization. *
27 ****************************************************************************/
28
29/****************************************************************************
30 * Author: Sevval Bulburu, Aynur Dogan 2022-07-20 *
31 ****************************************************************************/
32
33/*
34 * gGUIProgressBar.h
35 *
36 * Created on: July 20, 2022
37 * Author: sevval, aynur
38 * Revised: 16 March 2022 Umutcan Turkmen
39 */
40
41#ifndef UI_GGUIPROGRESSBAR_H_
42#define UI_GGUIPROGRESSBAR_H_
43
44#include "gGUIControl.h"
45
58public:
62
65 void draw();
66
76 void setValue(float value);
77
81 float getValue();
82
92 void setMaxValue(float value);
93
103 void setMinValue(float value);
104
108 float getMaxValue();
109
113 float getMinValue();
114
121 void setProgressBarColor(float r, float g, float b);
122
129 void setBackgroundColor(float r, float g, float b);
130
135
144 void setBorderThickness(float thickness);
145
150
156 void setProgressBarSize(int w, int h);
157
162
167
168 void setType(TYPE type);
170 void setLineTextColor(float r, float g, float b);
171 void setSpinTextColor(float r, float g, float b);
172 void setSpinThickness(float thickness);
174 void displayProgressText(bool display);
175
176
177private:
178 int progressbarw, progressbarh;
179 int radius;
180 float valuemax, valuemin;
181 float value;
182 float thickness, spinthickness;
183 TYPE type;
184 bool textdisplayed;
185 float texth;
186
187 gColor progressbarcolor;
188 gColor backgroundcolor;
189 gColor linetextcolor, spintextcolor;
190};
191
192#endif /* UI_GGUIPROGRESSBAR_H_ */
Definition gColor.h:17
Definition gGUIControl.h:29
Definition gGUIProgressBar.h:57
float getMaxValue()
gColor * getProgressBarColor()
void setType(TYPE type)
float getMinValue()
void setProgressBarColor(float r, float g, float b)
void setBorderThickness(float thickness)
int getProgressBarWidth()
TYPE
Definition gGUIProgressBar.h:59
@ TYPE_CIRCULAR
Definition gGUIProgressBar.h:60
@ TYPE_LINE
Definition gGUIProgressBar.h:60
@ TYPE_SPIN
Definition gGUIProgressBar.h:60
virtual ~gGUIProgressBar()
int getProgressBarHeight()
void setBackgroundColor(float r, float g, float b)
void displayProgressText(bool display)
void setProgressBarSize(int w, int h)
float getBorderThickness()
void setValue(float value)
void setMaxValue(float value)
void setSpinThickness(float thickness)
void setMinValue(float value)
void setSpinTextColor(float r, float g, float b)
float getSpinThickness()
void setLineTextColor(float r, float g, float b)
float r
Definition gColor.h:22
float b
Definition gColor.h:22
float g
Definition gColor.h:22