2 * \file searchdlgimpl.h
3 * Copyright 2001 The LyX Team.
4 * See the file COPYING.
9 #include "searchdlgimpl.h"
11 #include <qpushbutton.h>
12 #include <qcombobox.h>
13 #include <qcheckbox.h>
17 SearchDlgImpl::SearchDlgImpl(FormSearch* form, QWidget* parent, const char* name, bool modal, WFlags fl )
18 : SearchDlg( parent, name, modal, fl ), form_(form)
23 SearchDlgImpl::~SearchDlgImpl()
27 void SearchDlgImpl::closeEvent(QCloseEvent * e)
33 void SearchDlgImpl::setReadOnly(bool readonly)
35 replace->setEnabled(!readonly);
36 replaceLabel->setEnabled(!readonly);
37 replacePB->setEnabled(!readonly);
38 replaceAllPB->setEnabled(!readonly);
41 void SearchDlgImpl::Find()
43 form_->find(tostr(find->currentText()).c_str(),
44 caseSensitive->isChecked(),
45 matchWord->isChecked(),
46 !searchBack->isChecked());
49 void SearchDlgImpl::Replace(bool replaceall = false)
51 form_->replace(tostr(find->currentText()).c_str(),
52 tostr(replace->currentText()).c_str(),
53 caseSensitive->isChecked(),
54 matchWord->isChecked(),
55 !searchBack->isChecked(),