• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdelibs API Reference
  • KDE Home
  • Contact Us
 

KDE3Support

  • sources
  • kde-4.14
  • kdelibs
  • kde3support
  • kdeui
k3sconfig.h
Go to the documentation of this file.
1 /* This file is part of the KDE libraries
2  Copyright (C) 1997 David Sweet <dsweet@kde.org>
3  Copyright (C) 2007-2008 Kevin Kofler <Kevin@tigcc.ticalc.org>
4 
5  This library is free software; you can redistribute it and/or
6  modify it under the terms of the GNU Library General Public
7  License version 2 as published by the Free Software Foundation.
8 
9  This library is distributed in the hope that it will be useful,
10  but WITHOUT ANY WARRANTY; without even the implied warranty of
11  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12  Library General Public License for more details.
13 
14  You should have received a copy of the GNU Library General Public License
15  along with this library; see the file COPYING.LIB. If not, write to
16  the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
17  Boston, MA 02110-1301, USA.
18 */
19 #ifndef KDELIBS_KSCONFIG_H
20 #define KDELIBS_KSCONFIG_H
21 
22 #include <kde3support_export.h>
23 #include <ksharedconfig.h>
24 
25 #include <QtGui/QWidget>
26 #include <QtCore/QStringList>
27 
28 class QCheckBox;
29 class QComboBox;
30 class QLabel;
31 
32 class K3SpellConfigPrivate;
33 
41 enum Encoding {
42  KS_E_ASCII=0,
43  KS_E_LATIN1=1,
44  KS_E_LATIN2=2,
45  KS_E_LATIN3=3,
46  KS_E_LATIN4=4,
47  KS_E_LATIN5=5,
48  KS_E_LATIN7=6,
49  KS_E_LATIN8=7,
50  KS_E_LATIN9=8,
51  KS_E_LATIN13=9,
52  KS_E_LATIN15=10,
53  KS_E_UTF8=11,
54  KS_E_KOI8R=12,
55  KS_E_KOI8U=13,
56  KS_E_CP1251=14,
57  KS_E_CP1255=15
58 };
59 
60 enum K3SpellClients {
61  KS_CLIENT_ISPELL=0,
62  KS_CLIENT_ASPELL=1,
63  KS_CLIENT_HSPELL=2,
64  KS_CLIENT_ZEMBEREK=3,
65  KS_CLIENT_HUNSPELL=4
66 };
67 
88 class KDE3SUPPORT_EXPORT_DEPRECATED K3SpellConfig : public QWidget
89 {
90  Q_OBJECT
91 
92  public:
103  explicit K3SpellConfig( QWidget *parent=0,
104  K3SpellConfig *spellConfig=0, bool addHelpButton = true );
105 
106  K3SpellConfig( const K3SpellConfig & );
107 
112  virtual ~K3SpellConfig();
113 
114  void operator=( const K3SpellConfig &ksc );
115 
132  void fillDicts( QComboBox* box, QStringList* dictionaries = 0 );
133 
148  void setIgnoreList( const QStringList &_ignorelist );
149 
155  void setReplaceAllList( const QStringList &_replaceAllList );
156 
162  void setNoRootAffix( bool );
163 
167  void setDoSpellChecking( bool b);
168 
174  void setRunTogether( bool );
175 
179  void setDictionary( const QString qs );
180  void setDictFromList( bool dfl );
181  //void setPersonalDict (const char *s);
182 
186  void setEncoding( int enctype );
187  void setClient( int client );
188 
192  bool doSpellChecking() const;
193  bool noRootAffix() const;
194  bool runTogether() const;
195  const QString dictionary() const;
196  bool dictFromList() const;
197  //QString personalDict () const;
198  int encoding() const;
199  QStringList ignoreList() const;
200  QStringList replaceAllList() const;
201 
202  int client() const;
203 
209  bool writeGlobalSettings();
210 
211  bool readGlobalSettings();
212  protected:
213  void fillInDialog();
214 
228  bool interpret( const QString &fname, QString &lname, QString &hname );
229 
230 
231  public Q_SLOTS:
240  void activateHelp( void );
241 
242 
243  protected Q_SLOTS:
247  void sHelp();
248  //void sBrowseDict();
249  //void sBrowsePDict();
250  void sDoSpell();
251  void sNoAff( bool );
252  void sRunTogether( bool );
253  void sDictionary( bool );
254  void sPathDictionary( bool );
255  void sSetDictionary( int );
256  void sChangeEncoding( int );
257  void sChangeClient( int );
258  //void textChanged1 (const char *);
259  //void textChanged2 (const char *);
260 
261  protected:
262  // The options
263  int enc; // 1 ==> -Tlatin1
264  bool bdospellchecking;
265  bool bnorootaffix; // -m
266  bool bruntogether; // -B
267  bool dictfromlist;
268  bool nodialog;
269  QString qsdict; // -d [dict]
270  QString qspdict; // -p [dict]
271  QStringList ignorelist;
272  enum {rdictlist=3, rencoding=4, rhelp=6};
273  KSharedConfig::Ptr kc;
274  int iclient; // defaults to ispell, may be aspell, too
275 
276  QCheckBox *cb0, *cb1, *cb2;
277  //KLineEdit *kle1, *kle2;
278  //QButtonGroup *dictgroup;
279  //QRadioButton *dictlistbutton, *dicteditbutton;
280  QLabel *dictlist;
281  QComboBox *dictcombo, *encodingcombo, *clientcombo;
282  //QPushButton *browsebutton1;
283  QStringList langfnames;
284 
285 Q_SIGNALS:
286  void configChanged();
287 
288 private:
289  K3SpellConfigPrivate *const d;
290  void getAvailDictsIspell();
291  void getAvailDictsAspell();
292  void getAvailDictsHunspell();
293 };
294 
295 #endif // KDELIBS_KSCONFIG_H
296 
297 
298 
299 
300 
KS_E_LATIN4
Definition: k3sconfig.h:46
KS_E_LATIN8
ISO-8859-7 (Greek)
Definition: k3sconfig.h:49
KSharedPtr< KSharedConfig >
QWidget
KS_E_LATIN15
ISO-8859-15 (Latin 9)
Definition: k3sconfig.h:52
K3SpellConfig::qspdict
QString qspdict
Definition: k3sconfig.h:270
KS_E_KOI8R
Definition: k3sconfig.h:54
K3SpellConfig
A configuration class/dialog for K3Spell.
Definition: k3sconfig.h:88
K3SpellConfig::langfnames
QStringList langfnames
Definition: k3sconfig.h:283
KS_E_LATIN13
ISO-8859-13 (Latin 7)
Definition: k3sconfig.h:51
K3SpellConfig::qsdict
QString qsdict
Definition: k3sconfig.h:269
KS_CLIENT_HUNSPELL
Definition: k3sconfig.h:65
KS_CLIENT_ASPELL
Definition: k3sconfig.h:62
KS_E_LATIN2
Definition: k3sconfig.h:44
KS_E_KOI8U
Definition: k3sconfig.h:55
K3SpellConfig::iclient
int iclient
Definition: k3sconfig.h:274
KS_CLIENT_ISPELL
Definition: k3sconfig.h:61
KS_CLIENT_HSPELL
Definition: k3sconfig.h:63
KS_E_CP1255
Definition: k3sconfig.h:57
kde3support_export.h
QCheckBox
Encoding
Encoding
Encoding for the spell checker.
Definition: k3sconfig.h:41
K3SpellConfig::ignorelist
QStringList ignorelist
Definition: k3sconfig.h:271
ksharedconfig.h
QString
KS_E_UTF8
Definition: k3sconfig.h:53
QStringList
K3SpellConfig::bdospellchecking
bool bdospellchecking
Definition: k3sconfig.h:264
K3SpellConfig::dictlist
QLabel * dictlist
Definition: k3sconfig.h:280
K3SpellConfig::nodialog
bool nodialog
Definition: k3sconfig.h:268
KS_E_LATIN5
ISO-8859-5 (Cyrillic)
Definition: k3sconfig.h:47
KS_E_ASCII
Definition: k3sconfig.h:42
KS_E_LATIN1
Definition: k3sconfig.h:43
K3SpellConfig::enc
int enc
Definition: k3sconfig.h:263
KS_E_LATIN9
ISO-8859-8 (Hebrew)
Definition: k3sconfig.h:50
KS_E_LATIN3
Definition: k3sconfig.h:45
KS_E_CP1251
Definition: k3sconfig.h:56
K3SpellConfig::dictfromlist
bool dictfromlist
Definition: k3sconfig.h:267
K3SpellClients
K3SpellClients
Definition: k3sconfig.h:60
K3SpellConfig::encodingcombo
QComboBox * encodingcombo
Definition: k3sconfig.h:281
QLabel
K3SpellConfig::kc
KSharedConfig::Ptr kc
Definition: k3sconfig.h:273
KS_E_LATIN7
ISO-8859-6 (Arabic)
Definition: k3sconfig.h:48
K3SpellConfig::cb2
QCheckBox * cb2
Definition: k3sconfig.h:276
K3SpellConfig::bnorootaffix
bool bnorootaffix
Definition: k3sconfig.h:265
K3SpellConfig::bruntogether
bool bruntogether
Definition: k3sconfig.h:266
QComboBox
KS_CLIENT_ZEMBEREK
Definition: k3sconfig.h:64
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:26:48 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

KDE3Support

Skip menu "KDE3Support"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members
  • Related Pages

kdelibs API Reference

Skip menu "kdelibs API Reference"
  • DNSSD
  • Interfaces
  •   KHexEdit
  •   KMediaPlayer
  •   KSpeech
  •   KTextEditor
  • kconf_update
  • KDE3Support
  •   KUnitTest
  • KDECore
  • KDED
  • KDEsu
  • KDEUI
  • KDEWebKit
  • KDocTools
  • KFile
  • KHTML
  • KImgIO
  • KInit
  • kio
  • KIOSlave
  • KJS
  •   KJS-API
  •   WTF
  • kjsembed
  • KNewStuff
  • KParts
  • KPty
  • Kross
  • KUnitConversion
  • KUtils
  • Nepomuk
  • Plasma
  • Solid
  • Sonnet
  • ThreadWeaver

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal