.TH "KToolBar" kde3 "11 Jun 2005" "Version Version 3.4.1" "kdeui Library" \" -*- nroff -*-
.ad l
.nh
.SH NAME
KToolBar \- Floatable toolbar with auto resize.  

.PP
.SH SYNOPSIS
.br
.PP
\fC#include <ktoolbar.h>\fP
.PP
Inherits \fBQToolBar\fP.
.PP
.SS "Public Types"

.in +1c
.ti -1c
.RI "enum \fBIconText\fP { \fBIconOnly\fP =  0, \fBIconTextRight\fP, \fBTextOnly\fP, \fBIconTextBottom\fP }"
.br
.ti -1c
.RI "enum \fBBarStatus\fP { \fBToggle\fP, \fBShow\fP, \fBHide\fP }"
.br
.ti -1c
.RI "enum \fBBarPosition\fP { \fBUnmanaged\fP, \fBFloating\fP, \fBTop\fP, \fBBottom\fP, \fBRight\fP, \fBLeft\fP, \fBFlat\fP }"
.br
.in -1c
.SS "Public Slots"

.in +1c
.ti -1c
.RI "virtual void \fBsetIconText\fP (const \fBQString\fP &txt)"
.br
.in -1c
.SS "Signals"

.in +1c
.ti -1c
.RI "void \fBclicked\fP (int id)"
.br
.ti -1c
.RI "void \fBdoubleClicked\fP (int id)"
.br
.ti -1c
.RI "void \fBpressed\fP (int)"
.br
.ti -1c
.RI "void \fBreleased\fP (int)"
.br
.ti -1c
.RI "void \fBtoggled\fP (int)"
.br
.ti -1c
.RI "void \fBhighlighted\fP (int id, bool isHighlighted)"
.br
.ti -1c
.RI "void \fBhighlighted\fP (int id)"
.br
.ti -1c
.RI "void \fBmoved\fP (\fBBarPosition\fP)"
.br
.ti -1c
.RI "void \fBmodechange\fP ()"
.br
.ti -1c
.RI "void \fBtoolbarDestroyed\fP ()"
.br
.in -1c
.SS "Public Member Functions"

.in +1c
.ti -1c
.RI "\fBKToolBar\fP (\fBQWidget\fP *parent, const char *name=0, bool honorStyle=false, bool readConfig=true)"
.br
.ti -1c
.RI "\fBKToolBar\fP (\fBQMainWindow\fP *parentWindow, QMainWindow::ToolBarDock dock, bool newLine=false, const char *name=0, bool honorStyle=false, bool readConfig=true)"
.br
.ti -1c
.RI "\fBKToolBar\fP (\fBQMainWindow\fP *parentWindow, \fBQWidget\fP *dock, bool newLine=false, const char *name=0, bool honorStyle=false, bool readConfig=true)"
.br
.ti -1c
.RI "virtual \fB~KToolBar\fP ()"
.br
.ti -1c
.RI "int \fBinsertButton\fP (const \fBQString\fP &icon, int id, bool enabled=true, const \fBQString\fP &text=QString::null, int index=-1, \fBKInstance\fP *_instance=\fBKGlobal::instance\fP())"
.br
.ti -1c
.RI "int \fBinsertButton\fP (const \fBQString\fP &icon, int id, const char *signal, const \fBQObject\fP *receiver, const char *slot, bool enabled=true, const \fBQString\fP &text=QString::null, int index=-1, \fBKInstance\fP *_instance=\fBKGlobal::instance\fP())"
.br
.ti -1c
.RI "int \fBinsertButton\fP (const \fBQPixmap\fP &pixmap, int id, bool enabled=true, const \fBQString\fP &text=QString::null, int index=-1)"
.br
.ti -1c
.RI "int \fBinsertButton\fP (const \fBQPixmap\fP &pixmap, int id, const char *signal, const \fBQObject\fP *receiver, const char *slot, bool enabled=true, const \fBQString\fP &text=QString::null, int index=-1)"
.br
.ti -1c
.RI "int \fBinsertButton\fP (const \fBQString\fP &icon, int id, \fBQPopupMenu\fP *popup, bool enabled, const \fBQString\fP &_text, int index=-1)"
.br
.ti -1c
.RI "int \fBinsertButton\fP (const \fBQPixmap\fP &pixmap, int id, \fBQPopupMenu\fP *popup, bool enabled, const \fBQString\fP &_text, int index=-1)"
.br
.ti -1c
.RI "int \fBinsertLined\fP (const \fBQString\fP &text, int id, const char *signal, const \fBQObject\fP *receiver, const char *slot, bool enabled=true, const \fBQString\fP &toolTipText=QString::null, int size=70, int index=-1)"
.br
.ti -1c
.RI "int \fBinsertCombo\fP (const \fBQStringList\fP &list, int id, bool writable, const char *signal, const \fBQObject\fP *receiver, const char *slot, bool enabled=true, const \fBQString\fP &tooltiptext=QString::null, int size=70, int index=-1, QComboBox::Policy policy=QComboBox::AtBottom)"
.br
.ti -1c
.RI "int \fBinsertCombo\fP (const \fBQString\fP &text, int id, bool writable, const char *signal, \fBQObject\fP *receiver, const char *slot, bool enabled=true, const \fBQString\fP &tooltiptext=QString::null, int size=70, int index=-1, QComboBox::Policy policy=QComboBox::AtBottom)"
.br
.ti -1c
.RI "int \fBinsertSeparator\fP (int index=-1, int id=-1)"
.br
.ti -1c
.RI "int \fBinsertLineSeparator\fP (int index=-1, int id=-1)"
.br
.ti -1c
.RI "int \fBinsertWidget\fP (int id, int width, \fBQWidget\fP *_widget, int index=-1)"
.br
.ti -1c
.RI "int \fBinsertAnimatedWidget\fP (int id, \fBQObject\fP *receiver, const char *slot, const \fBQString\fP &icons, int index=-1)"
.br
.ti -1c
.RI "\fBKAnimWidget\fP * \fBanimatedWidget\fP (int id)"
.br
.ti -1c
.RI "void \fBaddConnection\fP (int id, const char *signal, const \fBQObject\fP *receiver, const char *slot)"
.br
.ti -1c
.RI "void \fBsetItemEnabled\fP (int id, bool enabled)"
.br
.ti -1c
.RI "void \fBsetButtonIcon\fP (int id, const \fBQString\fP &_icon)"
.br
.ti -1c
.RI "void \fBsetButtonPixmap\fP (int id, const \fBQPixmap\fP &_pixmap)"
.br
.ti -1c
.RI "void \fBsetButtonIconSet\fP (int id, const \fBQIconSet\fP &iconset)"
.br
.ti -1c
.RI "void \fBsetDelayedPopup\fP (int id, \fBQPopupMenu\fP *_popup, bool toggle=false)"
.br
.ti -1c
.RI "void \fBsetAutoRepeat\fP (int id, bool flag=true)"
.br
.ti -1c
.RI "void \fBsetToggle\fP (int id, bool flag=true)"
.br
.ti -1c
.RI "void \fBtoggleButton\fP (int id)"
.br
.ti -1c
.RI "void \fBsetButton\fP (int id, bool flag)"
.br
.ti -1c
.RI "bool \fBisButtonOn\fP (int id) const "
.br
.ti -1c
.RI "void \fBsetLinedText\fP (int id, const \fBQString\fP &text)"
.br
.ti -1c
.RI "\fBQString\fP \fBgetLinedText\fP (int id) const "
.br
.ti -1c
.RI "void \fBinsertComboItem\fP (int id, const \fBQString\fP &text, int index)"
.br
.ti -1c
.RI "void \fBinsertComboList\fP (int id, const \fBQStringList\fP &list, int index)"
.br
.ti -1c
.RI "void \fBremoveComboItem\fP (int id, int index)"
.br
.ti -1c
.RI "void \fBsetCurrentComboItem\fP (int id, int index)"
.br
.ti -1c
.RI "void \fBchangeComboItem\fP (int id, const \fBQString\fP &text, int index=-1)"
.br
.ti -1c
.RI "void \fBclearCombo\fP (int id)"
.br
.ti -1c
.RI "\fBQString\fP \fBgetComboItem\fP (int id, int index=-1) const "
.br
.ti -1c
.RI "\fBKComboBox\fP * \fBgetCombo\fP (int id)"
.br
.ti -1c
.RI "\fBKLineEdit\fP * \fBgetLined\fP (int id)"
.br
.ti -1c
.RI "\fBKToolBarButton\fP * \fBgetButton\fP (int id)"
.br
.ti -1c
.RI "void \fBalignItemRight\fP (int id, bool right=true)"
.br
.ti -1c
.RI "\fBQWidget\fP * \fBgetWidget\fP (int id)"
.br
.ti -1c
.RI "void \fBsetItemAutoSized\fP (int id, bool yes=true)"
.br
.ti -1c
.RI "void \fBclear\fP ()"
.br
.ti -1c
.RI "void \fBremoveItem\fP (int id)"
.br
.ti -1c
.RI "void \fBremoveItemDelayed\fP (int id)"
.br
.ti -1c
.RI "void \fBhideItem\fP (int id)"
.br
.ti -1c
.RI "void \fBshowItem\fP (int id)"
.br
.ti -1c
.RI "int \fBitemIndex\fP (int id)"
.br
.ti -1c
.RI "int \fBidAt\fP (int index)"
.br
.ti -1c
.RI "void \fBsetFullSize\fP (bool flag=true)"
.br
.ti -1c
.RI "bool \fBfullSize\fP () const "
.br
.ti -1c
.RI "void \fBenableMoving\fP (bool flag=true) KDE_DEPRECATED"
.br
.ti -1c
.RI "void \fBsetBarPos\fP (\fBBarPosition\fP bpos)"
.br
.ti -1c
.RI "\fBBarPosition\fP \fBbarPos\fP () const "
.br
.ti -1c
.RI "bool \fBenable\fP (\fBBarStatus\fP stat) KDE_DEPRECATED"
.br
.ti -1c
.RI "void \fBsetMaxHeight\fP (int h) KDE_DEPRECATED"
.br
.ti -1c
.RI "int \fBmaxHeight\fP () KDE_DEPRECATED"
.br
.ti -1c
.RI "void \fBsetMaxWidth\fP (int dw) KDE_DEPRECATED"
.br
.ti -1c
.RI "int \fBmaxWidth\fP () KDE_DEPRECATED"
.br
.ti -1c
.RI "void \fBsetTitle\fP (const \fBQString\fP &_title)"
.br
.ti -1c
.RI "void \fBenableFloating\fP (bool flag) KDE_DEPRECATED"
.br
.ti -1c
.RI "void \fBsetIconText\fP (IconText it)"
.br
.ti -1c
.RI "void \fBsetIconText\fP (IconText it, bool update)"
.br
.ti -1c
.RI "IconText \fBiconText\fP () const "
.br
.ti -1c
.RI "void \fBsetIconSize\fP (int size)"
.br
.ti -1c
.RI "void \fBsetIconSize\fP (int size, bool update)"
.br
.ti -1c
.RI "int \fBiconSize\fP () const "
.br
.ti -1c
.RI "int \fBiconSizeDefault\fP () const "
.br
.ti -1c
.RI "void \fBsetEnableContextMenu\fP (bool enable=true)"
.br
.ti -1c
.RI "bool \fBcontextMenuEnabled\fP () const "
.br
.ti -1c
.RI "void \fBsetItemNoStyle\fP (int id, bool no_style=true)"
.br
.ti -1c
.RI "void \fBsetFlat\fP (bool flag)"
.br
.ti -1c
.RI "int \fBcount\fP () const "
.br
.ti -1c
.RI "void \fBsaveState\fP ()"
.br
.ti -1c
.RI "void \fBsaveSettings\fP (\fBKConfig\fP *config, const \fBQString\fP &configGroup)"
.br
.ti -1c
.RI "void \fBapplySettings\fP (\fBKConfig\fP *config, const \fBQString\fP &configGroup, bool force)"
.br
.ti -1c
.RI "void \fBapplySettings\fP (\fBKConfig\fP *config, const \fBQString\fP &configGroup)"
.br
.ti -1c
.RI "void \fBsetXMLGUIClient\fP (\fBKXMLGUIClient\fP *client)"
.br
.ti -1c
.RI "void \fBsetText\fP (const \fBQString\fP &txt)"
.br
.ti -1c
.RI "\fBQString\fP \fBtext\fP () const "
.br
.ti -1c
.RI "void \fBsetStretchableWidget\fP (\fBQWidget\fP *w)"
.br
.ti -1c
.RI "\fBQSizePolicy\fP \fBsizePolicy\fP () const "
.br
.ti -1c
.RI "bool \fBhighlight\fP () const "
.br
.ti -1c
.RI "\fBQSize\fP \fBsizeHint\fP () const "
.br
.ti -1c
.RI "\fBQSize\fP \fBminimumSizeHint\fP () const "
.br
.ti -1c
.RI "\fBQSize\fP \fBminimumSize\fP () const "
.br
.ti -1c
.RI "void \fBhide\fP ()"
.br
.ti -1c
.RI "void \fBshow\fP ()"
.br
.ti -1c
.RI "void \fBupdateRects\fP (bool=false)"
.br
.ti -1c
.RI "void \fBloadState\fP (const \fBQDomElement\fP &e)"
.br
.ti -1c
.RI "void \fBsaveState\fP (\fBQDomElement\fP &e)"
.br
.ti -1c
.RI "void \fBpositionYourself\fP (bool force=false)"
.br
.in -1c
.SS "Static Public Member Functions"

