File indexing completed on 2024-05-05 04:01:24

0001 /*
0002  * nsspellcheckerclient.h
0003  *
0004  * SPDX-FileCopyrightText: 2015 Nick Shaforostoff <shaforostoff@gmail.com>
0005  *
0006  * SPDX-License-Identifier: LGPL-2.1-or-later
0007  */
0008 #ifndef KSPELL_NSSPELLCLIENT_H
0009 #define KSPELL_NSSPELLCLIENT_H
0010 
0011 #include "client_p.h"
0012 
0013 namespace Sonnet
0014 {
0015 class SpellerPlugin;
0016 }
0017 using Sonnet::SpellerPlugin;
0018 
0019 class NSSpellCheckerClient : public Sonnet::Client
0020 {
0021     Q_OBJECT
0022     Q_INTERFACES(Sonnet::Client)
0023     Q_PLUGIN_METADATA(IID "org.kde.Sonnet.NSSpellClient")
0024 public:
0025     explicit NSSpellCheckerClient(QObject *parent = nullptr);
0026     ~NSSpellCheckerClient();
0027 
0028     int reliability() const;
0029 
0030     SpellerPlugin *createSpeller(const QString &language);
0031     QStringList languages() const;
0032     QString name() const
0033     {
0034         return QStringLiteral("NSSpellChecker");
0035     }
0036 };
0037 
0038 #endif