\section{KMdi\-Task\-Bar\-Button Class Reference}
\label{classKMdiTaskBarButton}\index{KMdiTaskBarButton@{KMdiTaskBarButton}}
Internal class.  


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

Inheritance diagram for KMdi\-Task\-Bar\-Button:\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=70pt]{classKMdiTaskBarButton__inherit__graph}
\end{center}
\end{figure}
Collaboration diagram for KMdi\-Task\-Bar\-Button:\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=268pt]{classKMdiTaskBarButton__coll__graph}
\end{center}
\end{figure}
\subsection*{Public Slots}
\begin{CompactItemize}
\item 
void {\bf set\-New\-Text} (const {\bf QString} \&)
\end{CompactItemize}
\subsection*{Signals}
\begin{CompactItemize}
\item 
void {\bf clicked} ({\bf KMdi\-Child\-View} $\ast$)
\item 
void {\bf left\-Mouse\-Button\-Clicked} ({\bf KMdi\-Child\-View} $\ast$)
\item 
void {\bf right\-Mouse\-Button\-Clicked} ({\bf KMdi\-Child\-View} $\ast$)
\item 
void {\bf button\-Text\-Changed} (int)
\end{CompactItemize}
\subsection*{Public Member Functions}
\begin{CompactItemize}
\item 
{\bf KMdi\-Task\-Bar\-Button} ({\bf KMdi\-Task\-Bar} $\ast$p\-Task\-Bar, {\bf KMdi\-Child\-View} $\ast$win\_\-ptr)
\item 
{\bf $\sim$KMdi\-Task\-Bar\-Button} ()
\item 
{\bf QString} {\bf actual\-Text} () const 
\item 
void {\bf fit\-Text} (const {\bf QString} \&, int new\-Width)
\item 
void {\bf set\-Text} (const {\bf QString} \&)
\end{CompactItemize}
\subsection*{Public Attributes}
\begin{CompactItemize}
\item 
{\bf KMdi\-Child\-View} $\ast$ {\bf m\_\-p\-Window}
\end{CompactItemize}
\subsection*{Protected Slots}
\begin{CompactItemize}
\item 
void {\bf mouse\-Press\-Event} ({\bf QMouse\-Event} $\ast$)
\end{CompactItemize}
\subsection*{Protected Attributes}
\begin{CompactItemize}
\item 
{\bf QString} {\bf m\_\-actual\-Text}
\end{CompactItemize}


\subsection{Detailed Description}
Internal class. 

It's a special kind of {\bf QPush\-Button} catching mouse clicks. And you have the ability to abbreviate the text that it fits in the button. 



Definition at line 51 of file kmditaskbar.h.

\subsection{Constructor \& Destructor Documentation}
\index{KMdiTaskBarButton@{KMdi\-Task\-Bar\-Button}!KMdiTaskBarButton@{KMdiTaskBarButton}}
\index{KMdiTaskBarButton@{KMdiTaskBarButton}!KMdiTaskBarButton@{KMdi\-Task\-Bar\-Button}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}KMdi\-Task\-Bar\-Button::KMdi\-Task\-Bar\-Button ({\bf KMdi\-Task\-Bar} $\ast$ {\em p\-Task\-Bar}, {\bf KMdi\-Child\-View} $\ast$ {\em win\_\-ptr})}\label{classKMdiTaskBarButton_a0}


Constructor (sets to toggle button, adds a tooltip (caption) and sets to No\-Focus. 



Definition at line 58 of file kmditaskbar.cpp.

References m\_\-p\-Window, and QPush\-Button::set\-Toggle\-Button().\index{KMdiTaskBarButton@{KMdi\-Task\-Bar\-Button}!~KMdiTaskBarButton@{$\sim$KMdiTaskBarButton}}
\index{~KMdiTaskBarButton@{$\sim$KMdiTaskBarButton}!KMdiTaskBarButton@{KMdi\-Task\-Bar\-Button}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}KMdi\-Task\-Bar\-Button::$\sim${\bf KMdi\-Task\-Bar\-Button} ()}\label{classKMdiTaskBarButton_a1}


Destructor. 



Definition at line 69 of file kmditaskbar.cpp.

\subsection{Member Function Documentation}
\index{KMdiTaskBarButton@{KMdi\-Task\-Bar\-Button}!actualText@{actualText}}
\index{actualText@{actualText}!KMdiTaskBarButton@{KMdi\-Task\-Bar\-Button}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QString} KMdi\-Task\-Bar\-Button::actual\-Text () const}\label{classKMdiTaskBarButton_a2}


{\bf text()} returns the possibly abbreviated text including the dots in it. 

But {\bf actual\-Text()}{\rm (p.\,\pageref{classKMdiTaskBarButton_a2})} returns the full text.

Definition at line 132 of file kmditaskbar.cpp.

References m\_\-actual\-Text.

Referenced by KMdi\-Task\-Bar::layout\-Task\-Bar().\index{KMdiTaskBarButton@{KMdi\-Task\-Bar\-Button}!fitText@{fitText}}
\index{fitText@{fitText}!KMdiTaskBarButton@{KMdi\-Task\-Bar\-Button}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void KMdi\-Task\-Bar\-Button::fit\-Text (const {\bf QString} \&, int {\em new\-Width})}\label{classKMdiTaskBarButton_a3}


Given the parameter new\-Width this function possibly abbreviates the parameter string and sets a new button text. 



Definition at line 101 of file kmditaskbar.cpp.

References QString::left(), QString::length(), m\_\-actual\-Text, QString::right(), QButton::set\-Text(), and QFont\-Metrics::width().

Referenced by KMdi\-Task\-Bar::layout\-Task\-Bar().\index{KMdiTaskBarButton@{KMdi\-Task\-Bar\-Button}!setText@{setText}}
\index{setText@{setText}!KMdiTaskBarButton@{KMdi\-Task\-Bar\-Button}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void KMdi\-Task\-Bar\-Button::set\-Text (const {\bf QString} \&)}\label{classKMdiTaskBarButton_a4}


Sets the text and avoids any abbreviation. 

Memorizes that text in m\_\-actual\-Text, too.

Reimplemented from {\bf QPush\-Button}.

Definition at line 95 of file kmditaskbar.cpp.

References m\_\-actual\-Text, and QButton::set\-Text().

Referenced by KMdi\-Task\-Bar::add\-Win\-Button(), KMdi\-Task\-Bar::layout\-Task\-Bar(), and set\-New\-Text().\index{KMdiTaskBarButton@{KMdi\-Task\-Bar\-Button}!clicked@{clicked}}
\index{clicked@{clicked}!KMdiTaskBarButton@{KMdi\-Task\-Bar\-Button}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void KMdi\-Task\-Bar\-Button::clicked ({\bf KMdi\-Child\-View} $\ast$)\hspace{0.3cm}{\tt  [signal]}}\label{classKMdiTaskBarButton_l0}


Emitted when the button has been clicked. 

Internally connected to set\-Focus of the according MDI view.\index{KMdiTaskBarButton@{KMdi\-Task\-Bar\-Button}!leftMouseButtonClicked@{leftMouseButtonClicked}}
\index{leftMouseButtonClicked@{leftMouseButtonClicked}!KMdiTaskBarButton@{KMdi\-Task\-Bar\-Button}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void KMdi\-Task\-Bar\-Button::left\-Mouse\-Button\-Clicked ({\bf KMdi\-Child\-View} $\ast$)\hspace{0.3cm}{\tt  [signal]}}\label{classKMdiTaskBarButton_l1}


Internally connected with {\bf KMdi\-Main\-Frm::activate\-View}{\rm (p.\,\pageref{classKMdiMainFrm_i45})}. 