.in +1c
.ti -1c
.RI "static bool \fBhighlightSetting\fP ()"
.br
.ti -1c
.RI "static bool \fBtransparentSetting\fP ()"
.br
.ti -1c
.RI "static IconText \fBiconTextSetting\fP ()"
.br
.in -1c
.SS "Protected Member Functions"

.in +1c
.ti -1c
.RI "void \fBmousePressEvent\fP (\fBQMouseEvent\fP *)"
.br
.ti -1c
.RI "void \fBchildEvent\fP (\fBQChildEvent\fP *e)"
.br
.ti -1c
.RI "void \fBshowEvent\fP (\fBQShowEvent\fP *e)"
.br
.ti -1c
.RI "void \fBresizeEvent\fP (\fBQResizeEvent\fP *e)"
.br
.ti -1c
.RI "bool \fBevent\fP (\fBQEvent\fP *e)"
.br
.ti -1c
.RI "void \fBapplyAppearanceSettings\fP (\fBKConfig\fP *config, const \fBQString\fP &_configGroup, bool forceGlobal=false)"
.br
.ti -1c
.RI "\fBQString\fP \fBsettingsGroup\fP () const "
.br
.ti -1c
.RI "virtual void \fBvirtual_hook\fP (int id, void *data)"
.br
.in -1c
.SS "Properties"

.in +1c
.ti -1c
.RI "IconText \fBiconText\fP"
.br
.ti -1c
.RI "\fBBarPosition\fP \fBbarPos\fP"
.br
.ti -1c
.RI "bool \fBfullSize\fP"
.br
.ti -1c
.RI "int \fBiconSize\fP"
.br
.ti -1c
.RI "\fBQString\fP \fBtext\fP"
.br
.in -1c
.SH "Detailed Description"
.PP 
Floatable toolbar with auto resize. 

A KDE-style toolbar.
.PP
KToolBar can be dragged around in and between different docks.
.PP
A KToolBar can contain all sorts of widgets.
.PP
KToolBar can be used as a standalone widget, but \fBKMainWindow\fP provides easy factories and management of one or more toolbars. Once you have a KToolBar object, you can insert items into it with the insert... methods, or remove them with the \fBremoveItem()\fP method. This can be done at any time; the toolbar will be automatically updated. There are also many methods to set per-child properties like alignment and toggle behavior.
.PP
KToolBar uses a global config group to load toolbar settings on construction. It will reread this config group on a \fBKApplication::appearanceChanged()\fP signal.
.PP
\fBAuthor:\fP
.RS 4
Reginald Stadlbauer <reggie@kde.org>, Stephan Kulow <coolo@kde.org>, Sven Radej <radej@kde.org>. 
.RE
.PP

.PP
Definition at line 103 of file ktoolbar.h.
.SH "Member Enumeration Documentation"
.PP 
.SS "enum \fBKToolBar::BarStatus\fP"
.PP
The state of the status bar. 
.PP
\fBDeprecated\fP
.RS 4
.RE
.PP

.PP
Definition at line 119 of file ktoolbar.h.
.SS "enum \fBKToolBar::BarPosition\fP"
.PP
Possible bar positions. 
.PP
Definition at line 123 of file ktoolbar.h.
.SH "Constructor & Destructor Documentation"
.PP 
.SS "KToolBar::KToolBar (\fBQWidget\fP * parent, const char * name = \fC0\fP, bool honorStyle = \fCfalse\fP, bool readConfig = \fCtrue\fP)"
.PP
Normal constructor. 
.PP
This constructor is used by the XML-GUI. If you use it, you need to call QMainWindow::addToolBar to specify the position of the toolbar. So it's simpler to use the other constructor.
.PP
The toolbar will read in various global config settings for things like icon size and text position, etc. However, some of the settings will be honored only if \fChonorStyle\fP is set to true. All other toolbars will be IconOnly and use Medium icons.
.PP
\fBParameters:\fP
.RS 4
\fIparent\fP The standard toolbar parent (usually a \fBKMainWindow\fP) 
.br
\fIname\fP The standard internal name 
.br
\fIhonorStyle\fP If true, then global settings for IconSize and IconText will be honored 
.br
\fIreadConfig\fP whether to apply the configuration (global and application-specific) 
.RE
.PP

.PP
Definition at line 195 of file ktoolbar.cpp.
.SS "KToolBar::KToolBar (\fBQMainWindow\fP * parentWindow, QMainWindow::ToolBarDock dock, bool newLine = \fCfalse\fP, const char * name = \fC0\fP, bool honorStyle = \fCfalse\fP, bool readConfig = \fCtrue\fP)"
.PP
Constructor for non-XML-GUI applications. 
.PP
The toolbar will read in various global config settings for things like icon size and text position, etc. However, some of the settings will be honored only if \fChonorStyle\fP is set to true. All other toolbars will be IconOnly and use Medium icons.
.PP
\fBParameters:\fP
.RS 4
\fIparentWindow\fP The window that should be the parent of this toolbar 
.br
\fIdock\fP The position of the toolbar. Usually QMainWindow::Top. 
.br
\fInewLine\fP If true, start a new line in the dock for this toolbar. 
.br
\fIname\fP The standard internal name 
.br
\fIhonorStyle\fP If true, then global settings for IconSize and IconText will be honored 
.br
\fIreadConfig\fP whether to apply the configuration (global and application-specific) 
.RE
.PP

.PP
Definition at line 204 of file ktoolbar.cpp.
.SS "KToolBar::KToolBar (\fBQMainWindow\fP * parentWindow, \fBQWidget\fP * dock, bool newLine = \fCfalse\fP, const char * name = \fC0\fP, bool honorStyle = \fCfalse\fP, bool readConfig = \fCtrue\fP)"
.PP
Constructor for non-XML-GUI applications. 
.PP
The toolbar will read in various global config settings for things like icon size and text position, etc. However, some of the settings will be honored only if \fChonorStyle\fP is set to true. All other toolbars will be IconOnly and use Medium icons.
.PP
\fBParameters:\fP
.RS 4
\fIparentWindow\fP The window that should be the parent of this toolbar 
.br
\fIdock\fP Another widget than the mainwindow to dock toolbar to. 
.br
\fInewLine\fP If true, start a new line in the dock for this toolbar. 
.br
\fIname\fP The standard internal name 
.br
\fIhonorStyle\fP If true, then global settings for IconSize and IconText will be honored 
.br
\fIreadConfig\fP whether to apply the configuration (global and application-specific) 
.RE
.PP

.PP
Definition at line 212 of file ktoolbar.cpp.
.SS "KToolBar::~\fBKToolBar\fP ()\fC [virtual]\fP"
.PP
Destructor. 
.PP
Definition at line 220 of file ktoolbar.cpp.
.PP
References toolbarDestroyed().
.SH "Member Function Documentation"
.PP 
.SS "int KToolBar::insertButton (const \fBQString\fP & icon, int id, bool enabled = \fCtrue\fP, const \fBQString\fP & text = \fCQString::null\fP, int index = \fC-1\fP, \fBKInstance\fP * _instance = \fC\fBKGlobal::instance\fP()\fP)"
.PP
Insert a button (a \fBKToolBarButton\fP) with a pixmap. 
.PP
The pixmap is loaded by the button itself based on the global icon settings.
.PP
You should connect to one or more signals in KToolBar: \fBclicked()\fP , \fBpressed()\fP , \fBreleased()\fP , or \fBhighlighted()\fP and if the button is a toggle button ( \fBsetToggle()\fP ) \fBtoggled()\fP . Those signals have \fCid\fP of a button that caused the signal. If you want to bind a popup to button, see \fBsetButton()\fP.
.PP
\fBParameters:\fP
.RS 4
\fIicon\fP The name of the icon to use as the active pixmap 
.br
\fIid\fP The id of this button 
.br
\fIenabled\fP Enable or disable the button at startup 
.br
\fItext\fP The tooltip or toolbar text (depending on state) 
.br
\fIindex\fP The position of the button. (-1 = at end). 
.br
\fI_instance\fP instance this button will belong to
.RE
.PP
\fBReturns:\fP
.RS 4
The item index. 
.RE
.PP

.PP
Definition at line 257 of file ktoolbar.cpp.
.PP
Referenced by KPasteTextAction::plug(), KToolBarPopupAction::plug(), KActionMenu::plug(), KRecentFilesAction::plug(), and KAction::plug().
.SS "int KToolBar::insertButton (const \fBQString\fP & icon, int id, const char * signal, const \fBQObject\fP * receiver, const char * slot, bool enabled = \fCtrue\fP, const \fBQString\fP & text = \fCQString::null\fP, int index = \fC-1\fP, \fBKInstance\fP * _instance = \fC\fBKGlobal::instance\fP()\fP)"
.PP
This is the same as above, but with specified signals and slots to which this button will be connected. 
.PP
You can add more signals with \fBaddConnection()\fP.
.PP
\fBParameters:\fP
.RS 4
\fIicon\fP The name of the icon to use as the active pixmap 
.br
\fIid\fP The id of this button 
.br
\fIsignal\fP The signal to connect to 
.br
\fIreceiver\fP The slot's parent 
.br
\fIslot\fP The slot to receive the signal specified in that argument. 
.br
\fIenabled\fP Enable or disable the button at startup 
.br
\fItext\fP The tooltip or toolbar text (depending on state) 
.br
\fIindex\fP The position of the button. (-1 = at end). 
.br
\fI_instance\fP instance this button will belong to
.RE
.PP
\fBReturns:\fP
.RS 4
The item index. 
.RE
.PP

.PP
Definition at line 269 of file ktoolbar.cpp.
.SS "int KToolBar::insertButton (const \fBQPixmap\fP & pixmap, int id, bool enabled = \fCtrue\fP, const \fBQString\fP & text = \fCQString::null\fP, int index = \fC-1\fP)"
.PP
Inserts a button (a \fBKToolBarButton\fP) with the specified pixmap. 
.PP
This pixmap will be used as the 'active' one and the disabled and default ones will be autogenerated.
.PP
It is recommended that you use the insertButton function that allows you to specify the icon name rather then the pixmap itself. Specifying the icon name is much more flexible.
.PP
You should connect to one or more signals in KToolBar: \fBclicked()\fP , \fBpressed()\fP , \fBreleased()\fP , or \fBhighlighted()\fP and if the button is a toggle button ( \fBsetToggle()\fP ) \fBtoggled()\fP . Those signals have \fCid\fP of a button that caused the signal. If you want to bind a popup to button, see \fBsetButton()\fP.
.PP
\fBParameters:\fP
.RS 4
\fIpixmap\fP The active pixmap 
.br
\fIid\fP The id of this button 
.br
\fIenabled\fP Enable or disable the button at startup 
.br
\fItext\fP The tooltip or toolbar text (depending on state) 
.br
\fIindex\fP The position of the button. (-1 = at end).
.RE
.PP
\fBReturns:\fP
.RS 4
The item index. 
.RE
.PP

