ddt 1.4.0
 
Loading...
Searching...
No Matches
ddtWidget.hpp
Go to the documentation of this file.
1
9
10#ifndef DDT_DATAVISUALISATION_DDTWIDGETS_WIDGETS_HPP
11#define DDT_DATAVISUALISATION_DDTWIDGETS_WIDGETS_HPP
12
13#include <QtWidgets>
14
19class DdtWidget : public QDockWidget {
20 Q_OBJECT
21
22 public:
27 explicit DdtWidget(QWidget* parent = nullptr);
28
32 virtual ~DdtWidget() = default;
33
42 QWidget* AddParentWidget(QLayout* child_layout);
43
55 void connect(const QObject *sender, const char *signal, const QObject *receiver, const char *member);
56 void connect(const QObject *sender, const QMetaMethod &signal, const QObject *receiver, const QMetaMethod &method);
57 void connect(const QObject *sender, const char *signal, const char *member);
58
69 template <typename Func1, typename Func2>
70 void connect(const typename QtPrivate::FunctionPointer<Func1>::Object *sender, Func1 signal, const QObject *context, Func2 slot);
71
72private:
77 QGroupBox* group_box;
78};
79
80template <typename Func1, typename Func2>
81void DdtWidget::connect(const typename QtPrivate::FunctionPointer<Func1>::Object *sender, Func1 signal, const QObject *context, Func2 slot) {
82 QObject::connect(sender, signal, context, slot, Qt::QueuedConnection);
83}
84
85#endif // DDT_DATAVISUALISATION_DDTWIDGETS_WIDGETS_HPP
DdtWidget(QWidget *parent=nullptr)
DdtWidget.
Definition ddtWidget.cpp:19
void connect(const QObject *sender, const char *signal, const QObject *receiver, const char *member)
connect Group of overloaded functions that use the QObject::connect method with the Qt::QueuedConnect...
Definition ddtWidget.cpp:32
QWidget * AddParentWidget(QLayout *child_layout)
AddParentWidget This will add the given layout to a QGroupBox Widget to integrate in the parent layou...
Definition ddtWidget.cpp:22
virtual ~DdtWidget()=default