ports/net-im/psi/files/patch-src_libpsi_tools_spellchecker_spellchecker.h
Alexey Dokuchaev 59494c0dce - Update `net-im/psi' to version 1.4
- Replace current 2015 Hunspell implementation (by Sergey Ilinykh and
  Vitaly Tonkacheyev) with 2009 one by Alexander Tsvyashchenko, which
  turned out to be better alternative:

   * Much faster (suggestions appear almost instantly vs. several
     hundreds milliseconds with the original implementation)
   * Better multilanguage support (tested with English and Russian)
   * Ability to limit number of suggestions in the settings dialog
   * Working "add word to the dictionary" feature

Obtained from:	http://endl.ch/content/psi-spell-checking-hunspell-support
2019-04-07 14:45:50 +00:00

19 lines
868 B
C++

--- src/libpsi/tools/spellchecker/spellchecker.h.orig 2018-11-02 00:37:04 UTC
+++ src/libpsi/tools/spellchecker/spellchecker.h
@@ -37,12 +37,11 @@ class SpellChecker : public QObject (public)
static SpellChecker* instance();
virtual bool available() const;
virtual bool writable() const;
- virtual QList<QString> suggestions(const QString&);
+ virtual QList<QString> suggestions(const QString& word, const QString& lang, unsigned max_sugs);
virtual bool isCorrect(const QString&);
- virtual bool add(const QString&);
-
- virtual void setActiveLanguages(const QList<QString>& ) {}
- virtual QList<QString> getAllLanguages() const { return QList<QString>(); }
+ virtual bool add(const QString& word, const QString& lang);
+ virtual QList<QString> getAllLanguages() const;
+ virtual void setActiveLanguages(const QList<QString>&);
protected:
SpellChecker();