kalarm/lib

ButtonGroup Class Reference

#include <buttongroup.h>

Inherits TQButtonGroup.

Signals

void buttonSet (int id)
 

Public Member Functions

 ButtonGroup (TQWidget *parent, const char *name=0)
 
 ButtonGroup (const TQString &title, TQWidget *parent, const char *name=0)
 
 ButtonGroup (int strips, TQt::Orientation orient, TQWidget *parent, const char *name=0)
 
 ButtonGroup (int strips, TQt::Orientation orient, const TQString &title, TQWidget *parent, const char *name=0)
 
int insert (TQButton *button, int id=-1)
 
virtual void setButton (int id)
 

Detailed Description

A TQButtonGroup with signal on new selection, plus TQt 2 compatibility.

The ButtonGroup class provides an enhanced version of the TQButtonGroup class.

It emits an additional signal, buttonSet(int), whenever any of its buttons changes state, for whatever reason, including programmatic control. (The TQButtonGroup class only emits signals when buttons are clicked on by the user.) The class also provides TQt 2 compatibility.

Author
David Jarvie softw.nosp@m.are@.nosp@m.astro.nosp@m.jar..nosp@m.org.u.nosp@m.k

Definition at line 38 of file buttongroup.h.

Constructor & Destructor Documentation

◆ ButtonGroup() [1/4]

ButtonGroup::ButtonGroup ( TQWidget *  parent,
const char *  name = 0 
)
explicit

Constructor.

Parameters
parentThe parent object of this widget.
nameThe name of this widget.

Definition at line 29 of file buttongroup.cpp.

◆ ButtonGroup() [2/4]

ButtonGroup::ButtonGroup ( const TQString &  title,
TQWidget *  parent,
const char *  name = 0 
)

Constructor.

Parameters
titleThe title displayed for this button group.
parentThe parent object of this widget.
nameThe name of this widget.

Definition at line 35 of file buttongroup.cpp.

◆ ButtonGroup() [3/4]

ButtonGroup::ButtonGroup ( int  strips,
TQt::Orientation  orient,
TQWidget *  parent,
const char *  name = 0 
)

Constructor.

Parameters
stripsThe number of rows or columns of buttons.
orientThe orientation (TQt::Horizontal or TQt::Vertical) of the button group.
parentThe parent object of this widget.
nameThe name of this widget.

Definition at line 41 of file buttongroup.cpp.

◆ ButtonGroup() [4/4]

ButtonGroup::ButtonGroup ( int  strips,
TQt::Orientation  orient,
const TQString &  title,
TQWidget *  parent,
const char *  name = 0 
)

Constructor.

Parameters
stripsThe number of rows or columns of buttons.
orientThe orientation (TQt::Horizontal or TQt::Vertical) of the button group.
titleThe title displayed for this button group.
parentThe parent object of this widget.
nameThe name of this widget.

Definition at line 47 of file buttongroup.cpp.

Member Function Documentation

◆ buttonSet

void ButtonGroup::buttonSet ( int  id)
signal

Signal emitted whenever whenever any button in the group changes state, for whatever reason.

Parameters
idThe identifier of the button which is now selected.

◆ insert()

int ButtonGroup::insert ( TQButton *  button,
int  id = -1 
)

Inserts a button in the group.

This overrides the insert() method of TQButtonGroup, which should really be a virtual method...

Parameters
buttonThe button to insert.
idThe identifier for the button.
Returns
The identifier of the inserted button.

Definition at line 57 of file buttongroup.cpp.

◆ setButton()

virtual void ButtonGroup::setButton ( int  id)
inlinevirtual

Sets the button with the specified identifier to be on.

If this is an exclusive group, all other buttons in the group will be set off. The buttonSet() signal is emitted.

Parameters
idThe identifier of the button to set on.

Definition at line 80 of file buttongroup.h.


The documentation for this class was generated from the following files: