BibleTime
|
#include "cswordmodulesearch.h"
#include <algorithm>
#include <QChar>
#include <QDataStream>
#include <QRegularExpression>
#include <QRegularExpressionMatch>
#include <QStringList>
#include <QtCore>
#include "../util/btassert.h"
#include "config/btconfig.h"
#include "drivers/cswordmoduleinfo.h"
#include "managers/cswordbackend.h"
#include <listkey.h>
Go to the source code of this file.
Namespaces | |
CSwordModuleSearch | |
CSwordModuleSearch::anonymous_namespace{cswordmodulesearch.cpp} | |
Functions | |
for (auto const &word :queryParser(searchedText)) | |
for (QRegularExpressionMatch match;;) | |
QString | CSwordModuleSearch::highlightSearchedText (QString const &content, QString const &searchedText, bool plainSearchedText) |
if (plainSearchedText) | |
return r | join (QString()) |
QDataStream & | operator<< (QDataStream &out, const CSwordModuleSearch::SearchType &searchType) |
QDataStream & | operator>> (QDataStream &in, CSwordModuleSearch::SearchType &searchType) |
QString | prepareSearchText (QString const &orig, SearchType const searchType) |
QStringList | CSwordModuleSearch::anonymous_namespace{cswordmodulesearch.cpp}::queryParser (QString const &queryString) |
QStringList | r (content.left(bodyIndex)) |
Results | CSwordModuleSearch::search (QString const &searchText, BtConstModuleList const &modules, sword::ListKey scope) |
static QRegularExpression const | CSwordModuleSearch::anonymous_namespace{cswordmodulesearch.cpp}::spaceRegexp (spaceRegexpString) |
static auto const | CSwordModuleSearch::anonymous_namespace{cswordmodulesearch.cpp}::spaceRegexpString (QStringLiteral(R"PCRE(\s+)PCRE")) |
Variables | |
else | |
auto | fragmentEnd = ret.indexOf(QLatin1Char('<'), fragmentStart) |
decltype(ret.size()) | fragmentSize |
auto | fragmentStart = 0 |
QRegularExpression | highlightRegex |
for | ( | auto const &word | :queryParsersearchedText | ) |
Definition at line 254 of file cswordmodulesearch.cpp.
References fragmentEnd, fragmentSize, and fragmentStart.
for | ( | QRegularExpressionMatch match;; | ) |
Definition at line 294 of file cswordmodulesearch.cpp.
References fragmentEnd, fragmentSize, fragmentStart, highlightRegex, and r().
if | ( | plainSearchedText | ) |
Definition at line 247 of file cswordmodulesearch.cpp.
References highlightRegex, CSwordModuleSearch::anonymous_namespace{cswordmodulesearch.cpp}::spaceRegexp(), and CSwordModuleSearch::anonymous_namespace{cswordmodulesearch.cpp}::spaceRegexpString().
Referenced by BtBibleKeyWidget::BtBibleKeyWidget(), CAcceleratorSettingsPage::CAcceleratorSettingsPage(), CBookmarkIndex::CBookmarkIndex(), CMDIArea::CMDIArea(), CSwordSetupInstallSourcesDialog::CSwordSetupInstallSourcesDialog(), CKeyChooserWidget::init(), and main().
QDataStream& operator<< | ( | QDataStream & | out, |
const CSwordModuleSearch::SearchType & | searchType | ||
) |
Definition at line 355 of file cswordmodulesearch.cpp.
QDataStream& operator>> | ( | QDataStream & | in, |
CSwordModuleSearch::SearchType & | searchType | ||
) |
Definition at line 360 of file cswordmodulesearch.cpp.
QString prepareSearchText | ( | QString const & | orig, |
SearchType const | searchType | ||
) |
Definition at line 340 of file cswordmodulesearch.cpp.
References CSwordModuleSearch::FullType, CSwordModuleSearch::OrType, and CSwordModuleSearch::anonymous_namespace{cswordmodulesearch.cpp}::spaceRegexp().
QStringList r | ( | content. | leftbodyIndex | ) |
Referenced by BtBookmarksModel::addBookmark(), BtConfig::booknameLanguage(), for(), util::directory::anonymous_namespace{directory.cpp}::getDocFile(), BtModuleIndexDialog::indexAllModulesPrivate(), BibleTimeApp::initBtConfig(), main(), Search::CSearchAnalysisItem::paint(), Search::CSearchAnalysisLegendItem::paint(), BtActionCollection::removeAction(), BtModuleTextModel::roleNames(), and CSwordModuleSearch::search().
else |
Definition at line 252 of file cswordmodulesearch.cpp.
auto fragmentEnd = ret.indexOf(QLatin1Char('<'), fragmentStart) |
Definition at line 291 of file cswordmodulesearch.cpp.
Referenced by for().
decltype(ret.size()) fragmentSize |
auto fragmentStart = 0 |
Definition at line 290 of file cswordmodulesearch.cpp.
Referenced by for().
highlightRegex |
Definition at line 246 of file cswordmodulesearch.cpp.