2 * \file QSpellcheckerDialog.C
3 * This file is part of LyX, the document processor.
4 * Licence details can be found in the file COPYING.
8 * Full author contact details are available in file CREDITS
14 #pragma implementation
17 #include "QSpellcheckerDialog.h"
18 #include "QSpellchecker.h"
21 #include <qpushbutton.h>
22 #include <qlineedit.h>
24 #include <qcombobox.h>
27 QSpellcheckerDialog::QSpellcheckerDialog(QSpellchecker * form)
28 : QSpellcheckerDialogBase(0, 0, false, 0),
31 connect(closePB, SIGNAL(clicked()),
36 void QSpellcheckerDialog::stop()
42 void QSpellcheckerDialog::acceptClicked()
48 void QSpellcheckerDialog::spellcheckClicked()
54 void QSpellcheckerDialog::addClicked()
60 void QSpellcheckerDialog::replaceClicked()
66 void QSpellcheckerDialog::ignoreClicked()
72 void QSpellcheckerDialog::suggestionChanged(QString const & str)
74 if (replaceCO->count() != 0)
75 replaceCO->changeItem(str, 0);
77 replaceCO->insertItem(str);
79 replaceCO->setCurrentItem(0);
83 void QSpellcheckerDialog::replaceChanged(QString const & str)
85 if (suggestionsLB->currentText() == str)
89 for (; i < suggestionsLB->count(); ++i) {
90 if (suggestionsLB->text(i) == str)
94 if (i != suggestionsLB->count())
95 suggestionsLB->setCurrentItem(i);
99 void QSpellcheckerDialog::closeEvent(QCloseEvent * e)
107 void QSpellcheckerDialog::reject()
110 QSpellcheckerDialogBase::reject();