.TH "KToggleAction" 3 "28 Jan 2004" "kdeui Library" \" -*- nroff -*-
.ad l
.nh
.SH NAME
KToggleAction \- Checkbox like action. Checkbox like action.  

.PP
.SH SYNOPSIS
.br
.PP
\fC#include <kaction.h>\fP
.PP
Inherits \fBKAction\fP.
.PP
Inherited by \fBKRadioAction\fP, and \fBKToggleToolBarAction\fP.
.PP
.SS "Public Slots"

.in +1c
.ti -1c
.RI "virtual void \fBsetChecked\fP (bool)"
.br
.RI "\fISets the state of the action. \fP"
.in -1c
.SS "Signals"

.in +1c
.ti -1c
.RI "void \fBtoggled\fP (bool)"
.br
.in -1c
.SS "Public Member Functions"

.in +1c
.ti -1c
.RI "\fBKToggleAction\fP (const  \fBQString\fP &text, const  KShortcut &cut=KShortcut(), \fBQObject\fP *\fBparent\fP=0, const  char *\fBname\fP=0)"
.br
.RI "\fIConstructs a toggle action with text and potential keyboard accelerator but nothing else. \fP"
.ti -1c
.RI "\fBKToggleAction\fP (const  \fBQString\fP &text, const  KShortcut &cut, const  \fBQObject\fP *receiver, const  char *slot, \fBQObject\fP *\fBparent\fP, const  char *\fBname\fP=0)"
.br
.ti -1c
.RI "\fBKToggleAction\fP (const  \fBQString\fP &text, const  \fBQIconSet\fP &pix, const  KShortcut &cut=KShortcut(), \fBQObject\fP *\fBparent\fP=0, const  char *\fBname\fP=0)"
.br
.ti -1c
.RI "\fBKToggleAction\fP (const  \fBQString\fP &text, const  \fBQString\fP &pix, const  KShortcut &cut=KShortcut(), \fBQObject\fP *\fBparent\fP=0, const  char *\fBname\fP=0)"
.br
.ti -1c
.RI "\fBKToggleAction\fP (const  \fBQString\fP &text, const  \fBQIconSet\fP &pix, const  KShortcut &cut, const  \fBQObject\fP *receiver, const  char *slot, \fBQObject\fP *\fBparent\fP, const  char *\fBname\fP=0)"
.br
.ti -1c
.RI "\fBKToggleAction\fP (const  \fBQString\fP &text, const  \fBQString\fP &pix, const  KShortcut &cut, const  \fBQObject\fP *receiver, const  char *slot, \fBQObject\fP *\fBparent\fP, const  char *\fBname\fP=0)"
.br
.ti -1c
.RI "\fBKToggleAction\fP (\fBQObject\fP *\fBparent\fP=0, const  char *\fBname\fP=0)"
.br
.ti -1c
.RI "virtual \fB~KToggleAction\fP ()"
.br
.RI "\fIDestructor. \fP"
.ti -1c
.RI "virtual int \fBplug\fP (\fBQWidget\fP *widget, int index=-1)"
.br
.RI "\fI'Plug' or insert this action into a given widget. \fP"
.ti -1c
.RI "bool \fBisChecked\fP () const "
.br
.RI "\fIReturns the actual state of the action. \fP"
.ti -1c
.RI "\fBQString\fP \fBexclusiveGroup\fP () const "
.br
.ti -1c
.RI "virtual void \fBsetExclusiveGroup\fP (const  \fBQString\fP &\fBname\fP)"
.br
.RI "\fIDefines which 'exclusive group' this action is part of. \fP"
.in -1c
.SS "Protected Slots"

.in +1c
.ti -1c
.RI "virtual void \fBslotActivated\fP ()"
.br
.in -1c
.SS "Protected Member Functions"

.in +1c
.ti -1c
.RI "virtual void \fBupdateChecked\fP (int id)"
.br
.ti -1c
.RI "virtual void \fBvirtual_hook\fP (int id, void *data)"
.br
.in -1c
.SH "Detailed Description"
.PP 
Checkbox like action. Checkbox like action. 

