source: ogBrowser-Git/qtermwidget/lib/SearchBar.h @ ffbf8ac

jenkinsmain
Last change on this file since ffbf8ac was 64efc22, checked in by Vadim Troshchinskiy <vtroshchinskiy@…>, 19 months ago

Update qtermwidget to modern version

  • Property mode set to 100644
File size: 1.6 KB
Line 
1/*
2    Copyright 2013 Christian Surlykke
3
4    This program is free software; you can redistribute it and/or modify
5    it under the terms of the GNU General Public License as published by
6    the Free Software Foundation; either version 2 of the License, or
7    (at your option) any later version.
8
9    This program is distributed in the hope that it will be useful,
10    but WITHOUT ANY WARRANTY; without even the implied warranty of
11    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12    GNU General Public License for more details.
13
14    You should have received a copy of the GNU General Public License
15    along with this program; if not, write to the Free Software
16    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
17    02110-1301  USA.
18*/
19#ifndef _SEARCHBAR_H
20#define _SEARCHBAR_H
21
22#include <QRegExp>
23
24#include "ui_SearchBar.h"
25#include "HistorySearch.h"
26
27class SearchBar : public QWidget {
28    Q_OBJECT
29public:
30    SearchBar(QWidget* parent = nullptr);
31    ~SearchBar() override;
32    virtual void show();
33    QString searchText();
34    bool useRegularExpression();
35    bool matchCase();
36    bool highlightAllMatches();
37
38public slots:
39    void noMatchFound();
40    void hide();
41
42signals:
43    void searchCriteriaChanged();
44    void highlightMatchesChanged(bool highlightMatches);
45    void findNext();
46    void findPrevious();
47
48protected:
49    void keyReleaseEvent(QKeyEvent* keyEvent) override;
50
51private slots:
52    void clearBackgroundColor();
53
54private:
55    Ui::SearchBar widget;
56    QAction *m_matchCaseMenuEntry;
57    QAction *m_useRegularExpressionMenuEntry;
58    QAction *m_highlightMatchesMenuEntry;
59};
60
61#endif  /* _SEARCHBAR_H */
Note: See TracBrowser for help on using the repository browser.