\section{KPopup\-Frame Class Reference}
\label{classKPopupFrame}\index{KPopupFrame@{KPopupFrame}}
Frame with popup menu behavior.  


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

Inheritance diagram for KPopup\-Frame:\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=58pt]{classKPopupFrame__inherit__graph}
\end{center}
\end{figure}
Collaboration diagram for KPopup\-Frame:\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=80pt]{classKPopupFrame__coll__graph}
\end{center}
\end{figure}
\subsection*{Public Slots}
\begin{CompactItemize}
\item 
void {\bf close} (int r)
\end{CompactItemize}
\subsection*{Public Member Functions}
\begin{CompactItemize}
\item 
{\bf KPopup\-Frame} ({\bf QWidget} $\ast$parent=0, const char $\ast$name=0)
\item 
void {\bf set\-Main\-Widget} ({\bf QWidget} $\ast$m)
\item 
virtual void {\bf resize\-Event} ({\bf QResize\-Event} $\ast$)
\item 
void {\bf popup} (const {\bf QPoint} \&pos)
\item 
int {\bf exec} ({\bf QPoint} p)
\item 
int {\bf exec} (int x, int y)
\end{CompactItemize}
\subsection*{Protected Member Functions}
\begin{CompactItemize}
\item 
virtual void {\bf key\-Press\-Event} ({\bf QKey\-Event} $\ast$e)
\item 
virtual void {\bf virtual\_\-hook} (int id, void $\ast$data)\label{classKPopupFrame_b1}

\end{CompactItemize}
\subsection*{Protected Attributes}
\begin{CompactItemize}
\item 
int {\bf result}
\item 
{\bf QWidget} $\ast$ {\bf main}
\end{CompactItemize}


\subsection{Detailed Description}
Frame with popup menu behavior. 

\begin{Desc}
\item[Author:]Tim Gilman, Mirko Boehm \end{Desc}
\begin{Desc}
\item[Version:]\begin{Desc}
\item[Id]{\bf kdatetbl.h}{\rm (p.\,\pageref{kdatetbl_8h})} 382217 2005-01-25 09:31:19Z dfaure \end{Desc}
\end{Desc}




Definition at line 166 of file kdatetbl.h.

\subsection{Constructor \& Destructor Documentation}
\index{KPopupFrame@{KPopup\-Frame}!KPopupFrame@{KPopupFrame}}
\index{KPopupFrame@{KPopupFrame}!KPopupFrame@{KPopup\-Frame}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}KPopup\-Frame::KPopup\-Frame ({\bf QWidget} $\ast$ {\em parent} = {\tt 0}, const char $\ast$ {\em name} = {\tt 0})}\label{classKPopupFrame_a0}


The contructor. 

Creates a dialog without buttons. 

Definition at line 888 of file kdatetbl.cpp.

References QFrame::set\-Frame\-Style(), and QFrame::set\-Mid\-Line\-Width().

\subsection{Member Function Documentation}
\index{KPopupFrame@{KPopup\-Frame}!keyPressEvent@{keyPressEvent}}
\index{keyPressEvent@{keyPressEvent}!KPopupFrame@{KPopup\-Frame}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void KPopup\-Frame::key\-Press\-Event ({\bf QKey\-Event} $\ast$ {\em e})\hspace{0.3cm}{\tt  [protected, virtual]}}\label{classKPopupFrame_b0}


Catch key press events. 



Definition at line 898 of file kdatetbl.cpp.

References result.\index{KPopupFrame@{KPopup\-Frame}!close@{close}}
\index{close@{close}!KPopupFrame@{KPopup\-Frame}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void KPopup\-Frame::close (int {\em r})\hspace{0.3cm}{\tt  [slot]}}\label{classKPopupFrame_i0}


Close the popup window. 

This is called from the main widget, usually. {\tt r} is the result returned from {\bf exec()}{\rm (p.\,\pageref{classKPopupFrame_a4})}. 

