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

KDECore

backgroundchecker.h

Go to the documentation of this file.
00001 /*
00002  * backgroundchecker.h
00003  *
00004  * Copyright (C)  2004  Zack Rusin <zack@kde.org>
00005  *
00006  * This library is free software; you can redistribute it and/or
00007  * modify it under the terms of the GNU Lesser General Public
00008  * License as published by the Free Software Foundation; either
00009  * version 2.1 of the License, or (at your option) any later version.
00010  *
00011  * This library is distributed in the hope that it will be useful,
00012  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00013  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00014  * Lesser General Public License for more details.
00015  *
00016  * You should have received a copy of the GNU Lesser General Public
00017  * License along with this library; if not, write to the Free Software
00018  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
00019  * 02110-1301  USA
00020  */
00021 #ifndef SONNET_BACKGROUNDCHECKER_H
00022 #define SONNET_BACKGROUNDCHECKER_H
00023 
00024 #include "speller.h"
00025 
00026 #include <kdecore_export.h>
00027 
00028 #include <QtCore/QObject>
00029 
00033 namespace Sonnet
00034 {
00035     class Speller;
00036 
00054     class KDECORE_EXPORT BackgroundChecker : public QObject
00055     {
00056         Q_OBJECT
00057     public:
00058         explicit BackgroundChecker(QObject *parent =0);
00059         explicit BackgroundChecker(const Speller &speller, QObject *parent =0);
00060         ~BackgroundChecker();
00061 
00068         void setText(const QString &text);
00069         QString text() const;
00070 
00071         QString currentContext() const;
00072 
00073         Speller speller() const;
00074         void setSpeller(const Speller &speller);
00075 
00076         bool checkWord(const QString &word);
00077         QStringList suggest(const QString &word) const;
00078         bool addWordToPersonal(const QString &word);
00079 
00080         void restore(KConfig *config);
00081 
00082     public Q_SLOTS:
00083         virtual void start();
00084         virtual void stop();
00085         void replace(int start, const QString &oldText,
00086                      const QString &newText);
00087         void changeLanguage(const QString &lang);
00088 
00094         virtual void continueChecking();
00095 
00096     Q_SIGNALS:
00100         void misspelling(const QString &word, int start);
00101 
00105         void done();
00106 
00107     protected:
00116         virtual QString fetchMoreText();
00117 
00122         virtual void finishedCurrentFeed();
00123 
00124     protected Q_SLOTS:
00125         void slotEngineDone();
00126     private:
00127         class Private;
00128         Private *const d;
00129     };
00130 
00131 }
00132 
00133 #endif

KDECore

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

kdelibs

Skip menu "kdelibs"
  • DNSSD
  • Interfaces
  •   KHexEdit
  •   KMediaPlayer
  •   KSpeech
  •   KTextEditor
  • Kate
  • 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
Generated for kdelibs by doxygen 1.7.3
This website is maintained by Adriaan de Groot and Allen Winter.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal