2006-03-05 17:24:44 +00:00
|
|
|
// -*- C++ -*-
|
|
|
|
/**
|
2007-08-31 05:53:55 +00:00
|
|
|
* \file GuiSearch.h
|
2006-03-05 17:24:44 +00:00
|
|
|
* This file is part of LyX, the document processor.
|
|
|
|
* Licence details can be found in the file COPYING.
|
|
|
|
*
|
|
|
|
* \author John Levon
|
2007-10-06 20:54:31 +00:00
|
|
|
* \author Angus Leeming
|
2006-03-05 17:24:44 +00:00
|
|
|
*
|
|
|
|
* Full author contact details are available in file CREDITS.
|
|
|
|
*/
|
|
|
|
|
2007-08-31 22:16:11 +00:00
|
|
|
#ifndef GUISEARCH_H
|
|
|
|
#define GUISEARCH_H
|
2006-03-05 17:24:44 +00:00
|
|
|
|
2007-09-05 20:33:29 +00:00
|
|
|
#include "GuiDialog.h"
|
2007-08-11 15:48:15 +00:00
|
|
|
#include "ui_SearchUi.h"
|
2007-08-31 22:16:11 +00:00
|
|
|
|
2006-03-05 17:24:44 +00:00
|
|
|
namespace lyx {
|
|
|
|
namespace frontend {
|
|
|
|
|
2007-10-09 19:34:27 +00:00
|
|
|
class GuiSearch : public GuiDialog, public Ui::SearchUi
|
2007-09-05 20:33:29 +00:00
|
|
|
{
|
2007-04-24 13:27:23 +00:00
|
|
|
Q_OBJECT
|
2007-09-05 20:33:29 +00:00
|
|
|
|
2007-04-24 13:27:23 +00:00
|
|
|
public:
|
2007-11-23 09:44:02 +00:00
|
|
|
GuiSearch(GuiView & lv);
|
2007-04-24 13:27:23 +00:00
|
|
|
|
2007-09-05 20:33:29 +00:00
|
|
|
private Q_SLOTS:
|
2007-04-24 13:27:23 +00:00
|
|
|
void findChanged();
|
|
|
|
void findClicked();
|
|
|
|
void replaceClicked();
|
|
|
|
void replaceallClicked();
|
|
|
|
|
|
|
|
private:
|
2007-12-09 22:35:04 +00:00
|
|
|
void showEvent(QShowEvent * e);
|
2007-09-05 20:33:29 +00:00
|
|
|
///
|
2007-10-06 20:54:31 +00:00
|
|
|
bool initialiseParams(std::string const &) { return true; }
|
|
|
|
void clearParams() {}
|
|
|
|
void dispatchParams() {}
|
|
|
|
bool isBufferDependent() const { return true; }
|
|
|
|
|
2013-07-21 16:51:53 +00:00
|
|
|
/// Dispatches repeatedly func with wrap around question
|
|
|
|
void wrap_dispatch(const FuncRequest & func, bool forward);
|
|
|
|
|
2007-10-06 20:54:31 +00:00
|
|
|
/// Searches occurence of string
|
|
|
|
void find(docstring const & search,
|
|
|
|
bool casesensitive, bool matchword, bool forward);
|
|
|
|
|
|
|
|
/// Replaces occurence of string
|
|
|
|
void replace(docstring const & search, docstring const & replace,
|
|
|
|
bool casesensitive, bool matchword,
|
|
|
|
bool forward, bool all);
|
2006-03-05 17:24:44 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
} // namespace frontend
|
|
|
|
} // namespace lyx
|
|
|
|
|
2007-08-31 22:16:11 +00:00
|
|
|
#endif // GUISEARCH_H
|