.PP
Definition at line 282 of file ktoolbar.cpp.
.SS "int KToolBar::insertButton (const \fBQPixmap\fP & pixmap, int id, const char * signal, const \fBQObject\fP * receiver, const char * slot, bool enabled = \fCtrue\fP, const \fBQString\fP & text = \fCQString::null\fP, int index = \fC-1\fP)"
.PP
This is the same as above, but with specified signals and slots to which this button will be connected. 
.PP
You can add more signals with \fBaddConnection()\fP.
.PP
\fBParameters:\fP
.RS 4
\fIpixmap\fP The name of the icon to use as the active pixmap 
.br
\fIid\fP The id of this button 
.br
\fIsignal\fP The signal to connect to 
.br
\fIreceiver\fP The slot's parent 
.br
\fIslot\fP The slot to receive the signal specified in that argument. 
.br
\fIenabled\fP Enable or disable the button at startup 
.br
\fItext\fP The tooltip or toolbar text (depending on state) 
.br
\fIindex\fP The position of the button. (-1 = at end).
.RE
.PP
\fBReturns:\fP
.RS 4
The item index. 
.RE
.PP

.PP
Definition at line 293 of file ktoolbar.cpp.
.SS "int KToolBar::insertButton (const \fBQString\fP & icon, int id, \fBQPopupMenu\fP * popup, bool enabled, const \fBQString\fP & _text, int index = \fC-1\fP)"
.PP
Inserts a button with popupmenu. 
.PP
Button will have small triangle. You have to connect to popup's signals. The signals KButton::pressed(), KButton::released(), KButton::clicked() or KButton::doubleClicked() are \fCnot\fP emmited by this button (see \fBsetDelayedPopup()\fP for that). You can add custom popups which inherit \fBQPopupMenu\fP to get popups with tables, drawings etc. Just don't fiddle with events there. 
.PP
Definition at line 307 of file ktoolbar.cpp.
.PP
References KToolBarButton::setPopup().
.SS "int KToolBar::insertButton (const \fBQPixmap\fP & pixmap, int id, \fBQPopupMenu\fP * popup, bool enabled, const \fBQString\fP & _text, int index = \fC-1\fP)"
.PP
Inserts a button with popupmenu. 
.PP
Button will have small triangle. You have to connect to popup's signals. The signals KButton::pressed(), KButton::released(), KButton::clicked() or KButton::doubleClicked() are \fCnot\fP emmited by this button (see \fBsetDelayedPopup()\fP for that). You can add custom popups which inherit \fBQPopupMenu\fP to get popups with tables, drawings etc. Just don't fiddle with events there. 
.PP
Definition at line 319 of file ktoolbar.cpp.
.PP
References KToolBarButton::setPopup().
.SS "int KToolBar::insertLined (const \fBQString\fP & text, int id, const char * signal, const \fBQObject\fP * receiver, const char * slot, bool enabled = \fCtrue\fP, const \fBQString\fP & toolTipText = \fCQString::null\fP, int size = \fC70\fP, int index = \fC-1\fP)"
.PP
Inserts a \fBKLineEdit\fP. 
.PP
You have to specify signals and slots to which \fBKLineEdit\fP will be connected. \fBKLineEdit\fP has all slots \fBQLineEdit\fP has, plus signals \fBKLineEdit::completion\fP and \fBKLineEdit::textRotation\fP \fBKLineEdit\fP can be set to autoresize itself to full free width in toolbar, that is to last right aligned item. For that, toolbar must be set to full width (which it is by default). 
.PP
\fBSee also:\fP
.RS 4
setFullWidth() 
.PP
\fBsetItemAutoSized()\fP 
.PP
\fBKLineEdit\fP 
.RE
.PP
\fBReturns:\fP
.RS 4
Item index. 
.RE
.PP

.PP
Definition at line 331 of file ktoolbar.cpp.
.PP
References QToolTip::add(), and KLineEdit::setText().
.SS "int KToolBar::insertCombo (const \fBQStringList\fP & list, int id, bool writable, const char * signal, const \fBQObject\fP * receiver, const char * slot, bool enabled = \fCtrue\fP, const \fBQString\fP & tooltiptext = \fCQString::null\fP, int size = \fC70\fP, int index = \fC-1\fP, QComboBox::Policy policy = \fCQComboBox::AtBottom\fP)"
.PP
Inserts a \fBKComboBox\fP with list. 
.PP
Can be writable, but cannot contain pixmaps. By default inserting policy is AtBottom, i.e. typed items are placed at the bottom of the list. Can be autosized. If the size argument is specified as -1, the width of the combobox is automatically computed.
.PP
\fBSee also:\fP
.RS 4
setFullWidth() 
.PP
\fBsetItemAutoSized()\fP 
.PP
\fBKComboBox\fP 
.RE
.PP
\fBReturns:\fP
.RS 4
Item index. 
.RE
.PP

.PP
Definition at line 350 of file ktoolbar.cpp.
.PP
References QToolTip::add(), QComboBox::insertStringList(), and QComboBox::setInsertionPolicy().
.PP
Referenced by KSelectAction::plug().
.SS "int KToolBar::insertCombo (const \fBQString\fP & text, int id, bool writable, const char * signal, \fBQObject\fP * receiver, const char * slot, bool enabled = \fCtrue\fP, const \fBQString\fP & tooltiptext = \fCQString::null\fP, int size = \fC70\fP, int index = \fC-1\fP, QComboBox::Policy policy = \fCQComboBox::AtBottom\fP)"
.PP
Insert a \fBKComboBox\fP with text. 
.PP
The rest is the same as above. 
.PP
\fBSee also:\fP
.RS 4
\fBsetItemAutoSized()\fP
.PP
\fBKComboBox\fP 
.RE
.PP
\fBReturns:\fP
.RS 4
Item index. 
.RE
.PP

.PP
Definition at line 374 of file ktoolbar.cpp.
.PP
References QToolTip::add(), QComboBox::insertItem(), and QComboBox::setInsertionPolicy().
.SS "int KToolBar::insertSeparator (int index = \fC-1\fP, int id = \fC-1\fP)"
.PP
Inserts a separator into the toolbar with the given \fCid\fP. 
.PP
\fBReturns:\fP
.RS 4
the separator's index 
.RE
.PP

.PP
Definition at line 394 of file ktoolbar.cpp.
.SS "int KToolBar::insertLineSeparator (int index = \fC-1\fP, int id = \fC-1\fP)"
.PP
Inserts a line separator into the toolbar with the given \fCid\fP. 
.PP
\fBReturns:\fP
.RS 4
the separator's index 
.RE
.PP

.PP
Definition at line 401 of file ktoolbar.cpp.
.SS "int KToolBar::insertWidget (int id, int width, \fBQWidget\fP * _widget, int index = \fC-1\fP)"
.PP
Inserts a user-defined widget. 
.PP
The widget \fCmust\fP have this toolbar as its parent.
.PP
Widget must have a \fBQWidget\fP for base class. Widget can be autosized to full width. If you forget about it, you can get a pointer to this widget with \fBgetWidget()\fP. 
.PP
\fBSee also:\fP
.RS 4
\fBsetItemAutoSized()\fP 
.RE
.PP
\fBReturns:\fP
.RS 4
Item index. 
.RE
.PP

