okular/part/searchwidget.h
David Hurka 19d5dd8ec7 New part/ directory for okularpart sources from /, ui/, conf/
Source files are no longer separated by UI and non-UI and similar,
but only by their build target.

* ui/ -> part/
* Move all source files from conf/ to part/
* Keep config skeleton definitions in conf/, needed for the mobile target too
* Move editdrawingtooldialogtest.h from conf/autotests/ to autotests/
* ui/data/icons/ -> icons/
* Move /part.cpp, /part.rc and similar files to part/
* Adapt include paths in source files
* Adapt CMakeLists.txt files (in / and in subdirectories)
* Adapt /Messages.sh
2020-11-18 19:32:56 +00:00

49 lines
1.5 KiB
C++

/***************************************************************************
* Copyright (C) 2004 by Enrico Ros <eros.kde@email.it> *
* *
* This program is free software; you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. *
***************************************************************************/
#ifndef _OKULAR_SEARCHWIDGET_H_
#define _OKULAR_SEARCHWIDGET_H_
#include <qwidget.h>
namespace Okular
{
class Document;
}
class QAction;
class QMenu;
class SearchLineEdit;
/**
* @short A widget for find-as-you-type search. Outputs to the Document.
*
* This widget accepts keyboard input and performs a call to findTextAll(..)
* in the Okular::Document class when there are 3 or more chars to search for.
* It supports case sensitive/unsensitive(default) and provides a button
* for switching between the 2 modes.
*/
class SearchWidget : public QWidget
{
Q_OBJECT
public:
SearchWidget(QWidget *parent, Okular::Document *document);
void clearText();
private:
QMenu *m_menu;
QAction *m_matchPhraseAction, *m_caseSensitiveAction, *m_marchAllWordsAction, *m_marchAnyWordsAction;
SearchLineEdit *m_lineEdit;
private Q_SLOTS:
void slotMenuChaged(QAction *);
};
#endif