GlistEngine
Loading...
Searching...
No Matches
gGUICandleStickChart.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: Berke Adil, Utku Sarialan, 2022-on *
31 ****************************************************************************/
32
33/*
34 * gGUICandleStickChart.h
35 *
36 * Created on: 15 Agu 2022
37 * Author: Berke Adil
38 */
39
40#ifndef UI_GGUICANDLESTICKCHART_H_
41#define UI_GGUICANDLESTICKCHART_H_
42
43#include "gImage.h"
44#include "gGUIFrame.h"
45#include "gGUIPanel.h"
46#include "gGUIButton.h"
47#include "gGUITextbox.h"
48#include "gGUIControl.h"
49#include "gLine.h"
50#include "gRectangle.h"
51#include "gGUIGraph.h"
52#include <array>
53
54
56
57public:
60
61 void set(gBaseApp* root, gBaseGUIObject* topParentGUIObject, gBaseGUIObject* parentGUIObject, int parentSlotLineNo, int parentSlotColumnNo, int x, int y, int w, int h);
62
63 void setMaxX(int maxX);
64 void setMinX(int minX);
65 void setMaxY(int maxY);
66 void setMinY(int minY);
67
68 void setLabelCountX(int labelCount);
69 void setLabelCountY(int labelCount);
70
71 void setHighColor(gColor highColor);
73 void setLowColor(gColor lowColor);
75
76 void addPointToLine(float x, float high, float low, float open, float close);
77 void setCandleWidth(float candleWidth);
79
80private:
81 void drawGraph();
82 void updatePoints();
83
84 std::vector<std::array<float, 10>> graphline;
85 gColor highcolor;
86 gColor lowcolor;
87
88 int candlew;
89};
90
91
92
93#endif /* UI_GGUICANDLESTICKCHART_H_ */
Definition gBaseApp.h:16
Definition gBaseGUIObject.h:18
gBaseApp * root
Definition gBaseGUIObject.h:147
Definition gColor.h:17
Definition gGUICandleStickChart.h:55
void setMinY(int minY)
void setMaxX(int maxX)
void setLowColor(gColor lowColor)
void addPointToLine(float x, float high, float low, float open, float close)
void setMinX(int minX)
void set(gBaseApp *root, gBaseGUIObject *topParentGUIObject, gBaseGUIObject *parentGUIObject, int parentSlotLineNo, int parentSlotColumnNo, int x, int y, int w, int h)
void setCandleWidth(float candleWidth)
void setHighColor(gColor highColor)
virtual ~gGUICandleStickChart()
void setMaxY(int maxY)
void setLabelCountX(int labelCount)
void setLabelCountY(int labelCount)
Definition gGUIGraph.h:49