3 * \file GuiSpellchecker.h
4 * This file is part of LyX, the document processor.
5 * Licence details can be found in the file COPYING.
8 * \author Kalle Dalheimer
10 * \author Abdelrazak Younes
12 * Full author contact details are available in file CREDITS.
15 #ifndef GUISPELLCHECKER_H
16 #define GUISPELLCHECKER_H
21 class QListWidgetItem;
27 class SpellcheckerWidget : public QTabWidget
32 SpellcheckerWidget(GuiView * gv, DockView * dv, QWidget * parent = nullptr);
33 ~SpellcheckerWidget();
37 bool initialiseParams(std::string const &);
40 void on_replaceAllPB_clicked();
41 void on_suggestionsLW_itemClicked(QListWidgetItem *);
42 void on_replaceCO_highlighted(const QString & str);
43 void on_languageCO_activated(int index);
44 void on_ignoreAllPB_clicked();
45 void on_addPB_clicked();
46 void on_ignorePB_clicked();
47 void on_replacePB_clicked();
51 bool eventFilter(QObject *obj, QEvent *event) override;
57 class GuiSpellchecker : public DockView
63 GuiView & parent, ///< the main window where to dock.
64 Qt::DockWidgetArea area = Qt::RightDockWidgetArea, ///< Position of the dock (and also drawer)
65 Qt::WindowFlags flags = {});
70 void updateView() override;
71 bool initialiseParams(std::string const & sdata) override
72 { return widget_->initialiseParams(sdata); }
73 void clearParams() override {}
74 void dispatchParams() override {}
75 bool isBufferDependent() const override { return false; }
77 /// The encapsulated widget.
78 SpellcheckerWidget * widget_;
81 } // namespace frontend
84 #endif // GUISPELLCHECKER_H