.PP
Definition at line 409 of file ktoolbar.cpp.
.PP
Referenced by KWidgetAction::plug().
.SS "int KToolBar::insertAnimatedWidget (int id, \fBQObject\fP * receiver, const char * slot, const \fBQString\fP & icons, int index = \fC-1\fP)"
.PP
Inserts an animated widget. 
.PP
A \fBKAnimWidget\fP will be created internally using the icon name you provide. This will emit a signal (\fBclicked()\fP) whenever the animation widget is clicked.
.PP
\fBSee also:\fP
.RS 4
\fBanimatedWidget()\fP
.RE
.PP
\fBParameters:\fP
.RS 4
\fIid\fP The id for this toolbar item 
.br
\fIreceiver\fP The parent of your slot 
.br
\fIslot\fP The slot to receive the \fBclicked()\fP signal 
.br
\fIicons\fP The name of the animation icon group to use 
.br
\fIindex\fP The item index
.RE
.PP
\fBReturns:\fP
.RS 4
The item index 
.RE
.PP

.PP
Definition at line 416 of file ktoolbar.cpp.
.PP
References clicked().
.SS "\fBKAnimWidget\fP * KToolBar::animatedWidget (int id)"
.PP
This will return a pointer to the animated widget with the given \fCid\fP, if it exists. 
.PP
\fBSee also:\fP
.RS 4
\fBinsertAnimatedWidget\fP 
.RE
.PP
\fBParameters:\fP
.RS 4
\fIid\fP The id for the widget you want to get a pointer to 
.RE
.PP
\fBReturns:\fP
.RS 4
A pointer to the current animated widget or 0L 
.RE
.PP

.PP
Definition at line 428 of file ktoolbar.cpp.
.PP
References QMap::end(), and QMap::find().
.SS "void KToolBar::addConnection (int id, const char * signal, const \fBQObject\fP * receiver, const char * slot)"
.PP
Adds connections to items. 
.PP
It is important that you know the \fCid\fP of particular item. Nothing happens if you forget \fCid\fP. 
.PP
Definition at line 456 of file ktoolbar.cpp.
.PP
References getWidget().
.SS "void KToolBar::setItemEnabled (int id, bool enabled)"
.PP
Enables/disables item. 
.PP
Definition at line 464 of file ktoolbar.cpp.
.PP
References getWidget(), and QWidget::setEnabled().
.SS "void KToolBar::setButtonIcon (int id, const \fBQString\fP & _icon)"
.PP
Sets the icon for a button. 
.PP
Can be used while button is visible. 
.PP
Definition at line 480 of file ktoolbar.cpp.
.PP
References getButton(), and KToolBarButton::setIcon().
.SS "void KToolBar::setButtonPixmap (int id, const \fBQPixmap\fP & _pixmap)"
.PP
Sets button pixmap. 
.PP
Can be used while button is visible. 
.PP
Definition at line 472 of file ktoolbar.cpp.
.PP
References getButton(), and KToolBarButton::setPixmap().
.SS "void KToolBar::setButtonIconSet (int id, const \fBQIconSet\fP & iconset)"
.PP
Sets a button icon from a \fBQIconSet\fP. 
.PP
Can be used while button is visible. 
.PP
Definition at line 487 of file ktoolbar.cpp.
.PP
References getButton(), and KToolBarButton::setIconSet().
.SS "void KToolBar::setDelayedPopup (int id, \fBQPopupMenu\fP * _popup, bool toggle = \fCfalse\fP)"
.PP
Sets a delayed popup for a button. 
.PP
Delayed popup is what you see in Netscape Navigator's Previous and Next buttons: If you click them you go back or forth. If you press them long enough, you get a history-menu. This is exactly what we do here.
.PP
You will insert a normal button with connection (or use signals from toolbar): 
.PP
.nf
 bar->insertButton(icon, id, SIGNAL(clicked ()), this,
                   SLOT (slotClick()), true, 'click or wait for popup');

.fi
.PP
 And then add a delayed popup: 
.PP
.nf
 bar->setDelayedPopup (id, historyPopup);

.fi
.PP
.PP
Don't add delayed popups to buttons which have normal popups.
.PP
You may add popups which are derived from \fBQPopupMenu\fP. You may add popups that are already in the menu bar or are submenus of other popups. 
.PP
Definition at line 495 of file ktoolbar.cpp.
.PP
References getButton(), and KToolBarButton::setDelayedPopup().
.PP
Referenced by KPasteTextAction::plug(), KToolBarPopupAction::plug(), KActionMenu::plug(), and KRecentFilesAction::plug().
.SS "void KToolBar::setAutoRepeat (int id, bool flag = \fCtrue\fP)"
.PP
Turns a button into an autorepeat button. 
.PP
Toggle buttons, buttons with menus, or buttons with delayed menus cannot be made into autorepeat buttons. Moreover, you can and will receive only the signal \fBclicked()\fP, but not \fBpressed()\fP or \fBreleased()\fP. When the user presses this button, you will receive the signal \fBclicked()\fP, and if the button is still pressed after some time, you will receive more \fBclicked()\fP signals separated by regular intervals. Since this uses \fBQButton::setAutoRepeat()\fP , I can't quantify 'some'. 
.PP
Definition at line 503 of file ktoolbar.cpp.
.PP
References getButton().
.SS "void KToolBar::setToggle (int id, bool flag = \fCtrue\fP)"
.PP
Turns button into a toggle button if \fCflag\fP is true. 
.PP
Definition at line 511 of file ktoolbar.cpp.
.PP
References getButton(), and KToolBarButton::setToggle().
.PP
Referenced by KToggleAction::plug().
.SS "void KToolBar::toggleButton (int id)"
.PP
Toggles a togglebutton. 
.PP
If the button is a toggle button (see \fBsetToggle()\fP) the button state will be toggled. This will also cause the toolbar to emit the signal KButton::toggled() with parameter \fCid\fP. You must connect to this signal, or use \fBaddConnection()\fP to connect directly to the button signal KButton::toggled(). 
.PP
Definition at line 519 of file ktoolbar.cpp.
.PP
References getButton(), and KToolBarButton::toggle().
.SS "void KToolBar::setButton (int id, bool flag)"
.PP
Sets a toggle button state. 
.PP
If the button is a toggle button (see \fBsetToggle()\fP) this will set its state flag. This will also emit the signal KButton::toggled().
.PP
\fBSee also:\fP
.RS 4
\fBsetToggle()\fP 
.RE
.PP

.PP
Definition at line 527 of file ktoolbar.cpp.
.PP
References getButton(), and KToolBarButton::on().
.PP
Referenced by KToggleAction::plug().
.SS "bool KToolBar::isButtonOn (int id) const"
.PP
Returns \fCtrue\fP if button is on and is a toggle button. 
.PP
\fBReturns:\fP
.RS 4
\fCtrue\fP if button is on and is a toggle button 
.RE
.PP
\fBSee also:\fP
.RS 4
\fBsetToggle()\fP 
.RE
.PP

.PP
Definition at line 535 of file ktoolbar.cpp.
.SS "void KToolBar::setLinedText (int id, const \fBQString\fP & text)"
.PP
Sets the text of a line editor. 
.PP
Cursor is set at end of text. 
.PP
Definition at line 542 of file ktoolbar.cpp.
.PP
References getLined(), and KLineEdit::setText().
.SS "\fBQString\fP KToolBar::getLinedText (int id) const"
.PP
Returns the line editor text. 
.PP
\fBReturns:\fP
.RS 4
the line editor text. 
.RE
.PP

