GlistEngine
Loading...
Searching...
No Matches
gGUIForm.h
Go to the documentation of this file.
1
/*
2
* gGUITopContainer.h
3
*
4
* Created on: Aug 20, 2021
5
* Author: noyan
6
*/
7
8
#ifndef UI_GGUIFORM_H_
9
#define UI_GGUIFORM_H_
10
11
#include "
gBaseGUIObject.h
"
12
class
gGUISizer
;
13
class
gGUIMenubar
;
14
class
gGUIToolbar
;
15
class
gGUIContextMenu
;
16
class
gGUIStatusBar
;
17
class
gGUITreelist
;
18
class
gGUITooltipText
;
19
20
21
class
gGUIForm
:
public
gBaseGUIObject
{
22
public
:
23
gGUIForm
();
24
virtual
~gGUIForm
();
25
26
enum
{
27
RESIZE_MENUBAR
,
28
RESIZE_STATUSBAR
,
29
RESIZE_TOOLBAR_HORIZONTAL
,
30
RESIZE_TOOLBAR_VERTICAL
31
};
32
33
void
setMenuBar
(
gGUIMenubar
* menuBar);
34
void
resizeMenuBar
();
35
void
addToolBar
(
gGUIToolbar
* toolBar);
36
void
resizeToolbars
();
37
void
resizeVerticalToolbars
();
38
void
setStatusBar
(
gGUIStatusBar
* statusBar);
39
void
resizeStatusBar
();
40
void
addContextMenu
(
gGUIContextMenu
* contextMenu);
41
void
addTreelist
(
gGUITreelist
* treeList,
int
treeListx,
int
treeListy,
int
treeListw);
42
void
resizeAll
(
int
resizeCode);
43
44
void
setToolbarHeight
(
int
toolbarHeight);
45
int
getToolbarHeight
();
46
void
setVerticalToolbarWidth
(
int
verticalToolbarWidth);
47
int
getVerticalToolbarWidth
();
48
49
void
setSizer
(
gGUISizer
* guiSizer);
50
void
updateSizer
();
51
gGUISizer
*
getSizer
();
52
53
virtual
int
getCursor
(
int
x,
int
y);
54
int
getFocusId
();
55
int
getPreviousFocusId
();
56
57
void
show
();
58
void
hide
();
59
60
void
keyPressed
(
int
key);
61
void
keyReleased
(
int
key);
62
void
charPressed
(
unsigned
int
codepoint);
63
void
mouseMoved
(
int
x,
int
y);
64
void
mousePressed
(
int
x,
int
y,
int
button);
65
void
mouseDragged
(
int
x,
int
y,
int
button);
66
void
mouseReleased
(
int
x,
int
y,
int
button);
67
void
mouseScrolled
(
int
x,
int
y);
68
void
mouseEntered
();
69
void
mouseExited
();
70
void
windowResized
(
int
w,
int
h);
71
72
void
setTooltipText
(
gGUITooltipText
* tooltiptext);
73
74
void
showProgressBar
(
int
style = 0,
gColor
col =
gColor
(1.0f, 1.0f, 1.0f),
float
speed = 1.0f);
75
void
hideProgressBar
();
76
bool
isProgressShown
();
77
78
protected
:
79
static
const
int
maxtoolbarnum
= 9;
80
gGUISizer
*
guisizer
, *
temporaryemptysizer
;
81
bool
isshown
;
82
gGUIMenubar
*
menubar
;
83
gGUIToolbar
*
toolbars
[
maxtoolbarnum
];
84
gGUIToolbar
*
verticaltoolbars
[
maxtoolbarnum
];
85
gGUIStatusBar
*
statusbar
;
86
int
toolbarnum
,
verticaltoolbarnum
;
87
int
menuh
;
88
int
toolbarh
,
verticaltoolbarw
;
89
int
statusw
,
statush
;
90
int
sizerh
;
91
gGUIContextMenu
*
contextmenu
;
92
int
contextmenuw
,
contextmenuh
;
93
int
contextmenux
,
contextmenuy
;
94
gGUITreelist
*
treelist
;
95
int
treelistw
,
treelisth
;
96
std::vector<gGUITooltipText*>
vectooltiptext
;
97
bool
isprogressshown
;
98
float
cprdeg
;
99
int
cpx
,
cpy
,
cpw
,
cph
;
100
gColor
cpcolor
;
101
float
cpspeed
;
102
};
103
104
#endif
/* UI_GGUIFORM_H_ */
gBaseGUIObject
Definition
gBaseGUIObject.h:18
gColor
Definition
gColor.h:17
gGUIContextMenu
Definition
gGUIContextMenu.h:215
gGUIForm
Definition
gGUIForm.h:21
gGUIForm::contextmenux
int contextmenux
Definition
gGUIForm.h:93
gGUIForm::toolbarh
int toolbarh
Definition
gGUIForm.h:88
gGUIForm::toolbars
gGUIToolbar * toolbars[maxtoolbarnum]
Definition
gGUIForm.h:83
gGUIForm::cprdeg
float cprdeg
Definition
gGUIForm.h:98
gGUIForm::verticaltoolbarnum
int verticaltoolbarnum
Definition
gGUIForm.h:86
gGUIForm::keyReleased
void keyReleased(int key)
gGUIForm::cpy
int cpy
Definition
gGUIForm.h:99
gGUIForm::treelisth
int treelisth
Definition
gGUIForm.h:95
gGUIForm::menubar
gGUIMenubar * menubar
Definition
gGUIForm.h:82
gGUIForm::addToolBar
void addToolBar(gGUIToolbar *toolBar)
gGUIForm::addContextMenu
void addContextMenu(gGUIContextMenu *contextMenu)
gGUIForm::cpx
int cpx
Definition
gGUIForm.h:99
gGUIForm::charPressed
void charPressed(unsigned int codepoint)
gGUIForm::mouseReleased
void mouseReleased(int x, int y, int button)
gGUIForm::cpcolor
gColor cpcolor
Definition
gGUIForm.h:100
gGUIForm::toolbarnum
int toolbarnum
Definition
gGUIForm.h:86
gGUIForm::statush
int statush
Definition
gGUIForm.h:89
gGUIForm::verticaltoolbarw
int verticaltoolbarw
Definition
gGUIForm.h:88
gGUIForm::getSizer
gGUISizer * getSizer()
gGUIForm::cpw
int cpw
Definition
gGUIForm.h:99
gGUIForm::mousePressed
void mousePressed(int x, int y, int button)
gGUIForm::getFocusId
int getFocusId()
gGUIForm::RESIZE_STATUSBAR
@ RESIZE_STATUSBAR
Definition
gGUIForm.h:28
gGUIForm::RESIZE_TOOLBAR_VERTICAL
@ RESIZE_TOOLBAR_VERTICAL
Definition
gGUIForm.h:30
gGUIForm::RESIZE_MENUBAR
@ RESIZE_MENUBAR
Definition
gGUIForm.h:27
gGUIForm::RESIZE_TOOLBAR_HORIZONTAL
@ RESIZE_TOOLBAR_HORIZONTAL
Definition
gGUIForm.h:29
gGUIForm::isProgressShown
bool isProgressShown()
gGUIForm::statusbar
gGUIStatusBar * statusbar
Definition
gGUIForm.h:85
gGUIForm::showProgressBar
void showProgressBar(int style=0, gColor col=gColor(1.0f, 1.0f, 1.0f), float speed=1.0f)
gGUIForm::maxtoolbarnum
static const int maxtoolbarnum
Definition
gGUIForm.h:79
gGUIForm::mouseDragged
void mouseDragged(int x, int y, int button)
gGUIForm::treelist
gGUITreelist * treelist
Definition
gGUIForm.h:94
gGUIForm::mouseEntered
void mouseEntered()
gGUIForm::resizeAll
void resizeAll(int resizeCode)
gGUIForm::contextmenuh
int contextmenuh
Definition
gGUIForm.h:92
gGUIForm::treelistw
int treelistw
Definition
gGUIForm.h:95
gGUIForm::mouseScrolled
void mouseScrolled(int x, int y)
gGUIForm::cpspeed
float cpspeed
Definition
gGUIForm.h:101
gGUIForm::~gGUIForm
virtual ~gGUIForm()
gGUIForm::resizeMenuBar
void resizeMenuBar()
gGUIForm::hide
void hide()
gGUIForm::getVerticalToolbarWidth
int getVerticalToolbarWidth()
gGUIForm::addTreelist
void addTreelist(gGUITreelist *treeList, int treeListx, int treeListy, int treeListw)
gGUIForm::setVerticalToolbarWidth
void setVerticalToolbarWidth(int verticalToolbarWidth)
gGUIForm::isshown
bool isshown
Definition
gGUIForm.h:81
gGUIForm::mouseMoved
void mouseMoved(int x, int y)
gGUIForm::verticaltoolbars
gGUIToolbar * verticaltoolbars[maxtoolbarnum]
Definition
gGUIForm.h:84
gGUIForm::contextmenu
gGUIContextMenu * contextmenu
Definition
gGUIForm.h:91
gGUIForm::updateSizer
void updateSizer()
gGUIForm::vectooltiptext
std::vector< gGUITooltipText * > vectooltiptext
Definition
gGUIForm.h:96
gGUIForm::getToolbarHeight
int getToolbarHeight()
gGUIForm::setToolbarHeight
void setToolbarHeight(int toolbarHeight)
gGUIForm::setTooltipText
void setTooltipText(gGUITooltipText *tooltiptext)
gGUIForm::gGUIForm
gGUIForm()
gGUIForm::contextmenuw
int contextmenuw
Definition
gGUIForm.h:92
gGUIForm::resizeToolbars
void resizeToolbars()
gGUIForm::setStatusBar
void setStatusBar(gGUIStatusBar *statusBar)
gGUIForm::getPreviousFocusId
int getPreviousFocusId()
gGUIForm::isprogressshown
bool isprogressshown
Definition
gGUIForm.h:97
gGUIForm::getCursor
virtual int getCursor(int x, int y)
gGUIForm::menuh
int menuh
Definition
gGUIForm.h:87
gGUIForm::keyPressed
void keyPressed(int key)
gGUIForm::setSizer
void setSizer(gGUISizer *guiSizer)
gGUIForm::sizerh
int sizerh
Definition
gGUIForm.h:90
gGUIForm::hideProgressBar
void hideProgressBar()
gGUIForm::guisizer
gGUISizer * guisizer
Definition
gGUIForm.h:80
gGUIForm::temporaryemptysizer
gGUISizer * temporaryemptysizer
Definition
gGUIForm.h:80
gGUIForm::contextmenuy
int contextmenuy
Definition
gGUIForm.h:93
gGUIForm::resizeVerticalToolbars
void resizeVerticalToolbars()
gGUIForm::resizeStatusBar
void resizeStatusBar()
gGUIForm::mouseExited
void mouseExited()
gGUIForm::show
void show()
gGUIForm::setMenuBar
void setMenuBar(gGUIMenubar *menuBar)
gGUIForm::windowResized
void windowResized(int w, int h)
gGUIForm::statusw
int statusw
Definition
gGUIForm.h:89
gGUIForm::cph
int cph
Definition
gGUIForm.h:99
gGUIMenubar
Definition
gGUIMenubar.h:174
gGUISizer
Definition
gGUISizer.h:14
gGUIStatusBar
Definition
gGUIStatusBar.h:15
gGUIToolbar
Definition
gGUIToolbar.h:27
gGUITooltipText
Definition
gGUITooltipText.h:18
gGUITreelist
Definition
gGUITreelist.h:64
gBaseGUIObject.h
engine
ui
gGUIForm.h
Generated by
1.9.8