|
@@ -42,6 +42,9 @@ class ctkCheckablePushButtonPrivate;
|
|
/// \note In checkBoxControlsButton mode, calling setCheckable instead of
|
|
/// \note In checkBoxControlsButton mode, calling setCheckable instead of
|
|
/// setCheckState may not refresh the button automatically. Use setCheckState
|
|
/// setCheckState may not refresh the button automatically. Use setCheckState
|
|
/// instead.
|
|
/// instead.
|
|
|
|
+/// \note You can automatically check the button when the user checks the
|
|
|
|
+/// checkbox by connecting the checkBoxToggled(bool) signal with the
|
|
|
|
+/// setChecked(bool) slot.
|
|
class CTK_WIDGETS_EXPORT ctkCheckablePushButton : public QPushButton
|
|
class CTK_WIDGETS_EXPORT ctkCheckablePushButton : public QPushButton
|
|
{
|
|
{
|
|
Q_OBJECT
|
|
Q_OBJECT
|
|
@@ -81,6 +84,9 @@ public:
|
|
virtual void setCheckBoxUserCheckable(bool b);
|
|
virtual void setCheckBoxUserCheckable(bool b);
|
|
|
|
|
|
signals:
|
|
signals:
|
|
|
|
+ /// Fired anytime the checkbox change of state
|
|
|
|
+ void checkBoxToggled(bool);
|
|
|
|
+ /// Fired anytime the checkbox change of state
|
|
void checkStateChanged(Qt::CheckState newCheckState);
|
|
void checkStateChanged(Qt::CheckState newCheckState);
|
|
|
|
|
|
protected:
|
|
protected:
|