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
searchwidget.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
4#ifndef SEARCHWIDGET_H
5#define SEARCHWIDGET_H
6
7#include <QtCore/QUrl>
8#include <QtCore/QPoint>
9
10#include <QtWidgets/QWidget>
11
13
14class QMouseEvent;
15class QHelpSearchEngine;
16class QHelpSearchResultWidget;
17
18class SearchWidget : public QWidget
19{
21
22public:
23 explicit SearchWidget(QHelpSearchEngine *engine, QWidget *parent = nullptr);
25
26 void zoomIn();
27 void zoomOut();
28 void resetZoom();
29
31 void requestShowLink(const QUrl &url);
32 void requestShowLinkInNewTab(const QUrl &url);
33
34private slots:
35 void search() const;
36 void searchingStarted();
37 void searchingFinished(int searchResultCount);
38
39private:
40 bool eventFilter(QObject* o, QEvent *e) override;
41 void keyPressEvent(QKeyEvent *keyEvent) override;
42 void contextMenuEvent(QContextMenuEvent *contextMenuEvent) override;
43
44private:
45 int zoomCount;
46 QHelpSearchEngine *searchEngine;
47 QHelpSearchResultWidget *resultWidget;
48};
49
50QT_END_NAMESPACE
51
52#endif // SEARCHWIDGET_H
QString documentTitle() const
void setText(const QString &text, const QByteArray &resources)
void setPixmap(const QPixmap &pixmap)
QSize minimumSizeHint() const override
QVariant loadResource(int type, const QUrl &name) override
This function is called when the document is loaded and for each image in the document.
void doSetSource(const QUrl &name, QTextDocument::ResourceType type) override
Attempts to load the document at the given url with the specified type.
void setText(const QString &text, const QByteArray &resources)
void subclassKeyPressEvent(QKeyEvent *event)
void focusInEvent(QFocusEvent *event) override
This event handler can be reimplemented in a subclass to receive keyboard focus events (focus receive...
void setBookmarksToolbar(QToolBar *toolBar)
void setSource(const QUrl &url)
void setSourceInNewTab(const QUrl &url)
QWidget * bookmarkDockWidget() const
~BookmarkManager() override
static void destroy()
bool eventFilter(QObject *object, QEvent *event) override
Filters events if this object has been installed as an event filter for the watched object.
void sourceChanged(const QUrl &url)
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)
void keyPressEvent(QKeyEvent *) override
This event handler, for event event, can be reimplemented in a subclass to receive key press events f...
void setSourceFromSearch(const QUrl &url)
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
void highlighted(const QUrl &link)
void setSource(const QUrl &url)
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
ShowState index() const
ShowState contents() const
ShowState bookmarks() const
bool enableRemoteControl() const
bool collectionFileGiven() const
ShowState search() const
bool syncToContent(const QUrl &url)
void focusInEvent(QFocusEvent *e) override
This event handler can be reimplemented in a subclass to receive keyboard focus events (focus receive...
void escapePressed()
void expandToDepth(int depth)
bool eventFilter(QObject *o, QEvent *e) override
Filters events if this object has been installed as an event filter for the watched object.
~ContentWindow() override
QAction * findAction() const
QAction * zoomInAction() const
QAction * nextAction() const
QList< QAction * > actionList() const
QAction * homeAction() const
QAction * backAction() const
QAction * printAction() const
QAction * zoomOutAction() const
HelpDocSettings(const HelpDocSettings &other)
bool removeDocumentation(const QString &namespaceName)
QString namespaceName(const QString &fileName) const
static bool applySettings(QHelpEngineCore *helpEngine, const HelpDocSettings &settings)
QMap< QString, QString > namespaceToFileName() const
static HelpDocSettings readSettings(QHelpEngineCore *helpEngine)
QList< QVersionNumber > versions() const
QStringList namespaces() const
HelpDocSettings(HelpDocSettings &&other)
HelpDocSettings & operator=(const HelpDocSettings &other)
void swap(HelpDocSettings &other) noexcept
QStringList components() const
HelpDocSettings & operator=(HelpDocSettings &&other)
bool addDocumentation(const QString &fileName)
QHelpFilterEngine * filterEngine() const
QHelpSearchEngine * searchEngine() const
static HelpEngineWrapper & instance()
bool addressBarEnabled() const
bool addressBarVisible() const
void setUseBrowserFont(bool useBrowserFont)
QHelpIndexModel * indexModel() const
bool filterFunctionalityEnabled() const
bool filterToolbarVisible() const
void setUseAppFont(bool useAppFont)
QHelpContentModel * contentModel() const
void focusInEvent(QFocusEvent *e) override
This event handler can be reimplemented in a subclass to receive keyboard focus events (focus receive...
void documentsActivated(const QList< QHelpLink > &documents, const QString &keyword)
void escapePressed()
void setSearchLineEditText(const QString &text)
bool eventFilter(QObject *obj, QEvent *e) override
Filters events if this object has been installed as an event filter for the watched object.
~IndexWindow() override
QString searchLineEditText() const
Definition indexwindow.h:27
void closeEvent(QCloseEvent *event) override
[21]
void setIndexString(const QString &str)
~MainWindow() override
void syncContents()
void setBookmarksVisible(bool visible)
static void activateCurrentBrowser()
void activateCurrentCentralWidgetTab()
void expandTOC(int depth)
void setIndexVisible(bool visible)
void setSearchVisible(bool visible)
void currentFilterChanged(const QString &filter)
bool usesDefaultCollection() const
QAbstractItemView * openPagesWidget() const
void setCurrentPage(HelpViewer *page)
bool pagesOpenForNamespace(const QString &nameSpace) const
HelpViewer * createNewPageFromSearch(const QUrl &url)
void pageAdded(int index)
void closePage(HelpViewer *page)
void reloadPages(const QString &nameSpace)
HelpViewer * createBlankPage()
static OpenPagesManager * instance()
void setCurrentPage(int index)
void closePages(const QString &nameSpace)
void aboutToClosePage(int index)
void updateApplicationFont()
void updateUserInterface()
\inmodule QtCore
\inmodule QtCore
QtDocInstaller(const QList< DocInfo > &docInfos)
void docsInstalled(bool newDocsInstalled)
void registerDocumentation(const QString &component, const QString &absFileName)
void run() override
~QtDocInstaller() override
void contextMenuEvent(QContextMenuEvent *contextMenuEvent) override
This event handler, for event event, can be reimplemented in a subclass to receive widget context men...
bool eventFilter(QObject *o, QEvent *e) override
Filters events if this object has been installed as an event filter for the watched object.
~SearchWidget() override
void setCurrent(HelpViewer *viewer)
void removeTabAt(HelpViewer *viewer)
QUrl link() const
Combined button and popup list for selecting options.
@ warnAboutMissingModules
static const char * docs[]
static QStringList newQtDocumentation()
#define TRACE_OBJ
Definition tracer.h:34