Show wrap indicator also for searches in help views.

Task-number: QTCREATORBUG-2753
This commit is contained in:
con
2011-01-14 11:19:57 +01:00
parent ebb9e25277
commit 7915ce6bd3
6 changed files with 36 additions and 12 deletions

View File

@@ -191,8 +191,10 @@ bool HelpViewer::isBackwardAvailable() const
}
bool HelpViewer::findText(const QString &text, Find::FindFlags flags,
bool incremental, bool fromSearch)
bool incremental, bool fromSearch, bool *wrapped)
{
if (wrapped)
*wrapped = false;
QTextDocument *doc = document();
QTextCursor cursor = textCursor();
if (!doc || cursor.isNull())
@@ -210,6 +212,8 @@ bool HelpViewer::findText(const QString &text, Find::FindFlags flags,
else
cursor.movePosition(QTextCursor::End);
found = doc->find(text, cursor, f);
if (!found.isNull() && wrapped)
*wrapped = true;
}
if (fromSearch) {