QWebEngineFindTextResult#

The QWebEngineFindTextResult class encapsulates the result of a string search on a page. More

Synopsis#

Properties#

Functions#

Note

This documentation may contain snippets that were automatically translated from C++ to Python. We always welcome contributions to the snippet translation. If you see an issue with the translation, you can also let us know by creating a ticket on https:/bugreports.qt.io/projects/PYSIDE

Detailed Description#

The string search can be initiated by the findText() or findText() method. The results of the search are highlighted in the view. The details of this result are passed as a QWebEngineFindTextResult object that can be used to show a status message, such as “2 of 2 matches”. For example:

QObject::connect(view.page(), &QWebEnginePage::findTextFinished, [](const QWebEngineFindTextResult &result) {
    qInfo() << result.activeMatch() << "of" << result.numberOfMatches() << "matches";
});

Results are passed to the user in the findTextFinished() and findTextFinished() signals.

class PySide6.QtWebEngineCore.QWebEngineFindTextResult#

PySide6.QtWebEngineCore.QWebEngineFindTextResult(other)

Parameters:

otherPySide6.QtWebEngineCore.QWebEngineFindTextResult

Note

Properties can be used directly when from __feature__ import true_property is used or via accessor functions otherwise.

property PᅟySide6.QtWebEngineCore.QWebEngineFindTextResult.activeMatch: int#

This property holds The index of the currently highlighted match..

Access functions:
property PᅟySide6.QtWebEngineCore.QWebEngineFindTextResult.numberOfMatches: int#

This property holds The number of matches found..

Access functions:
PySide6.QtWebEngineCore.QWebEngineFindTextResult.activeMatch()#
Return type:

int

Getter of property activeMatch .

PySide6.QtWebEngineCore.QWebEngineFindTextResult.numberOfMatches()#
Return type:

int

Getter of property numberOfMatches .