.PP
Definition at line 550 of file ktoolbar.cpp.
.PP
References QLineEdit::text().
.SS "void KToolBar::insertComboItem (int id, const \fBQString\fP & text, int index)"
.PP
Inserts \fCtext\fP in combobox \fCid\fP at position \fCindex\fP. 
.PP
Definition at line 557 of file ktoolbar.cpp.
.PP
References getCombo(), and QComboBox::insertItem().
.SS "void KToolBar::insertComboList (int id, const \fBQStringList\fP & list, int index)"
.PP
Inserts \fClist\fP in combobox \fCid\fP at position \fCindex\fP. 
.PP
Definition at line 564 of file ktoolbar.cpp.
.PP
References getCombo(), and QComboBox::insertStringList().
.SS "void KToolBar::removeComboItem (int id, int index)"
.PP
Removes item \fCindex\fP from combobox \fCid\fP. 
.PP
Definition at line 572 of file ktoolbar.cpp.
.PP
References getCombo(), and QComboBox::removeItem().
.SS "void KToolBar::setCurrentComboItem (int id, int index)"
.PP
Sets item \fCindex\fP to be current item in combobox \fCid\fP. 
.PP
Definition at line 580 of file ktoolbar.cpp.
.PP
References getCombo(), and KComboBox::setCurrentItem().
.SS "void KToolBar::changeComboItem (int id, const \fBQString\fP & text, int index = \fC-1\fP)"
.PP
Changes item \fCindex\fP in combobox \fCid\fP to text. 
.PP
\fCindex\fP = -1 refers current item (one displayed in the button). 
.PP
Definition at line 588 of file ktoolbar.cpp.
.PP
References QComboBox::changeItem(), and getCombo().
.SS "void KToolBar::clearCombo (int id)"
.PP
Clears the combobox \fCid\fP. 
.PP
Does not delete it or hide it. 
.PP
Definition at line 596 of file ktoolbar.cpp.
.PP
References QComboBox::clear(), and getCombo().
.SS "\fBQString\fP KToolBar::getComboItem (int id, int index = \fC-1\fP) const"
.PP
Returns text of item \fCindex\fP from combobox \fCid\fP. 
.PP
\fBReturns:\fP
.RS 4
text of item \fCindex\fP from combobox \fCid\fP.
.RE
.PP
\fCindex\fP = -1 refers to current item. 
.PP
Definition at line 604 of file ktoolbar.cpp.
.PP
References QComboBox::text().
.SS "\fBKComboBox\fP * KToolBar::getCombo (int id)"
.PP
Returns a pointer to the combobox with \fCid\fP. 
.PP
\fBReturns:\fP
.RS 4
a pointer to the combobox with \fCid\fP.
.RE
.PP
Example: 
.PP
.nf
 KComboBox *combo = toolbar->getCombo(combo_id);

.fi
.PP
 That way you can get access to other public methods that \fBKComboBox\fP provides. 
.PP
Definition at line 611 of file ktoolbar.cpp.
.PP
References QMap::end(), and QMap::find().
.PP
Referenced by changeComboItem(), clearCombo(), insertComboItem(), insertComboList(), KSelectAction::plug(), removeComboItem(), and setCurrentComboItem().
.SS "\fBKLineEdit\fP * KToolBar::getLined (int id)"
.PP
Returns a pointer to KToolBarLined with \fCid\fP. 
.PP
\fBReturns:\fP
.RS 4
a pointer to KToolBarLined with \fCid\fP.
.RE
.PP
Example: 
.PP
.nf
 KLineEdit * lined = toolbar->getKToolBarLined(lined_id);

.fi
.PP
 That way you can get access to other public methods that \fBKLineEdit\fP provides. \fBKLineEdit\fP is the same thing as \fBQLineEdit\fP plus completion signals. 
.PP
Definition at line 620 of file ktoolbar.cpp.
.PP
References QMap::end(), and QMap::find().
.PP
Referenced by setLinedText().
.SS "\fBKToolBarButton\fP * KToolBar::getButton (int id)"
.PP
Returns a pointer to \fBKToolBarButton\fP. 
.PP
Example: 
.PP
.nf
 KToolBarButton * button = toolbar->getButton(button_id);

.fi
.PP
 That way you can get access to other public methods that \fBKToolBarButton\fP provides.
.PP
Using this method is not recommended. 
.PP
Definition at line 629 of file ktoolbar.cpp.
.PP
References QMap::end(), and QMap::find().
.PP
Referenced by KToolBarRadioGroup::addButton(), KPasteTextAction::plug(), KToolBarPopupAction::plug(), KActionMenu::plug(), KRecentFilesAction::plug(), KAction::plug(), setAutoRepeat(), setButton(), setButtonIcon(), setButtonIconSet(), setButtonPixmap(), setDelayedPopup(), setItemNoStyle(), setToggle(), and toggleButton().
.SS "void KToolBar::alignItemRight (int id, bool right = \fCtrue\fP)"
.PP
Align item to the right. 
.PP
This works only if toolbar is set to full width. 
.PP
\fBSee also:\fP
.RS 4
setFullWidth() 
.RE
.PP

.PP
Definition at line 638 of file ktoolbar.cpp.
.PP
References QMap::end(), and QMap::find().
.SS "\fBQWidget\fP * KToolBar::getWidget (int id)"
.PP
Returns a pointer to the widget corresponding to \fCid\fP. 
.PP
\fBReturns:\fP
.RS 4
a pointer to the widget corresponding to \fCid\fP.
.RE
.PP
Wrong ids are not tested. You can do with this whatever you want, except change its height (hardcoded). If you change its width you will probably have to call QToolBar::updateRects(true) 
.PP
\fBSee also:\fP
.RS 4
\fBQWidget\fP 
.PP
updateRects() 
.RE
.PP

.PP
Definition at line 650 of file ktoolbar.cpp.
.PP
References QMap::end(), and QMap::find().
.PP
Referenced by addConnection(), hideItem(), itemIndex(), setItemAutoSized(), setItemEnabled(), and showItem().
.SS "void KToolBar::setItemAutoSized (int id, bool yes = \fCtrue\fP)"
.PP
Set item autosized. 
.PP
This works only if the toolbar is set to full width. Only \fCone\fP item can be autosized, and it has to be the last left-aligned item. Items that come after this must be right aligned. Items that can be right aligned are Lineds, Frames, Widgets and Combos. An autosized item will resize itself whenever the toolbar geometry changes to the last right-aligned item (or to end of toolbar if there are no right-aligned items.) 
.PP
\fBSee also:\fP
.RS 4
setFullWidth() 
.PP
\fBalignItemRight()\fP 
.RE
.PP

.PP
Definition at line 657 of file ktoolbar.cpp.
.PP
References getWidget(), and QToolBar::setStretchableWidget().
.PP
Referenced by KWidgetAction::plug().
.SS "void KToolBar::clear ()"
.PP
Remove all items. 
.PP
The toolbar is redrawn after it. 
.PP
Reimplemented from \fBQToolBar\fP.
.PP
Definition at line 665 of file ktoolbar.cpp.
.PP
References QMap::clear(), and QToolBar::clear().
.SS "void KToolBar::removeItem (int id)"
.PP
Remove item \fCid\fP. 
.PP
Item is deleted. Toolbar is redrawn after it. 
.PP
Definition at line 673 of file ktoolbar.cpp.
.PP
References QMap::end(), endl(), QMap::find(), kdDebug(), QMap::remove(), and QPtrList::removeRef().
.SS "void KToolBar::removeItemDelayed (int id)"
.PP
Remove item \fCid\fP. 
.PP
Item is deleted when toolbar is redrawn. 
.PP
Definition at line 689 of file ktoolbar.cpp.
.PP
References QMap::end(), endl(), QMap::find(), kdDebug(), QMap::remove(), QPtrList::removeRef(), and QTimer::start().
.PP
Referenced by KAction::unplug().
.SS "void KToolBar::hideItem (int id)"
.PP
Hide item \fCid\fP. 
.PP
Definition at line 708 of file ktoolbar.cpp.
.PP
References getWidget(), and QWidget::hide().
.SS "void KToolBar::showItem (int id)"
.PP
Show item \fCid\fP. 
.PP
Definition at line 716 of file ktoolbar.cpp.
.PP
References getWidget(), and QWidget::show().
.SS "int KToolBar::itemIndex (int id)"
.PP
Returns the index of the item \fCid\fP. 
.PP
\fBReturns:\fP
.RS 4
the index of the item \fCid\fP. 
.RE
.PP
\fBSince:\fP
.RS 4
3.2 
.RE
.PP

.PP
Definition at line 724 of file ktoolbar.cpp.
.PP
References QPtrList::findRef(), and getWidget().
.SS "int KToolBar::idAt (int index)"
.PP
Returns the id of the item at the given index. 
.PP
\fBSince:\fP
.RS 4
3.2 
.RE
.PP

