diff options
Diffstat (limited to 'Swift/QtUI/QtTextEdit.h')
-rw-r--r-- | Swift/QtUI/QtTextEdit.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/Swift/QtUI/QtTextEdit.h b/Swift/QtUI/QtTextEdit.h index 075728b..a940879 100644 --- a/Swift/QtUI/QtTextEdit.h +++ b/Swift/QtUI/QtTextEdit.h @@ -5,20 +5,30 @@ */ #pragma once + #include <QTextEdit> namespace Swift { + class SpellChecker; class QtTextEdit : public QTextEdit { Q_OBJECT public: QtTextEdit(QWidget* parent = 0); + virtual ~QtTextEdit(); virtual QSize sizeHint() const; signals: + void wordCorrected(QString& word); void returnPressed(); void unhandledKeyPressEvent(QKeyEvent* event); + public slots: + void handleReplaceMisspellWord(const QString& word, const QPoint& position); protected: virtual void keyPressEvent(QKeyEvent* event); + virtual void contextMenuEvent(QContextMenuEvent* event); private slots: void handleTextChanged(); + private: + SpellChecker *checker_; + void underlineMisspells(); }; } |