52 #ifndef ACG_QT_FLAPBOX_HH 53 #define ACG_QT_FLAPBOX_HH 59 #include <QPushButton> 61 #include <QResizeEvent> 63 #include <QScrollArea> 64 #include "../Config/ACGDefines.hh" 79 QtFlapBox( QWidget * _parent = 0, Qt::WindowFlags _f = 0 );
82 int addItem( QWidget * _widget,
const QIcon & _icon,
const QString & _text );
83 int addItem( QWidget * _widget,
const QString & _text );
87 int indexOf( QWidget * _widget )
const;
88 int insertItem(
int _index, QWidget * _widget,
89 const QIcon & _icon,
const QString & _text );
90 int insertItem(
int _index, QWidget * _widget,
const QString & _text );
92 bool isItemEnabled(
int _index )
const;
93 QIcon itemIcon(
int _index )
const;
95 QString itemText(
int _index )
const;
96 QString itemToolTip(
int _index )
const;
97 void removeItem(
int _index );
98 void setItemEnabled(
int _index,
bool _enabled );
99 void setItemIcon(
int _index,
const QIcon & _icon );
100 void setItemText(
int _index,
const QString & _text );
101 void setItemToolTip(
int _index,
const QString & _toolTip );
102 QWidget * widget(
int _index )
const;
106 bool isItemHidden(
int _index )
const;
107 void setItemHidden(
int _index,
bool _hidden );
109 virtual QSize sizeHint()
const;
112 virtual void resizeEvent ( QResizeEvent * _event );
116 void sizeHintChanged();
138 QPushButton * button;
141 void setText(
const QString & _text )
143 button->setText( _text );
146 void setIcon(
const QIcon & _icon )
148 button->setIcon( _icon );
151 void setToolTip(
const QString & _tip )
153 button->setToolTip( _tip );
158 return button->text();
163 return button->icon();
166 QString toolTip()
const 168 return button->toolTip();
171 bool operator==(
const Flap & _other )
const 173 return widget == _other.widget;
181 void buttonClicked();
182 void widgetDestroyed(QObject*);
186 typedef QList< Flap > FlapList;
188 Flap * flap( QWidget * _widget )
const;
189 const Flap * flap(
int _index )
const;
190 Flap * flap(
int _index );
196 QVBoxLayout * boxlayout;
205 #endif // ACG_QT_FLAPBOX_HH defined Namespace providing different geometric functions concerning angles.