.PP
Definition at line 730 of file ktoolbar.cpp.
.PP
References QPtrList::at().
.SS "void KToolBar::setFullSize (bool flag = \fCtrue\fP)"
.PP
Set toolbar to full parent size (default). 
.PP
In full size mode the bar extends over the parent's full width or height. If the mode is disabled the toolbar tries to take as much space as it needs without wrapping, but it does not exceed the parent box. You can force a certain width or height with \fBsetMaxWidth()\fP or \fBsetMaxHeight()\fP.
.PP
If you want to use right-aligned items or auto-sized items you must use full size mode. 
.PP
Definition at line 736 of file ktoolbar.cpp.
.PP
Referenced by loadState().
.SS "bool KToolBar::fullSize () const"
.PP
Returns the full-size mode enabled flag. 
.PP
\fBReturns:\fP
.RS 4
\fCtrue\fP if the full-size mode is enabled. 
.RE
.PP

.SS "void KToolBar::enableMoving (bool flag = \fCtrue\fP)"
.PP
Enable or disable moving of toolbar. 
.PP
\fBDeprecated\fP
.RS 4
use setMovingEnabled(bool) instead. 
.RE
.PP

.PP
Definition at line 749 of file ktoolbar.cpp.
.SS "void KToolBar::setBarPos (\fBBarPosition\fP bpos)"
.PP
Set position of toolbar. 
.PP
\fBSee also:\fP
.RS 4
\fBBarPosition()\fP 
.RE
.PP

.PP
Definition at line 755 of file ktoolbar.cpp.
.PP
References QToolBar::mainWindow().
.SS "\fBBarPosition\fP KToolBar::barPos () const"
.PP
Returns the toolbar position. 
.PP
\fBReturns:\fP
.RS 4
position of toolbar. 
.RE
.PP

.SS "bool KToolBar::enable (\fBBarStatus\fP stat)"
.PP
Show, hide, or toggle toolbar. 
.PP
This method is provided for compatibility only, please use show() and/or hide() instead. 
.PP
\fBSee also:\fP
.RS 4
\fBBarStatus\fP 
.RE
.PP
\fBDeprecated\fP
.RS 4
.RE
.PP

.PP
Definition at line 779 of file ktoolbar.cpp.
.SS "void KToolBar::setMaxHeight (int h)"
.PP
Use setMaximumHeight() instead. 
.PP
\fBDeprecated\fP
.RS 4
.RE
.PP

.PP
Definition at line 792 of file ktoolbar.cpp.
.SS "int KToolBar::maxHeight ()"
.PP
Returns the value set with \fBsetMaxHeight()\fP. 
.PP
\fBDeprecated\fP
.RS 4
Use maximumHeight() instead.
.RE
.PP
\fBReturns:\fP
.RS 4
the value set with \fBsetMaxHeight()\fP. 
.RE
.PP

.PP
Definition at line 797 of file ktoolbar.cpp.
.SS "void KToolBar::setMaxWidth (int dw)"
.PP
Use setMaximumWidth() instead. 
.PP
Set maximal width of horizontal (top or bottom) toolbar. 
.PP
\fBDeprecated\fP
.RS 4
.RE
.PP

.PP
Definition at line 803 of file ktoolbar.cpp.
.SS "int KToolBar::maxWidth ()"
.PP
Returns the value set with \fBsetMaxWidth()\fP. 
.PP
Use maximumWidth() instead. 
.PP
\fBReturns:\fP
.RS 4
the value set with \fBsetMaxWidth()\fP. 
.RE
.PP
\fBDeprecated\fP
.RS 4
.RE
.PP

.PP
Definition at line 809 of file ktoolbar.cpp.
.SS "void KToolBar::setTitle (const \fBQString\fP & _title)"
.PP
Set title for toolbar when it floats. 
.PP
Titles are however not (yet) visible. You can't change toolbar's title while it's floating. 
.PP
Definition at line 815 of file ktoolbar.cpp.
.PP
References QToolBar::setLabel().
.SS "void KToolBar::enableFloating (bool flag)"
.PP
Use setMovingEnabled(bool) instead. 
.PP
\fBDeprecated\fP
.RS 4
.RE
.PP

.PP
Definition at line 821 of file ktoolbar.cpp.
.SS "void KToolBar::setIconText (IconText it)"
.PP
Set the kind of painting for buttons. 
.PP
Choose from: 
.PD 0

.IP "\(bu" 2
IconOnly (only icons), 
.IP "\(bu" 2
IconTextRight (icon and text, text is left from icons), 
.IP "\(bu" 2
TextOnly (only text), 
.IP "\(bu" 2
IconTextBottom (icons and text, text is under icons). 
.PP
\fBSee also:\fP
.RS 4
IconText 
.RE
.PP

.PP

.PP
Definition at line 826 of file ktoolbar.cpp.
.PP
Referenced by loadState().
.SS "void KToolBar::setIconText (IconText it, bool update)"
.PP
Similar to \fBsetIconText(IconText it)\fP but allows you to disable or enable updating. 
.PP
If \fCupdate\fP is false, then the buttons will not be updated. This is useful only if you know that you will be forcing an update later. 
.PP
Definition at line 832 of file ktoolbar.cpp.
.PP
References QToolBar::mainWindow().
.SS "IconText KToolBar::iconText () const"
.PP
Returns the current text style for buttons. 
.PP
\fBReturns:\fP
.RS 4
the current text style for buttons. 
.RE
.PP

.SS "void KToolBar::setIconSize (int size)"
.PP
Set the icon size to load. 
.PP
Usually you should not call this, the icon size is taken care of by \fBKIconLoader\fP and globally configured. By default, the toolbar will load icons of size 32 for main toolbars and 22 for other toolbars 
.PP
\fBSee also:\fP
.RS 4
\fBKIconLoader\fP.
.RE
.PP
\fBParameters:\fP
.RS 4
\fIsize\fP The size to use 
.RE
.PP

.PP
Definition at line 868 of file ktoolbar.cpp.
.PP
Referenced by loadState().
.SS "void KToolBar::setIconSize (int size, bool update)"
.PP
Same as setIconText(int size) but allows you to disable the toolbar update. 
.PP
\fBParameters:\fP
.RS 4
\fIsize\fP The size to use 
.br
\fIupdate\fP If true, then the toolbar will be updated after this 
.RE
.PP

.PP
Definition at line 873 of file ktoolbar.cpp.
.PP
References QToolBar::mainWindow().
.SS "int KToolBar::iconSize () const"
.PP
Returns the current icon size for buttons. 
.PP
\fBReturns:\fP
.RS 4
the current icon size for buttons. 
.RE
.PP

.PP
Referenced by saveSettings().
.SS "int KToolBar::iconSizeDefault () const"
.PP
Returns the default size for this type of toolbar. 
.PP
\fBReturns:\fP
.RS 4
the default size for this type of toolbar. 
.RE
.PP

.PP
Definition at line 907 of file ktoolbar.cpp.
.PP
References KIconLoader::currentSize(), and KGlobal::iconLoader().
.PP
Referenced by saveSettings().
.SS "void KToolBar::setEnableContextMenu (bool enable = \fCtrue\fP)"
.PP
This allows you to enable or disable the context menu. 
.PP
\fBParameters:\fP
.RS 4
\fIenable\fP If false, then the context menu will be disabled 
.RE
.PP

.PP
Definition at line 915 of file ktoolbar.cpp.
.SS "bool KToolBar::contextMenuEnabled () const"
.PP
Returns the context menu enabled flag. 
.PP
\fBReturns:\fP
.RS 4
true if the context menu is disabled 
.RE
.PP

.PP
Definition at line 921 of file ktoolbar.cpp.
.SS "void KToolBar::setItemNoStyle (int id, bool no_style = \fCtrue\fP)"
.PP
This will inform a toolbar button to ignore certain style changes. 
.PP
Specifically, it will ignore IconText (always IconOnly) and will not allow image effects to apply.
.PP
\fBParameters:\fP
.RS 4
\fIid\fP The button to exclude from styles 
.br
\fIno_style\fP If true, then it is excluded (default: true). 
.RE
.PP

