File indexing completed on 2024-05-05 04:01:24
0001 /* 0002 * kspell_aspelldict.h 0003 * 0004 * SPDX-FileCopyrightText: 2003 Zack Rusin <zack@kde.org> 0005 * 0006 * SPDX-License-Identifier: LGPL-2.1-or-later 0007 */ 0008 #ifndef KSPELL_ASPELLDICT_H 0009 #define KSPELL_ASPELLDICT_H 0010 0011 #include "spellerplugin_p.h" 0012 0013 #include "aspell.h" 0014 0015 class ASpellDict : public Sonnet::SpellerPlugin 0016 { 0017 public: 0018 explicit ASpellDict(const QString &lang); 0019 ~ASpellDict() override; 0020 bool isCorrect(const QString &word) const override; 0021 0022 QStringList suggest(const QString &word) const override; 0023 0024 bool storeReplacement(const QString &bad, const QString &good) override; 0025 0026 bool addToPersonal(const QString &word) override; 0027 bool addToSession(const QString &word) override; 0028 0029 private: 0030 AspellConfig *m_config = nullptr; 0031 AspellSpeller *m_speller = nullptr; 0032 }; 0033 0034 #endif