Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
findwidget.h
Go to the documentation of this file.
1// Copyright (C) 2016 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0
3#ifndef FINDWIDGET_H
4#define FINDWIDGET_H
5
6#include <QtWidgets/QWidget>
7
9
10class QCheckBox;
11class QLabel;
12class QLineEdit;
13class QToolButton;
14
15class FindWidget : public QWidget
16{
18public:
19 FindWidget(QWidget *parent = nullptr);
21
22 void show();
23 void showAndClear();
24
25 QString text() const;
26 bool caseSensitive() const;
27
28 void setPalette(bool found);
29 void setTextWrappedVisible(bool visible);
30
32 void findNext();
35 void find(const QString &text, bool forward, bool incremental);
36
37protected:
38 void hideEvent(QHideEvent* event) override;
39 void showEvent(QShowEvent * event) override;
40
41private slots:
42 void updateButtons();
43 void textChanged(const QString &text);
44
45private:
46 bool eventFilter(QObject *object, QEvent *e) override;
47 QToolButton* setupToolButton(const QString &text, const QString &icon);
48
49private:
50 QPalette appPalette;
51
52 QLineEdit *editFind;
53 QCheckBox *checkCase;
54 QLabel *labelWrapped;
55 QToolButton *toolNext;
56 QToolButton *toolClose;
57 QToolButton *toolPrevious;
58};
59
60QT_END_NAMESPACE
61
62#endif // FINDWIDGET_H
QString currentTitle() const
void backwardAvailable(bool available)
bool isBackwardAvailable() const
HelpViewer * viewerAt(int index) const
int currentIndex() const
static CentralWidget * instance()
void forwardAvailable(bool available)
bool hasSelection() const
CentralWidget(QWidget *parent=nullptr)
bool eventFilter(QObject *object, QEvent *e) override
Filters events if this object has been installed as an event filter for the watched object.
QUrl currentSource() const
HelpViewer * currentHelpViewer() const
void focusInEvent(QFocusEvent *event) override
This event handler can be reimplemented in a subclass to receive keyboard focus events (focus receive...
void updateUserInterface()
~CentralWidget() override
bool isForwardAvailable() const
QString text() const
void escapePressed()
void findPrevious()
void showEvent(QShowEvent *event) override
This event handler can be reimplemented in a subclass to receive widget show events which are passed ...
void showAndClear()
void setPalette(bool found)
bool eventFilter(QObject *object, QEvent *e) override
Filters events if this object has been installed as an event filter for the watched object.
void find(const QString &text, bool forward, bool incremental)
~FindWidget() override
void hideEvent(QHideEvent *event) override
This event handler can be reimplemented in a subclass to receive widget hide events.
bool caseSensitive() const
void show()
void setTextWrappedVisible(bool visible)
QHelpSearchEngine * searchEngine() const
static HelpEngineWrapper & instance()
void setLastTabPage(int lastPage)
void scaleUp()
void forwardAvailable(bool enabled)
void resetScale()
void loadFinished()
void forward()
void scaleDown()
bool isForwardAvailable() const
void backward()
void backwardAvailable(bool enabled)
bool isBackwardAvailable() const
HelpViewer * createBlankPage()
static OpenPagesManager * instance()
void setCurrent(HelpViewer *viewer)
void removeTabAt(HelpViewer *viewer)
Combined button and popup list for selecting options.
#define TRACE_OBJ
Definition tracer.h:34