11 #ifndef __FWGUIQT_WIDGET_QFWTOOLBOX_HPP__ 12 #define __FWGUIQT_WIDGET_QFWTOOLBOX_HPP__ 15 #include <QScrollArea> 17 #include <QFormLayout> 18 #include <QPushButton> 20 #include "fwGuiQt/config.hpp" 31 void setText(
const QString &text)
33 button->setText(text);
35 void setIcon(
const QIcon &is)
39 void setToolTip(
const QString &tip)
41 button->setToolTip(tip);
43 QString toolTip()
const 45 return button->toolTip();
49 return button->text();
53 return button->icon();
56 inline bool operator==(
const Page& other)
const 58 return widget == other.widget;
71 FWGUIQT_API
QfwToolBox(QWidget *parent = 0, Qt::WindowFlags f = 0);
72 FWGUIQT_API
virtual ~QfwToolBox();
74 FWGUIQT_API
int addItem(QWidget *widget,
const QString &text);
75 FWGUIQT_API
int insertItem(
int index, QWidget *widget,
const QString &text);
77 FWGUIQT_API
void removeItem(
int index);
79 FWGUIQT_API
void setItemEnabled(
int index,
bool enabled);
80 FWGUIQT_API
bool isItemEnabled(
int index)
const;
82 FWGUIQT_API
void setItemText(
int index,
const QString &text);
83 FWGUIQT_API QString itemText(
int index)
const;
85 FWGUIQT_API
void setItemToolTip(
int index,
const QString &toolTip);
86 FWGUIQT_API QString itemToolTip(
int index)
const;
88 FWGUIQT_API QWidget *widget(
int index)
const;
90 FWGUIQT_API
int indexOf(QWidget *widget)
const;
91 FWGUIQT_API
int count()
const;
93 FWGUIQT_API
void collapseItem(
int index);
94 FWGUIQT_API
void expandItem(
int index);
98 typedef QList< ::fwGuiQt::widget::Page > PageList;
101 void buttonToggled(
bool checked);
102 void widgetDestroyed(QObject*);
107 const ::fwGuiQt::widget::Page* page(
int index)
const;
120 #endif // __FWGUIQT_WIDGET_QFWTOOLBOX_HPP__
The namespace fwGuiQt contains classes which provide the implementation of the Gui using Qt library...