.TH "KSpellConfig" kde3 "11 Jun 2005" "Version Version 3.4.1" "kdeui Library" \" -*- nroff -*-
.ad l
.nh
.SH NAME
KSpellConfig \- A configuration class/dialog for \fBKSpell\fP.  

.PP
.SH SYNOPSIS
.br
.PP
\fC#include <ksconfig.h>\fP
.PP
Inherits \fBQWidget\fP.
.PP
.SS "Public Slots"

.in +1c
.ti -1c
.RI "void \fBactivateHelp\fP (void)"
.br
.in -1c
.SS "Signals"

.in +1c
.ti -1c
.RI "void \fBconfigChanged\fP ()"
.br
.in -1c
.SS "Public Member Functions"

.in +1c
.ti -1c
.RI "\fBKSpellConfig\fP (\fBQWidget\fP *parent=0, const char *name=0, \fBKSpellConfig\fP *spellConfig=0, bool addHelpButton=true)"
.br
.ti -1c
.RI "\fBKSpellConfig\fP (const \fBKSpellConfig\fP &)"
.br
.ti -1c
.RI "virtual \fB~KSpellConfig\fP ()"
.br
.ti -1c
.RI "void \fBoperator=\fP (const \fBKSpellConfig\fP &ksc)"
.br
.ti -1c
.RI "void \fBfillDicts\fP (\fBQComboBox\fP *box, \fBQStringList\fP *dictionaries=0)"
.br
.ti -1c
.RI "void \fBsetIgnoreList\fP (\fBQStringList\fP _ignorelist)"
.br
.ti -1c
.RI "void \fBsetReplaceAllList\fP (\fBQStringList\fP _replaceAllList)"
.br
.ti -1c
.RI "void \fBsetNoRootAffix\fP (bool)"
.br
.ti -1c
.RI "void \fBsetRunTogether\fP (bool)"
.br
.ti -1c
.RI "void \fBsetDictionary\fP (const \fBQString\fP qs)"
.br
.ti -1c
.RI "void \fBsetDictFromList\fP (bool dfl)"
.br
.ti -1c
.RI "void \fBsetEncoding\fP (int enctype)"
.br
.ti -1c
.RI "void \fBsetClient\fP (int client)"
.br
.ti -1c
.RI "bool \fBnoRootAffix\fP () const "
.br
.ti -1c
.RI "bool \fBrunTogether\fP () const "
.br
.ti -1c
.RI "const \fBQString\fP \fBdictionary\fP () const "
.br
.ti -1c
.RI "bool \fBdictFromList\fP () const "
.br
.ti -1c
.RI "int \fBencoding\fP () const "
.br
.ti -1c
.RI "\fBQStringList\fP \fBignoreList\fP () const "
.br
.ti -1c
.RI "\fBQStringList\fP \fBreplaceAllList\fP () const "
.br
.ti -1c
.RI "int \fBclient\fP () const "
.br
.ti -1c
.RI "bool \fBwriteGlobalSettings\fP ()"
.br
.ti -1c
.RI "bool \fBreadGlobalSettings\fP ()"
.br
.in -1c
.SS "Protected Types"

.in +1c
.ti -1c
.RI "enum { \fBrdictlist\fP = 3, \fBrencoding\fP = 4, \fBrhelp\fP = 6 }"
.br
.in -1c
.SS "Protected Slots"

.in +1c
.ti -1c
.RI "void \fBsHelp\fP ()"
.br
.ti -1c
.RI "void \fBsNoAff\fP (bool)"
.br
.ti -1c
.RI "void \fBsRunTogether\fP (bool)"
.br
.ti -1c
.RI "void \fBsDictionary\fP (bool)"
.br
.ti -1c
.RI "void \fBsPathDictionary\fP (bool)"
.br
.ti -1c
.RI "void \fBsSetDictionary\fP (int)"
.br
.ti -1c
.RI "void \fBsChangeEncoding\fP (int)"
.br
.ti -1c
.RI "void \fBsChangeClient\fP (int)"
.br
.in -1c
.SS "Protected Member Functions"

.in +1c
.ti -1c
.RI "void \fBfillInDialog\fP ()"
.br
.ti -1c
.RI "bool \fBinterpret\fP (\fBQString\fP &fname, \fBQString\fP &lname, \fBQString\fP &hname)"
.br
.in -1c
.SS "Protected Attributes"

