\section{KToggle\-Tool\-Bar\-Action Class Reference}
\label{classKToggleToolBarAction}\index{KToggleToolBarAction@{KToggleToolBarAction}}
An action that takes care of everything associated with showing or hiding a toolbar by a menu action.  


{\tt \#include $<$kaction.h$>$}

Inheritance diagram for KToggle\-Tool\-Bar\-Action:\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=81pt]{classKToggleToolBarAction__inherit__graph}
\end{center}
\end{figure}
Collaboration diagram for KToggle\-Tool\-Bar\-Action:\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=189pt]{classKToggleToolBarAction__coll__graph}
\end{center}
\end{figure}
\subsection*{Public Slots}
\begin{CompactItemize}
\item 
virtual void {\bf set\-Checked} (bool)
\begin{CompactList}\small\item\em Sets the state of the action. \item\end{CompactList}\end{CompactItemize}
\subsection*{Public Member Functions}
\begin{CompactItemize}
\item 
{\bf KToggle\-Tool\-Bar\-Action} (const  char $\ast$tool\-Bar\-Name, const  {\bf QString} \&text, {\bf KAction\-Collection} $\ast${\bf parent}, const  char $\ast${\bf name})
\begin{CompactList}\small\item\em Create a KToggle\-Toolbar\-Action that manages the toolbar named tool\-Bar\-Name. \item\end{CompactList}\item 
{\bf KToggle\-Tool\-Bar\-Action} ({\bf KTool\-Bar} $\ast$tool\-Bar, const  {\bf QString} \&text, {\bf KAction\-Collection} $\ast${\bf parent}, const  char $\ast${\bf name})\label{classKToggleToolBarAction_a1}

\item 
virtual int {\bf plug} ({\bf QWidget} $\ast$, int index=-1)
\begin{CompactList}\small\item\em \char`\"{}Plug\char`\"{} or insert this action into a given widget. \item\end{CompactList}\item 
{\bf KTool\-Bar} $\ast$ {\bf tool\-Bar} ()\label{classKToggleToolBarAction_a4}

\end{CompactItemize}
\subsection*{Protected Member Functions}
\begin{CompactItemize}
\item 
virtual void {\bf virtual\_\-hook} (int id, void $\ast$data)\label{classKToggleToolBarAction_b0}

\end{CompactItemize}


\subsection{Detailed Description}
An action that takes care of everything associated with showing or hiding a toolbar by a menu action. 

It will show or hide the toolbar with the given name when activated, and check or uncheck itself if the toolbar is manually shown or hidden.

If you need to perfom some additional action when the toolbar is shown or hidden, connect to the toggled(bool) signal. It will be emitted after the toolbar's visibility has changed, whenever it changes. \begin{Desc}
\item[Since:]3.1 \end{Desc}




Definition at line 1659 of file kaction.h.

\subsection{Constructor \& Destructor Documentation}
\index{KToggleToolBarAction@{KToggle\-Tool\-Bar\-Action}!KToggleToolBarAction@{KToggleToolBarAction}}
\index{KToggleToolBarAction@{KToggleToolBarAction}!KToggleToolBarAction@{KToggle\-Tool\-Bar\-Action}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}KToggle\-Tool\-Bar\-Action::KToggle\-Tool\-Bar\-Action (const char $\ast$ {\em tool\-Bar\-Name}, const {\bf QString} \& {\em text}, {\bf KAction\-Collection} $\ast$ {\em parent}, const char $\ast$ {\em name})}\label{classKToggleToolBarAction_a0}


Create a KToggle\-Toolbar\-Action that manages the toolbar named tool\-Bar\-Name. 

This can be either the name of a toolbar in an xml ui file, or a toolbar programmatically created with that name. 

Definition at line 2848 of file kaction.cpp.

References KStd\-Accel::name().

\subsection{Member Function Documentation}
\index{KToggleToolBarAction@{KToggle\-Tool\-Bar\-Action}!plug@{plug}}
\index{plug@{plug}!KToggleToolBarAction@{KToggle\-Tool\-Bar\-Action}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}int KToggle\-Tool\-Bar\-Action::plug ({\bf QWidget} $\ast$, int {\em index} = -1)\hspace{0.3cm}{\tt  [virtual]}}\label{classKToggleToolBarAction_a3}


\char`\"{}Plug\char`\"{} 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 {\bf KToggle\-Action}{\rm (p.\,\pageref{classKToggleAction})} object.

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em widget}]The GUI element to display this action. \item[{\em index}]The index of the item. \end{description}
\end{Desc}


Reimplemented from {\bf KToggle\-Action} {\rm (p.\,\pageref{classKToggleAction_a8})}.

Definition at line 2867 of file kaction.cpp.

References QObject::connect(), QWidget::is\-Dialog(), QObject::name(), QWidget::parent\-Widget(), KToggle\-Action::plug(), set\-Checked(), KAction::set\-Enabled(), and KMain\-Window::tool\-Bar().\index{KToggleToolBarAction@{KToggle\-Tool\-Bar\-Action}!setChecked@{setChecked}}
\index{setChecked@{setChecked}!KToggleToolBarAction@{KToggle\-Tool\-Bar\-Action}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void KToggle\-Tool\-Bar\-Action::set\-Checked (bool)\hspace{0.3cm}{\tt  [virtual, slot]}}\label{classKToggleToolBarAction_i0}


Sets the state of the action. 



Reimplemented from {\bf KToggle\-Action} {\rm (p.\,\pageref{classKToggleAction_i0})}.

Definition at line 2897 of file kaction.cpp.

References KToggle\-Action::set\-Checked().

Referenced by plug().

The documentation for this class was generated from the following files:\begin{CompactItemize}
\item 
kaction.h\item 
kaction.cpp\end{CompactItemize}