.PP
Definition at line 927 of file ktoolbar.cpp.
.PP
References getButton(), and KToolBarButton::setNoStyle().
.SS "int KToolBar::count () const"
.PP
Returns the total number of items in the toolbar. 
.PP
\fBReturns:\fP
.RS 4
the total number of items in the toolbar 
.RE
.PP

.PP
Definition at line 950 of file ktoolbar.cpp.
.PP
References QMap::count().
.SS "void KToolBar::saveState ()"
.PP
Instruct the toolbar to save it's current state to either the app config file or to the XML-GUI resource file (whichever has precedence). 
.PP
Definition at line 956 of file ktoolbar.cpp.
.PP
References QDomElement::attribute(), KGlobal::config(), QDomDocument::documentElement(), QDomNode::isNull(), QDomNode::nextSibling(), saveSettings(), QDomDocument::setContent(), KConfigBase::sync(), QDomElement::tagName(), and QDomNode::toElement().
.PP
Referenced by KXMLGUIBuilder::removeContainer().
.SS "void KToolBar::saveSettings (\fBKConfig\fP * config, const \fBQString\fP & configGroup)"
.PP
Save the toolbar settings to group \fCconfigGroup\fP in \fCconfig\fP. 
.PP
Definition at line 1037 of file ktoolbar.cpp.
.PP
References QPtrList::append(), QPtrListIterator::count(), QPtrList::first(), iconSize(), iconSizeDefault(), QString::isEmpty(), QToolBar::mainWindow(), QPtrList::next(), and QMainWindow::toolBars().
.PP
Referenced by KMainWindow::saveMainWindowSettings(), and saveState().
.SS "void KToolBar::applySettings (\fBKConfig\fP * config, const \fBQString\fP & configGroup, bool force)"
.PP
Read the toolbar settings from group \fCconfigGroup\fP in \fCconfig\fP and apply them. 
.PP
Even default settings are re-applied if \fCforce\fP is set. 
.PP
Definition at line 1635 of file ktoolbar.cpp.
.PP
References QString::isEmpty(), QToolBar::mainWindow(), and KGlobal::staticQString().
.PP
Referenced by KMainWindow::applyMainWindowSettings().
.SS "void KToolBar::setText (const \fBQString\fP & txt)"
.PP
Assign a (translated) text to this toolbar. 
.PP
This is used for the tooltip on the handle, and when listing the toolbars. 
.PP
Definition at line 1128 of file ktoolbar.cpp.
.PP
References QToolBar::setLabel().
.PP
Referenced by loadState().
.SS "\fBQString\fP KToolBar::text () const"
.PP
Returns the toolbar's text. 
.PP
\fBReturns:\fP
.RS 4
the toolbar's text. 
.RE
.PP

.SS "void KToolBar::loadState (const \fBQDomElement\fP & e)"
.PP
Load state from an XML element, called by \fBKXMLGUIBuilder\fP. 
.PP
Definition at line 1769 of file ktoolbar.cpp.
.PP
References QMainWindow::addDockWindow(), highlightSetting(), iconTextSetting(), QString::isEmpty(), QCString::isEmpty(), QString::latin1(), QString::lower(), QCString::lower(), QToolBar::mainWindow(), QMainWindow::moveDockWindow(), QMainWindow::opaqueMoving(), setFullSize(), setIconSize(), setIconText(), QMainWindow::setOpaqueMoving(), setText(), QString::toInt(), QCString::toInt(), transparentSetting(), and QString::utf8().
.PP
Referenced by KXMLGUIBuilder::createContainer().
.SS "void KToolBar::clicked (int id)\fC [signal]\fP"
.PP
Emitted when button \fCid\fP is clicked. 
.PP
Referenced by insertAnimatedWidget().
.SS "void KToolBar::doubleClicked (int id)\fC [signal]\fP"
.PP
Emitted when button \fCid\fP is double-clicked. 
.PP
Note: you will always recive two \fBclicked()\fP , \fBpressed()\fP and \fBreleased()\fP signals. There is no way to avoid it - at least no easy way. If you need to resolve this all you can do is set up timers which wait for \fBQApplication::doubleClickInterval()\fP to expire. If in that time you don't get this signal, you may belive that button was only clicked and not double-clicked. And please note that butons with popup menus do not emit this signal, but those with delayed popup do. 
.SS "void KToolBar::pressed (int)\fC [signal]\fP"
.PP
Emitted when button \fCid\fP is pressed. 
.PP
.SS "void KToolBar::released (int)\fC [signal]\fP"
.PP
Emits when button \fCid\fP is released. 
.PP
.SS "void KToolBar::toggled (int)\fC [signal]\fP"
.PP
Emitted when a toggle button changes state. 
.PP
Emitted also if you change state with \fBsetButton()\fP or \fBtoggleButton()\fP If you make a button normal again, with setToggle(false), this signal won't be emitted. 
.SS "void KToolBar::highlighted (int id, bool isHighlighted)\fC [signal]\fP"
.PP
This signal is emitted when item \fCid\fP gets highlighted/unhighlighted (i.e when mouse enters/exits). 
.PP
Note that this signal is emitted from all buttons (normal, disabled and toggle) even when there is no visible change in buttons (i.e., buttons do not raise when mouse enters). The parameter \fCisHighlighted\fP is \fCtrue\fP when mouse enters and \fCfalse\fP when mouse exits. 
.SS "void KToolBar::highlighted (int id)\fC [signal]\fP"
.PP
This signal is emitted when item \fCid\fP gets highlighted/unhighlighted (i.e when mouse enters/exits). 
.PP
Note that this signal is emitted from all buttons (normal, disabled and toggle) even when there is no visible change in buttons (i.e., buttons do not raise when mouse enters). 
.SS "void KToolBar::moved (\fBBarPosition\fP)\fC [signal]\fP"
.PP
Emitted when toolbar changes position, or when an item is removed from toolbar. 
.PP
If you subclass \fBKMainWindow\fP and reimplement KMainWindow::resizeEvent() be sure to connect to this signal. Note: You can connect this signal to a slot that doesn't take parameter. 
.SS "void KToolBar::modechange ()\fC [signal]\fP"
.PP
This signal is emitted when toolbar detects changing of following parameters: highlighting, button-size, button-mode. 
.PP
This signal is internal, aimed to buttons. 
.SS "void KToolBar::toolbarDestroyed ()\fC [signal]\fP"
.PP
This signal is emitted when the toolbar is getting deleted, and before ~KToolbar finishes (so it's still time to remove widgets from the toolbar). 
.PP
Used by \fBKWidgetAction\fP. 
.PP
\fBSince:\fP
.RS 4
3.2 
.RE
.PP

.PP
Referenced by ~KToolBar().
.SS "bool KToolBar::highlightSetting ()\fC [static]\fP"
.PP
Returns the global setting for 'Highlight buttons under mouse'. 
.PP
\fBReturns:\fP
.RS 4
global setting for 'Highlight buttons under mouse' 
.RE
.PP

.PP
Definition at line 1477 of file ktoolbar.cpp.
.PP
References KGlobal::config(), and KConfigBase::readBoolEntry().
.PP
Referenced by loadState().
.SS "bool KToolBar::transparentSetting ()\fC [static]\fP"
.PP
Returns the global setting for 'Toolbars transparent when moving'. 
.PP
\fBReturns:\fP
.RS 4
global setting for 'Toolbars transparent when moving' 
.RE
.PP

.PP
Definition at line 1485 of file ktoolbar.cpp.
.PP
References KGlobal::config(), and KConfigBase::readBoolEntry().
.PP
Referenced by loadState().
.SS "KToolBar::IconText KToolBar::iconTextSetting ()\fC [static]\fP"
.PP
Returns the global setting for 'Icon Text'. 
.PP
\fBReturns:\fP
.RS 4
global setting for 'Icon Text' 
.RE
.PP

.PP
Definition at line 1493 of file ktoolbar.cpp.
.PP
References KGlobal::config(), and KConfigBase::readEntry().
.PP
Referenced by loadState().

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