Definition at line 908 of file kdatetbl.cpp.

References result.\index{KPopupFrame@{KPopup\-Frame}!setMainWidget@{setMainWidget}}
\index{setMainWidget@{setMainWidget}!KPopupFrame@{KPopup\-Frame}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void KPopup\-Frame::set\-Main\-Widget ({\bf QWidget} $\ast$ {\em m})}\label{classKPopupFrame_a1}


Set the main widget. 

You cannot set the main widget from the constructor, since it must be a child of the frame itselfes. Be careful: the size is set to the main widgets size. It is up to you to set the main widgets correct size before setting it as the main widget. 

Definition at line 915 of file kdatetbl.cpp.

References QFrame::frame\-Width(), QWidget::height(), main, and QWidget::width().

Referenced by KDate\-Picker::select\-Year\-Clicked().\index{KPopupFrame@{KPopup\-Frame}!resizeEvent@{resizeEvent}}
\index{resizeEvent@{resizeEvent}!KPopupFrame@{KPopup\-Frame}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void KPopup\-Frame::resize\-Event ({\bf QResize\-Event} $\ast$)\hspace{0.3cm}{\tt  [virtual]}}\label{classKPopupFrame_a2}


The resize event. 

Simply resizes the main widget to the whole widgets client size. 

Reimplemented from {\bf QFrame}.

Definition at line 925 of file kdatetbl.cpp.

References QFrame::frame\-Width(), main, and QWidget::set\-Geometry().\index{KPopupFrame@{KPopup\-Frame}!popup@{popup}}
\index{popup@{popup}!KPopupFrame@{KPopup\-Frame}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void KPopup\-Frame::popup (const {\bf QPoint} \& {\em pos})}\label{classKPopupFrame_a3}


Open the popup window at position pos. 



Definition at line 935 of file kdatetbl.cpp.

References KGlobal\-Settings::desktop\-Geometry(), QRect::height(), QRect::width(), QRect::x(), and QRect::y().

Referenced by exec().\index{KPopupFrame@{KPopup\-Frame}!exec@{exec}}
\index{exec@{exec}!KPopupFrame@{KPopup\-Frame}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}int KPopup\-Frame::exec ({\bf QPoint} {\em p})}\label{classKPopupFrame_a4}


Execute the popup window. 



Definition at line 959 of file kdatetbl.cpp.

References popup(), and result.

Referenced by exec(), and KDate\-Picker::select\-Year\-Clicked().\index{KPopupFrame@{KPopup\-Frame}!exec@{exec}}
\index{exec@{exec}!KPopupFrame@{KPopup\-Frame}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}int KPopup\-Frame::exec (int {\em x}, int {\em y})}\label{classKPopupFrame_a5}


Execute the popup window. 



Definition at line 969 of file kdatetbl.cpp.

References exec().

\subsection{Member Data Documentation}
\index{KPopupFrame@{KPopup\-Frame}!result@{result}}
\index{result@{result}!KPopupFrame@{KPopup\-Frame}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}int {\bf KPopup\-Frame::result}\hspace{0.3cm}{\tt  [protected]}}\label{classKPopupFrame_p0}


The result. 

It is returned from {\bf exec()}{\rm (p.\,\pageref{classKPopupFrame_a4})} when the popup window closes. 

Definition at line 173 of file kdatetbl.h.

Referenced by close(), exec(), and key\-Press\-Event().\index{KPopupFrame@{KPopup\-Frame}!main@{main}}
\index{main@{main}!KPopupFrame@{KPopup\-Frame}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QWidget}$\ast$ {\bf KPopup\-Frame::main}\hspace{0.3cm}{\tt  [protected]}}\label{classKPopupFrame_p1}


The only subwidget that uses the whole dialog window. 



Definition at line 181 of file kdatetbl.h.

Referenced by resize\-Event(), and set\-Main\-Widget().

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