Re: [gtkmm] How to set a button back to its released(?) state?



>> Paul Davis <pbd op net> writes:

 > use button.set_active().

 Oh.  I'm terribly sorry.  I lost my way in the documentation and I
 didn't even thought of set_active().

 > class GroupedButtons : public SigC::Object
 > {
 >   public:
 > 	GroupedButtons (unsigned int nbuttons, unsigned int first_active);
 > 	GroupedButtons (vector<Gtk::ToggleButton *>&);
 > 	
 > 	Gtk::ToggleButton& button (unsigned int which) {
 > 		return *buttons[which];
 > 	}
 > 
 >   private:
 > 	vector<Gtk::ToggleButton *> buttons;
 > 	unsigned int current_active;
 > 	void one_clicked (unsigned int which);
 > };

 Oh, I like that.  I could use something like it.

 Thanks for the hint,

 Marcelo



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]