This action provides two states: checked or not.
.PP
Definition at line 611 of file kaction.h.
.SH "Constructor & Destructor Documentation"
.PP 
.SS "KToggleAction::KToggleAction (const \fBQString\fP & text, const KShortcut & cut = KShortcut(), \fBQObject\fP * parent = 0, const char * name = 0)"
.PP
Constructs a toggle action with text and potential keyboard accelerator but nothing else. Use this only if you really know what you are doing.
.PP
\fBParameters:\fP
.RS 4
\fItext\fP The text that will be displayed. 
.br
\fIcut\fP The corresponding keyboard accelerator (shortcut). 
.br
\fIparent\fP This action's parent. 
.br
\fIname\fP An internal name for this action. 
.RE
.PP
Definition at line 1205 of file kaction.cpp.
.PP
References KStdAccel::cut(), and QObject::name().
.SS "KToggleAction::KToggleAction (const \fBQString\fP & text, const KShortcut & cut, const \fBQObject\fP * receiver, const char * slot, \fBQObject\fP * parent, const char * name = 0)"
.PP
\fBParameters:\fP
.RS 4
\fItext\fP The text that will be displayed. 
.br
\fIcut\fP The corresponding keyboard accelerator (shortcut). 
.br
\fIreceiver\fP The SLOT's parent. 
.br
\fIslot\fP The SLOT to invoke to execute this action. 
.br
\fIparent\fP This action's parent. 
.br
\fIname\fP An internal name for this action. 
.RE
.PP
Definition at line 1213 of file kaction.cpp.
.PP
References KStdAccel::cut(), and KStdAccel::name().
.SS "KToggleAction::KToggleAction (const \fBQString\fP & text, const \fBQIconSet\fP & pix, const KShortcut & cut = KShortcut(), \fBQObject\fP * parent = 0, const char * name = 0)"
.PP
\fBParameters:\fP
.RS 4
\fItext\fP The text that will be displayed. 
.br
\fIpix\fP The icons that go with this action. 
.br
\fIcut\fP The corresponding keyboard accelerator (shortcut). 
.br
\fIparent\fP This action's parent. 
.br
\fIname\fP An internal name for this action. 
.RE
.PP
Definition at line 1221 of file kaction.cpp.
.PP
References KStdAccel::cut(), and KStdAccel::name().
.SS "KToggleAction::KToggleAction (const \fBQString\fP & text, const \fBQString\fP & pix, const KShortcut & cut = KShortcut(), \fBQObject\fP * parent = 0, const char * name = 0)"
.PP
\fBParameters:\fP
.RS 4
\fItext\fP The text that will be displayed. 
.br
\fIpix\fP The dynamically loaded icon that goes with this action. 
.br
\fIcut\fP The corresponding keyboard accelerator (shortcut). 
.br
\fIparent\fP This action's parent. 
.br
\fIname\fP An internal name for this action. 
.RE
.PP
Definition at line 1229 of file kaction.cpp.
.PP
References KStdAccel::cut(), and KStdAccel::name().
.SS "KToggleAction::KToggleAction (const \fBQString\fP & text, const \fBQIconSet\fP & pix, const KShortcut & cut, const \fBQObject\fP * receiver, const char * slot, \fBQObject\fP * parent, const char * name = 0)"
.PP
\fBParameters:\fP
.RS 4
\fItext\fP The text that will be displayed. 
.br
\fIpix\fP The icons that go with this action. 
.br
\fIcut\fP The corresponding keyboard accelerator (shortcut). 
.br
\fIreceiver\fP The SLOT's parent. 
.br
\fIslot\fP The SLOT to invoke to execute this action. 
.br
\fIparent\fP This action's parent. 
.br
\fIname\fP An internal name for this action. 
.RE
.PP
Definition at line 1237 of file kaction.cpp.
.PP
References KStdAccel::cut(), and KStdAccel::name().
.SS "KToggleAction::KToggleAction (const \fBQString\fP & text, const \fBQString\fP & pix, const KShortcut & cut, const \fBQObject\fP * receiver, const char * slot, \fBQObject\fP * parent, const char * name = 0)"
.PP
\fBParameters:\fP
.RS 4
\fItext\fP The text that will be displayed. 
.br
\fIpix\fP The dynamically loaded icon that goes with this action. 
.br
\fIcut\fP The corresponding keyboard accelerator (shortcut). 
.br
\fIreceiver\fP The SLOT's parent. 
.br
\fIslot\fP The SLOT to invoke to execute this action. 
.br
\fIparent\fP This action's parent. 
.br
\fIname\fP An internal name for this action. 
.RE
.PP
Definition at line 1247 of file kaction.cpp.
.PP
References KStdAccel::cut(), and KStdAccel::name().
.SS "KToggleAction::KToggleAction (\fBQObject\fP * parent = 0, const char * name = 0)"
.PP
\fBParameters:\fP
.RS 4
\fIparent\fP This action's parent. 
.br
\fIname\fP An internal name for this action. 
.RE
.PP
Definition at line 1257 of file kaction.cpp.
.PP
References KStdAccel::name().
.SS "KToggleAction::~\fBKToggleAction\fP ()\fC [virtual]\fP"
.PP
Destructor. Definition at line 1263 of file kaction.cpp.
.SH "Member Function Documentation"
.PP 
.SS "int KToggleAction::plug (\fBQWidget\fP * widget, int index = -1)\fC [virtual]\fP"
.PP
'Plug' or insert this action into a given widget. This will typically be a menu or a toolbar. From this point on, you will never need to directly manipulate the item in the menu or toolbar. You do all enabling/disabling/manipulation directly with your KToggleAction object.
.PP
\fBParameters:\fP
.RS 4
\fIwidget\fP The GUI element to display this action. 
.br
\fIindex\fP The index of the item. 
.RE
.PP
Reimplemented from \fBKAction\fP.
.PP
Reimplemented in \fBKToggleToolBarAction\fP.
.PP
Definition at line 1268 of file kaction.cpp.
.PP
References isChecked(), QObject::name(), KAction::plug(), KToolBar::setButton(), and KToolBar::setToggle().
.PP
Referenced by KToggleToolBarAction::plug().
.SS "bool KToggleAction::isChecked () const"
.PP
Returns the actual state of the action. Definition at line 1351 of file kaction.cpp.
.PP
Referenced by plug(), and setChecked().
.SS "\fBQString\fP KToggleAction::exclusiveGroup () const"
.PP
\fBReturns:\fP
.RS 4
which 'exclusive group' this action is part of. 
.RE
.PP
\fBSee also:\fP
.RS 4
\fBsetExclusiveGroup\fP 
.RE
.PP
Definition at line 1361 of file kaction.cpp.
.PP
Referenced by setChecked().
.SS "void KToggleAction::setExclusiveGroup (const \fBQString\fP & name)\fC [virtual]\fP"
.PP
Defines which 'exclusive group' this action is part of. In a given exclusive group, only one toggle action can be checked at a any moment. Checking an action unchecks the other actions of the group. Definition at line 1356 of file kaction.cpp.
.PP
References KStdAccel::name().
.SS "void KToggleAction::setChecked (bool)\fC [virtual, slot]\fP"
.PP
Sets the state of the action. Reimplemented in \fBKToggleToolBarAction\fP.
.PP
Definition at line 1297 of file kaction.cpp.
.PP
References exclusiveGroup(), isChecked(), QString::isEmpty(), QObject::parent(), and toggled().
.PP
Referenced by KStdAction::create(), KToggleToolBarAction::setChecked(), KStdAction::showMenubar(), KStdAction::showStatusbar(), and KStdAction::showToolbar().

.SH "Author"
.PP 
Generated automatically by Doxygen for kdeui Library from the source code.
