23class InPacketSearch :
public QObject
28 explicit InPacketSearch(
ProtoTree *tree, QObject *parent =
nullptr);
30 void installDelegate();
32 bool isMatch(
const QModelIndex &index)
const;
33 bool isCurrentMatch(
const QModelIndex &index)
const;
34 bool highlightsVisible()
const;
36 void setHighlightEnabled(
bool enabled);
39 void search(
const QString &pattern,
bool case_sensitive,
bool use_regex);
43 qsizetype matchCount()
const {
return matches_.size(); }
44 qsizetype currentMatchIndex()
const {
return current_match_; }
45 bool isRegexInvalid()
const {
return regex_invalid_; }
48 void matchesChanged();
51 void collectIndices(
const QModelIndex &parent, QList<QModelIndex> &out);
52 void navigateTo(qsizetype index);
53 void expandParents(
const QModelIndex &index);
56 QList<QModelIndex> matches_;
57 qsizetype current_match_;
58 bool highlight_enabled_;