1 /*---------------------------------------------------------------------\
3 | __ __ ____ _____ ____ |
4 | \ \ / /_ _/ ___|_ _|___ \ |
5 | \ V / _` \___ \ | | __) | |
6 | | | (_| |___) || | / __/ |
7 | |_|\__,_|____/ |_| |_____| |
11 \----------------------------------------------------------------------/
15 Author: Stefan Hundhammer <sh@suse.de>
24 #include "YCheckBox.h"
26 class YQCheckBox : public QCheckBox, public YCheckBox
35 YQCheckBox( YWidget * parent,
42 virtual ~YQCheckBox();
45 * Get the current value:
47 * YCheckBox_on CheckBox is checked
48 * YCheckBox_off CheckBox is unchecked
50 * YCheckBox_dont_care tri-state: CheckBox is greyed out,
51 * neither checked nor unchecked
53 * Reimplemented from YCheckBox.
55 virtual YCheckBoxState value();
58 * Set the CheckBox value (on/off/don't care).
60 * Reimplemented from YCheckBox.
62 virtual void setValue( YCheckBoxState state );
65 * Change the label (the text) on the RadioButton.
67 * Reimplemented from YRadioButton.
69 virtual void setLabel( const string & label );
74 * Reimplemented from YRadioButton.
76 virtual void setUseBoldFont( bool bold = true );
79 * Set enabled / disabled state.
81 * Reimplemented from YWidget.
83 virtual void setEnabled( bool enabled );
86 * Preferred width of the widget.
88 * Reimplemented from YWidget.
90 virtual int preferredWidth();
93 * Preferred height of the widget.
95 * Reimplemented from YWidget.
97 virtual int preferredHeight();
100 * Set the new size of the widget.
102 * Reimplemented from YWidget.
104 virtual void setSize( int newWidth, int newHeight );
107 * Accept the keyboard focus.
109 * Reimplemented from YWidget.
111 virtual bool setKeyboardFocus();
117 * Triggered when the on/off status is changed
119 void stateChanged ( int newState );
123 #endif // YQCheckBox_h