ACF $AcfVersion:0$
CStatusBarWidgetComp.h
Go to the documentation of this file.
1// SPDX-License-Identifier: LGPL-2.1-or-later OR GPL-2.0-or-later OR GPL-3.0-or-later OR LicenseRef-ACF-Commercial
2#pragma once
3
4
5// Qt includes
6#include <QtCore/QtGlobal>
7#if QT_VERSION >= 0x050000
8#include <QtWidgets/QStatusBar>
9#else
10#include <QtGui/QStatusBar>
11#endif
12
13// ACF includes
15
17#include <iqtgui/IGuiObject.h>
18
19
20namespace iqtgui
21{
22
23
29 virtual public iqtgui::IMainWindowComponent
30{
31public:
33
34 I_BEGIN_COMPONENT(CStatusBarWidgetComp);
35 I_REGISTER_INTERFACE(iqtgui::IMainWindowComponent);
36 I_ASSIGN_MULTI_0(m_statusBarWidgetsCompPtr, "StatusBarWidgets", "Widgets to place into the status bar of the application", true);
37 I_ASSIGN(m_isSizeGripEnabledAttrPtr, "EnableSizeGrip", "if enabled, the size grip will be created", true, true);
38 I_ASSIGN(m_suppressWidgetFrameAttrPtr, "SuppressWidgetFrame", "if enabled, the frame around status bar widgets will be hidden", true, false);
39 I_END_COMPONENT;
40
41 // reimplemented (iqtgui::IMainWindowComponent)
42 virtual bool AddToMainWindow(QMainWindow& mainWindow) override;
43 virtual bool RemoveFromMainWindow(QMainWindow& mainWindow) override;
44 virtual QString GetTitle() const override;
45 virtual int GetFlags() const override;
46
47private:
48 I_MULTIREF(iqtgui::IGuiObject, m_statusBarWidgetsCompPtr);
49 I_ATTR(bool, m_isSizeGripEnabledAttrPtr);
50 I_ATTR(bool, m_suppressWidgetFrameAttrPtr);
51};
52
53
54} // namespace iqtgui
55
56
57
58
Base class for component implementation.
Component for inserting of a widget into a status bar of the application.
virtual QString GetTitle() const override
Get the title of the main window component.
virtual bool RemoveFromMainWindow(QMainWindow &mainWindow) override
Remove this component from main window.
virtual bool AddToMainWindow(QMainWindow &mainWindow) override
Add this component to main window.
virtual int GetFlags() const override
Get properties of of the window component.
Common interface for GUI objects used in ACF component context.
Definition IGuiObject.h:133
A common interface for main window component such as dock widget, tool bar and so on.
Standard GUI specific interfaces and components based on Qt.