33 #ifndef CXBASEWIDGET_H_
34 #define CXBASEWIDGET_H_
36 #include "cxResourceWidgetsExport.h"
38 #include <QToolButton>
42 #include <boost/shared_ptr.hpp>
44 #include "boost/function.hpp"
62 class cxResourceWidgets_EXPORT
CXFrame :
public QFrame
66 CXFrame(QWidget* parent) : QFrame(parent) {}
113 BaseWidget(QWidget* parent, QString objectName, QString windowTitle);
116 QWidget* createMethodWidget(QWidget* inputWidget, QWidget* outputWidget, QString methodname,
117 bool inputChecked =
false,
bool outputVisible =
true);
119 QGroupBox* createGroupbox(QWidget* widget, QString boxname);
120 static QFrame* createHorizontalLine();
121 QGroupBox* wrapInGroupBox(QWidget* base, QString name);
122 CXFrame* wrapInFrame(QWidget* base);
128 QAction*
createAction2(QObject* parent, QIcon iconName, QString text, QString tip, QLayout* layout=NULL, QToolButton* button =
new QToolButton())
132 QAction* action =
new QAction(iconName, text, parent);
133 action->setStatusTip(tip);
134 action->setWhatsThis(tip);
135 action->setToolTip(tip);
138 button->setDefaultAction(action);
139 layout->addWidget(button);
149 QAction*
createAction(QObject* parent, QIcon iconName, QString text, QString tip, T slot, QLayout* layout=NULL, QToolButton* button =
new QToolButton())
151 QAction* action = createAction2(parent, iconName, text, tip, layout, button);
152 connect(action, SIGNAL(triggered()),
this, slot);
158 void adjustSizeSlot();
161 virtual void showEvent(QShowEvent* event);
165 QString mWindowTitle;
boost::shared_ptr< class PatientModelService > PatientModelServicePtr