Core: Show context of filter matches

When inspecting logs often enough the relevant information is next to
the line with the unique expression that's easy to match. The `grep`
tool solves this problem by providing various `--*context` options
which configure how much context to show for each match.

This change tries to replicate this feature.

Task-number: QTCREATORBUG-30167
Change-Id: I6432870c0b958df8c5dc616009aea4ca54973245
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This commit is contained in:
Mathias Hasselmann
2024-01-07 10:50:34 +01:00
committed by hjk
parent 54532795ab
commit da2e60fa3e
15 changed files with 157 additions and 15 deletions

View File

@@ -206,7 +206,9 @@ void BuildSystemOutputWindow::updateFilter()
m_filterActionCaseSensitive.isChecked() ? Qt::CaseSensitive
: Qt::CaseInsensitive,
m_filterActionRegexp.isChecked(),
m_invertFilterAction.isChecked());
m_invertFilterAction.isChecked(),
0 /* before context */,
0 /* after context */);
}
class VanishedTargetPanelItem : public TreeItem