.in +1c
.ti -1c
.RI "int \fBenc\fP"
.br
.ti -1c
.RI "bool \fBbnorootaffix\fP"
.br
.ti -1c
.RI "bool \fBbruntogether\fP"
.br
.ti -1c
.RI "bool \fBdictfromlist\fP"
.br
.ti -1c
.RI "bool \fBnodialog\fP"
.br
.ti -1c
.RI "\fBQString\fP \fBqsdict\fP"
.br
.ti -1c
.RI "\fBQString\fP \fBqspdict\fP"
.br
.ti -1c
.RI "\fBQStringList\fP \fBignorelist\fP"
.br
.ti -1c
.RI "\fBKConfig\fP * \fBkc\fP"
.br
.ti -1c
.RI "int \fBiclient\fP"
.br
.ti -1c
.RI "\fBQCheckBox\fP * \fBcb1\fP"
.br
.ti -1c
.RI "\fBQCheckBox\fP * \fBcb2\fP"
.br
.ti -1c
.RI "\fBQLabel\fP * \fBdictlist\fP"
.br
.ti -1c
.RI "\fBQComboBox\fP * \fBdictcombo\fP"
.br
.ti -1c
.RI "\fBQComboBox\fP * \fBencodingcombo\fP"
.br
.ti -1c
.RI "\fBQComboBox\fP * \fBclientcombo\fP"
.br
.ti -1c
.RI "\fBQStringList\fP \fBlangfnames\fP"
.br
.in -1c
.SH "Detailed Description"
.PP 
A configuration class/dialog for \fBKSpell\fP. 

It contains all of the options settings.The options are set to default values by the constructor and can be reset either by using the public interface or by using KSpellConfig as a widget in a dialog (or, preferably a tabbed dialog using \fBKDialogBase\fP) and letting the user change the settings. This way an application that uses \fBKSpell\fP can either rely on the default settings (in the simplest case), offer a dialog to configure \fBKSpell\fP, or offer a dialog to configure \fBKSpell\fP \fIfor this app only\fP (in which case, the application should save the settings for use next time it is run). This last option might be useful in an email program, for example, where people may be writing in a language different from that used for writing papers in their word processor.
.PP
\fBAuthor:\fP
.RS 4
David Sweet <dsweet@kde.org> 
.RE
.PP
\fBVersion:\fP
.RS 4
\fBId\fP.RS 4
\fBksconfig.h\fP 345236 2004-09-09 15:23:55Z dfaure 
.RE
.PP
.RE
.PP
\fBSee also:\fP
.RS 4
\fBKSpell\fP 
.RE
.PP

.PP
Definition at line 83 of file ksconfig.h.
.SH "Constructor & Destructor Documentation"
.PP 
.SS "KSpellConfig::KSpellConfig (\fBQWidget\fP * parent = \fC0\fP, const char * name = \fC0\fP, \fBKSpellConfig\fP * spellConfig = \fC0\fP, bool addHelpButton = \fCtrue\fP)"
.PP
Constructs a KSpellConfig with default or custom settings. 
.PP
\fBParameters:\fP
.RS 4
\fIparent\fP Parent of the widget. 
.br
\fIname\fP Widget name. 
.br
\fIspellConfig\fP Predefined configuration. If this parameter is 0, a default configuration will be used. 
.br
\fIaddHelpButton\fP Enabled or hides a help button. See activateHelp for more information. 
.RE
.PP

.PP
Definition at line 69 of file ksconfig.cpp.
.PP
References QGridLayout::addMultiCellWidget(), QGridLayout::addWidget(), KGlobal::config(), QComboBox::insertItem(), setDictionary(), setIgnoreList(), QComboBox::setInsertionPolicy(), setNoRootAffix(), setRunTogether(), and sHelp().
.SS "KSpellConfig::~\fBKSpellConfig\fP ()\fC [virtual]\fP"
.PP
Deconstructor. 
.PP
Deletes private class. 
.PP
Definition at line 166 of file ksconfig.cpp.
.SH "Member Function Documentation"
.PP 
.SS "void KSpellConfig::fillDicts (\fBQComboBox\fP * box, \fBQStringList\fP * dictionaries = \fC0\fP)"
.PP
Get the translated dictionary names and, optionally, the corresponding internal dictionary names. 
.PP
Fills \fCbox\fP with the human readable, translated dictionary names and selects the currently used dictionary (this will be the global dictionary if you call \fBfillDicts\fP directly after the constructor). If \fCdictionaries\fP isn't 0 then \fCdictionaries\fP will be filled with the corresponding internal dictionary names that are necessary to set the dictionary with \fBsetDictionary\fP.
.PP
\fBParameters:\fP
.RS 4
\fIbox\fP Will be filled with the translated dictionary names. 
.br
\fIdictionaries\fP Will be filled with the internal dictionary names.
.RE
.PP
\fBSince:\fP
.RS 4
3.2 
.RE
.PP

.PP
Definition at line 570 of file ksconfig.cpp.
.PP
References QString::arg(), QFileInfo::dirPath(), endl(), QString::endsWith(), QFileInfo::exists(), QFileInfo::filePath(), interpret(), QFileInfo::isDir(), kdDebug(), QString::length(), QString::remove(), and QFileInfo::setFile().
.SS "void KSpellConfig::setIgnoreList (\fBQStringList\fP _ignorelist)"
.PP
The \fC_ignorelist\fP contains words you'd like \fBKSpell\fP to ignore when it is spellchecking. 
.PP
When you get a KSpellConfig object back from \fBKSpell\fP (using KSpell::kcConfig()), the \fC_ignorelist\fP contains whatever was put in by you plus any words the user has chosen to ignore via the dialog box. It may be useful to save this list with the document being edited to facilitate quicker future spellchecking. 
.PP
Definition at line 962 of file ksconfig.cpp.
.PP
Referenced by KSpell::ksConfig(), and KSpellConfig().
.SS "void KSpellConfig::setReplaceAllList (\fBQStringList\fP _replaceAllList)"
.PP
The \fC_replaceAllList\fP contains word you like that replace word. 
.PP
Be careful that this list contains word which is replaced and new word. 
.PP
Definition at line 975 of file ksconfig.cpp.
.PP
Referenced by KSpell::ksConfig().
.SS "void KSpellConfig::setNoRootAffix (bool)"
.PP
Set an ISpell option. 
.PP
If \fCtrue\fP, don't create root-affix combinations. 
.PP
Definition at line 729 of file ksconfig.cpp.
.PP
References QCheckBox::setChecked().
.PP
Referenced by KSpellConfig().
.SS "void KSpellConfig::setRunTogether (bool)"
.PP
Set an ISpell option. 
.PP
If \fCtrue\fP, treat run-together words a valid. 
.PP
Definition at line 738 of file ksconfig.cpp.
.PP
References QCheckBox::setChecked().
.PP
Referenced by KSpellConfig().
.SS "void KSpellConfig::setDictionary (const \fBQString\fP qs)"
.PP
Set the name of the dictionary to use. 
.PP
Definition at line 747 of file ksconfig.cpp.
.PP
References QString::find(), QString::length(), QString::remove(), and QComboBox::setCurrentItem().
.PP
Referenced by KSpellConfig().
.SS "bool KSpellConfig::noRootAffix () const"
.PP
Options reading routines. 
.PP
Definition at line 807 of file ksconfig.cpp.
.PP
Referenced by writeGlobalSettings().
.SS "bool KSpellConfig::writeGlobalSettings ()"
.PP
Call this method before this class is deleted if you want the settings you have (or the user has) chosen to become the global, default settings. 
.PP
Definition at line 194 of file ksconfig.cpp.
.PP
References noRootAffix(), KConfigBase::sync(), and KConfigBase::writeEntry().
.SS "bool KSpellConfig::interpret (\fBQString\fP & fname, \fBQString\fP & lname, \fBQString\fP & hname)\fC [protected]\fP"
.PP
This takes a dictionary file name and provides both a language abbreviation appropriate for the $LANG variable, and a human-readable name. 
.PP
It also truncates '.aff' at the end of fname.
.PP
\fBParameters:\fP
.RS 4
\fIfname\fP the dictionary name file (input) 
.br
\fIlname\fP the language abbreviation, such as de for German (output) 
.br
\fIhname\fP the human-readable name, such as Deutsch (output)
.RE
.PP
\fBReturns:\fP
.RS 4
true if 
.PP
.nf
lname.data()==$LANG
.fi
.PP
 
.RE
.PP

.PP
Definition at line 243 of file ksconfig.cpp.
.PP
References endl(), QString::endsWith(), QString::find(), QString::isEmpty(), kdDebug(), QString::left(), QString::length(), KGlobal::locale(), QString::mid(), QString::remove(), QString::right(), QString::truncate(), KLocale::twoAlphaToCountryName(), and KLocale::twoAlphaToLanguageName().
.PP
Referenced by fillDicts().
.SS "void KSpellConfig::activateHelp (void)\fC [slot]\fP"
.PP
Use this function to activate the help information for this widget. 
.PP
The function is particulary useful if the help button is not displayed as specified by the constructor. Normally you want to hide the help button if this widget is embedded into a larger dialog box that has its own help button. See kedit (optiondialog.cpp) for an example 
.PP
Definition at line 922 of file ksconfig.cpp.
.PP
References sHelp().
.SS "void KSpellConfig::sHelp ()\fC [protected, slot]\fP"
.PP
Invokes the help documentation for kspell. 
.PP
Definition at line 927 of file ksconfig.cpp.
.PP
Referenced by activateHelp(), and KSpellConfig().

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