Referenced by mouse\-Press\-Event().\index{KMdiTaskBarButton@{KMdi\-Task\-Bar\-Button}!rightMouseButtonClicked@{rightMouseButtonClicked}}
\index{rightMouseButtonClicked@{rightMouseButtonClicked}!KMdiTaskBarButton@{KMdi\-Task\-Bar\-Button}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void KMdi\-Task\-Bar\-Button::right\-Mouse\-Button\-Clicked ({\bf KMdi\-Child\-View} $\ast$)\hspace{0.3cm}{\tt  [signal]}}\label{classKMdiTaskBarButton_l2}


Internally connected with {\bf KMdi\-Main\-Frm::taskbar\-Button\-Right\-Clicked}{\rm (p.\,\pageref{classKMdiMainFrm_j1})}. 



Referenced by mouse\-Press\-Event().\index{KMdiTaskBarButton@{KMdi\-Task\-Bar\-Button}!buttonTextChanged@{buttonTextChanged}}
\index{buttonTextChanged@{buttonTextChanged}!KMdiTaskBarButton@{KMdi\-Task\-Bar\-Button}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void KMdi\-Task\-Bar\-Button::button\-Text\-Changed (int)\hspace{0.3cm}{\tt  [signal]}}\label{classKMdiTaskBarButton_l3}


Emitted when the button text has changed. 

Internally connected with {\bf KMdi\-Task\-Bar::layout\-Task\-Bar}{\rm (p.\,\pageref{classKMdiTaskBar_j0})}

Referenced by set\-New\-Text().\index{KMdiTaskBarButton@{KMdi\-Task\-Bar\-Button}!setNewText@{setNewText}}
\index{setNewText@{setNewText}!KMdiTaskBarButton@{KMdi\-Task\-Bar\-Button}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void KMdi\-Task\-Bar\-Button::set\-New\-Text (const {\bf QString} \& {\em s})\hspace{0.3cm}{\tt  [slot]}}\label{classKMdiTaskBarButton_i0}


A slot version of set\-Text. 



Definition at line 89 of file kmditaskbar.cpp.

References button\-Text\-Changed(), and set\-Text().\index{KMdiTaskBarButton@{KMdi\-Task\-Bar\-Button}!mousePressEvent@{mousePressEvent}}
\index{mousePressEvent@{mousePressEvent}!KMdiTaskBarButton@{KMdi\-Task\-Bar\-Button}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void KMdi\-Task\-Bar\-Button::mouse\-Press\-Event ({\bf QMouse\-Event} $\ast$)\hspace{0.3cm}{\tt  [protected, slot]}}\label{classKMdiTaskBarButton_j0}


Reimplemented from its base class to catch right and left mouse button clicks. 



Definition at line 72 of file kmditaskbar.cpp.

References QPush\-Button::clicked(), left\-Mouse\-Button\-Clicked(), m\_\-p\-Window, and right\-Mouse\-Button\-Clicked().

\subsection{Member Data Documentation}
\index{KMdiTaskBarButton@{KMdi\-Task\-Bar\-Button}!m_pWindow@{m\_\-pWindow}}
\index{m_pWindow@{m\_\-pWindow}!KMdiTaskBarButton@{KMdi\-Task\-Bar\-Button}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf KMdi\-Child\-View}$\ast$ {\bf KMdi\-Task\-Bar\-Button::m\_\-p\-Window}}\label{classKMdiTaskBarButton_o0}


The according MDI view. 



Definition at line 109 of file kmditaskbar.h.

Referenced by KMdi\-Task\-Bar\-Button(), and mouse\-Press\-Event().\index{KMdiTaskBarButton@{KMdi\-Task\-Bar\-Button}!m_actualText@{m\_\-actualText}}
\index{m_actualText@{m\_\-actualText}!KMdiTaskBarButton@{KMdi\-Task\-Bar\-Button}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QString} {\bf KMdi\-Task\-Bar\-Button::m\_\-actual\-Text}\hspace{0.3cm}{\tt  [protected]}}\label{classKMdiTaskBarButton_p0}


Internally we must remember the real text because the button text can be abbreviated. 



Definition at line 114 of file kmditaskbar.h.

Referenced by actual\-Text(), fit\-Text(), and set\-Text().

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