\section{KMime\-Type\-Chooser Class Reference}
\label{classKMimeTypeChooser}\index{KMimeTypeChooser@{KMimeTypeChooser}}
This widget provides a checkable list of all available mimetypes, and a list of selected ones, as well as a corresponding list of file extensions, an optional text and an optional edit button (not working yet).  


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

Inheritance diagram for KMime\-Type\-Chooser:\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=71pt]{classKMimeTypeChooser__inherit__graph}
\end{center}
\end{figure}
Collaboration diagram for KMime\-Type\-Chooser:\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=71pt]{classKMimeTypeChooser__coll__graph}
\end{center}
\end{figure}
\subsection*{Public Types}
\begin{CompactItemize}
\item 
enum {\bf Visuals} \{ {\bf Comments} = 1, 
{\bf Patterns} = 2, 
{\bf Edit\-Button} = 4
 \}
\end{CompactItemize}
\subsection*{Public Slots}
\begin{CompactItemize}
\item 
void {\bf edit\-Mime\-Type} ()
\end{CompactItemize}
\subsection*{Public Member Functions}
\begin{CompactItemize}
\item 
{\bf KMime\-Type\-Chooser} (const {\bf QString} \&text=QString::null, const {\bf QString\-List} \&selected\-Mime\-Types=0, const {\bf QString} \&default\-Group=QString::null, const {\bf QString\-List} \&groups\-To\-Show={\bf QString\-List}(), int visuals=Comments$|$Patterns$|$Edit\-Button, {\bf QWidget} $\ast$parent=0, const char $\ast$name=0)
\item 
{\bf QString\-List} {\bf mime\-Types} () const 
\item 
{\bf QString\-List} {\bf patterns} () const 
\end{CompactItemize}


\subsection{Detailed Description}
This widget provides a checkable list of all available mimetypes, and a list of selected ones, as well as a corresponding list of file extensions, an optional text and an optional edit button (not working yet). 

Mime types is presented in a list view, with name, comment and patterns columns.

\begin{Desc}
\item[Author:]Anders Lund (anders at alweb dk), jan 23, 2002 \end{Desc}




Definition at line 34 of file kmimetypechooser.h.

\subsection{Member Enumeration Documentation}
\index{KMimeTypeChooser@{KMime\-Type\-Chooser}!Visuals@{Visuals}}
\index{Visuals@{Visuals}!KMimeTypeChooser@{KMime\-Type\-Chooser}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}enum {\bf KMime\-Type\-Chooser::Visuals}}\label{classKMimeTypeChooser_w3}


Buttons and data for display. 

\begin{Desc}
\item[Enumeration values: ]\par
\begin{description}
\index{Comments@{Comments}!KMimeTypeChooser@{KMimeTypeChooser}}\index{KMimeTypeChooser@{KMimeTypeChooser}!Comments@{Comments}}\item[{\em 
Comments\label{classKMimeTypeChooser_w3w0}
}]Show the Mimetypes Comment field in a column (\char`\"{}HTML Document\char`\"{}). \index{Patterns@{Patterns}!KMimeTypeChooser@{KMimeTypeChooser}}\index{KMimeTypeChooser@{KMimeTypeChooser}!Patterns@{Patterns}}\item[{\em 
Patterns\label{classKMimeTypeChooser_w3w1}
}]Show the Mimetypes Patterns field in a column (\char`\"{}$\ast$.html;$\ast$.htm\char`\"{}). \index{EditButton@{EditButton}!KMimeTypeChooser@{KMimeTypeChooser}}\index{KMimeTypeChooser@{KMimeTypeChooser}!EditButton@{EditButton}}\item[{\em 
Edit\-Button\label{classKMimeTypeChooser_w3w2}
}]Show the \char`\"{}Edit\char`\"{} button, allowing to edit the selected type. \end{description}
\end{Desc}



Definition at line 42 of file kmimetypechooser.h.

\subsection{Constructor \& Destructor Documentation}
\index{KMimeTypeChooser@{KMime\-Type\-Chooser}!KMimeTypeChooser@{KMimeTypeChooser}}
\index{KMimeTypeChooser@{KMimeTypeChooser}!KMimeTypeChooser@{KMime\-Type\-Chooser}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}KMime\-Type\-Chooser::KMime\-Type\-Chooser (const {\bf QString} \& {\em text} = {\tt QString::null}, const {\bf QString\-List} \& {\em selected\-Mime\-Types} = {\tt 0}, const {\bf QString} \& {\em default\-Group} = {\tt QString::null}, const {\bf QString\-List} \& {\em groups\-To\-Show} = {\tt {\bf QString\-List}()}, int {\em visuals} = {\tt Comments$|$Patterns$|$EditButton}, {\bf QWidget} $\ast$ {\em parent} = {\tt 0}, const char $\ast$ {\em name} = {\tt 0})}\label{classKMimeTypeChooser_a0}


Create a new KMime\-Type\-Chooser. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em text}]A Text to display above the list \item[{\em selected\-Mime\-Types}]A list of mimetype names, theese will be checked in the list if they exist. \item[{\em visuals}]A OR'd Visuals enum to decide which data and buttons to display. \item[{\em default\-Group}]The group to open when no groups are selected (like \char`\"{}text\char`\"{}). If not provided, no group is opened. If {\tt groups\-To\-Show} is provided and default\-Group is not a member of that, it is ignored. \item[{\em groups\-To\-Show}]a list of mimetype groups to show. If empty, all groups are shown. \item[{\em parent}]The parent widget to use \item[{\em name}]The internal name of this object \end{description}
\end{Desc}


Definition at line 50 of file kmimetypechooser.cpp.

References QWhats\-This::add(), Comments, Edit\-Button, edit\-Mime\-Type(), and Patterns.

\subsection{Member Function Documentation}
\index{KMimeTypeChooser@{KMime\-Type\-Chooser}!mimeTypes@{mimeTypes}}
\index{mimeTypes@{mimeTypes}!KMimeTypeChooser@{KMime\-Type\-Chooser}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QString\-List} KMime\-Type\-Chooser::mime\-Types () const}\label{classKMimeTypeChooser_a2}


\begin{Desc}
\item[Returns:]a list of all selected selected mimetypes represented by their name. \end{Desc}


Definition at line 217 of file kmimetypechooser.cpp.\index{KMimeTypeChooser@{KMime\-Type\-Chooser}!patterns@{patterns}}
\index{patterns@{patterns}!KMimeTypeChooser@{KMime\-Type\-Chooser}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QString\-List} KMime\-Type\-Chooser::patterns () const}\label{classKMimeTypeChooser_a3}


\begin{Desc}
\item[Returns:]a list of the fileame patterns associated with all selected mimetypes. \end{Desc}


Definition at line 229 of file kmimetypechooser.cpp.

References KMime\-Type::default\-Mime\-Type(), and KMime\-Type::mime\-Type().\index{KMimeTypeChooser@{KMime\-Type\-Chooser}!editMimeType@{editMimeType}}
\index{editMimeType@{editMimeType}!KMimeTypeChooser@{KMime\-Type\-Chooser}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void KMime\-Type\-Chooser::edit\-Mime\-Type ()\hspace{0.3cm}{\tt  [slot]}}\label{classKMimeTypeChooser_i0}


edit the current mimetype Uses {\bf KRun}{\rm (p.\,\pageref{classKRun})} to start the {\bf KDE} mimetype editor for editing the currently selected mimetype. 



Definition at line 190 of file kmimetypechooser.cpp.

References QString::from\-Latin1(), KRun::run\-Command(), and QList\-View\-Item::text().

Referenced by KMime\-Type\-Chooser().

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