CFx SDK Documentation
2024 SP0
Loading...
Searching...
No Matches
SDK
CFx
commonui_inc
UI
FxUIToolButton.h
Go to the documentation of this file.
1
//
2
// (C) Copyright 2005-2023 by Graebert GmbH.
3
//
4
// Permission to use, copy, modify, and distribute this software in
5
// object code form for any purpose and without fee is hereby granted,
6
// provided that the above copyright notice appears in all copies and
7
// that both that copyright notice and the limited warranty and
8
// restricted rights notice below appear in all supporting
9
// documentation.
10
//
11
// GRAEBERT PROVIDES THIS PROGRAM "AS IS" AND WITH ALL FAULTS.
12
// GRAEBERT SPECIFICALLY DISCLAIMS ANY IMPLIED WARRANTY OF
13
// MERCHANTABILITY OR FITNESS FOR A PARTICULAR USE. GRAEBERT GMBH
14
// DOES NOT WARRANT THAT THE OPERATION OF THE PROGRAM WILL BE
15
// UNINTERRUPTED OR ERROR FREE.
16
17
#pragma once
18
19
#include "
FxUIBaseView.h
"
20
21
class
CFxUIMenu
;
22
29
class
COMMONUI_API
CFxUIToolButton
:
public
CFxUIBaseView
30
{
31
public
:
35
enum
UIToolButtonStyle
36
{
37
eIconOnly
,
38
eTextOnly
,
39
eTextBesideIcon
,
40
eTextUnderIcon
,
41
eFollowStyle
42
};
43
public
:
45
CFxUIToolButton
();
46
48
~CFxUIToolButton
();
49
55
void
setText
(
const
CFxUIString
& text );
56
62
CFxUIString
text
()
const
;
63
69
void
setResourceIcon
(
const
CFxUIString
& resourceIcon );
70
76
void
setIconSize
(
const
CFxUISize
&
size
);
77
83
CFxUISize
iconSize
()
const
;
84
90
void
setIcon
(
const
CFxUIIcon
&icon);
91
97
void
setTextAlignment
(
TextAlignment
iAlignment );
98
104
void
setBoldText
(
bool
bBold );
105
113
void
setCheckable
(
const
bool
bCheckable );
114
122
void
setChecked
(
bool
bChecked );
123
129
bool
isChecked
()
const
;
130
138
void
setElideTextEnabled
(
const
bool
bEnableElideText );
139
145
void
setMenu
(
CFxUIMenu
* pMenu );
146
152
void
setMenuArrowVisible
(
bool
bVisible );
153
159
void
setToolButtonStyle
(
UIToolButtonStyle
iStyle);
160
166
CFxUIToolButton::UIToolButtonStyle
toolButtonStyle
();
167
171
CFxUISignal
<
void
(
bool
)>&
clicked
();
172
176
CFxUISignal
<
void
(
bool
)>&
toggled
();
177
178
183
CFxUISignal
<
void
(
int
,
int
) >&
keyWentDown
();
184
185
//...
186
};
187
188
COMMONUI_API
#define COMMONUI_API
Definition:
FxCommonFramework.h:20
FxUIBaseView.h
CFxUIString
QString CFxUIString
Definition:
FxUIObject.h:48
CFxUIIcon
QIcon CFxUIIcon
Definition:
FxUIObject.h:63
CFxUISize
QSize CFxUISize
Definition:
FxUIObject.h:47
CFxUIBaseView
Definition:
FxUIBaseView.h:30
CFxUIBaseView::TextAlignment
TextAlignment
Definition:
FxUIBaseView.h:37
CFxUIMenu
Definition:
FxUIMenu.h:28
CFxUISignal
Definition:
FxUISignal.h:74
CFxUIToolButton
Definition:
FxUIToolButton.h:30
CFxUIToolButton::~CFxUIToolButton
~CFxUIToolButton()
CFxUIToolButton::setCheckable
void setCheckable(const bool bCheckable)
CFxUIToolButton::setMenu
void setMenu(CFxUIMenu *pMenu)
CFxUIToolButton::setChecked
void setChecked(bool bChecked)
CFxUIToolButton::text
CFxUIString text() const
CFxUIToolButton::setToolButtonStyle
void setToolButtonStyle(UIToolButtonStyle iStyle)
CFxUIToolButton::setText
void setText(const CFxUIString &text)
CFxUIToolButton::setBoldText
void setBoldText(bool bBold)
CFxUIToolButton::toolButtonStyle
CFxUIToolButton::UIToolButtonStyle toolButtonStyle()
CFxUIToolButton::UIToolButtonStyle
UIToolButtonStyle
Definition:
FxUIToolButton.h:36
CFxUIToolButton::eTextUnderIcon
@ eTextUnderIcon
This enum displays text under icon.
Definition:
FxUIToolButton.h:40
CFxUIToolButton::eIconOnly
@ eIconOnly
This enum displays icon only.
Definition:
FxUIToolButton.h:37
CFxUIToolButton::eTextBesideIcon
@ eTextBesideIcon
This enum displays text beside icon.
Definition:
FxUIToolButton.h:39
CFxUIToolButton::eTextOnly
@ eTextOnly
This enum displays text only.
Definition:
FxUIToolButton.h:38
CFxUIToolButton::setResourceIcon
void setResourceIcon(const CFxUIString &resourceIcon)
CFxUIToolButton::iconSize
CFxUISize iconSize() const
CFxUIToolButton::setIcon
void setIcon(const CFxUIIcon &icon)
CFxUIToolButton::isChecked
bool isChecked() const
CFxUIToolButton::setIconSize
void setIconSize(const CFxUISize &size)
CFxUIToolButton::CFxUIToolButton
CFxUIToolButton()
CFxUIToolButton::toggled
CFxUISignal< void(bool)> & toggled()
CFxUIToolButton::setTextAlignment
void setTextAlignment(TextAlignment iAlignment)
CFxUIToolButton::setMenuArrowVisible
void setMenuArrowVisible(bool bVisible)
CFxUIToolButton::setElideTextEnabled
void setElideTextEnabled(const bool bEnableElideText)
CFxUIToolButton::clicked
CFxUISignal< void(bool)> & clicked()
CFxUIToolButton::keyWentDown
CFxUISignal< void(int, int) > & keyWentDown()
size
GLsizeiptr size
Definition:
gles2_ext.h:182
void
typedef void(APIENTRYP PFNGLACTIVETEXTUREPROC)(GLenum texture)
Generated on Wed Apr 5 2023 17:29:10