Doc: Documentation for QStringList::replaceInStrings

Added the text as a \note in QString::replace and QStringlist::replace
to make it more visible to the users.

Fixes: QTBUG-63485
Pick-to: 6.7
Change-Id: I519ab079ec86103a768f313cbc5ac625a0170839
Reviewed-by: Ivan Solovev <ivan.solovev@qt.io>
(cherry picked from commit 3e56757d651ffcba9ea65aa990b4e02b05e00b17)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
This commit is contained in:
Jaishree Vyas 2024-05-29 11:12:47 +02:00 committed by Qt Cherry-pick Bot
parent 41df8e68cb
commit 859af49b97
2 changed files with 6 additions and 0 deletions

View File

@ -3786,6 +3786,9 @@ static void replace_helper(QString &str, QSpan<size_t> indices, qsizetype blen,
but \a position + \a n goes outside the strings range,
then \a n will be adjusted to stop at the end of the string.
\note If you use an empty \a before argument, the \a after argument will be
inserted \e {before and after} each character of the string.
Example:
\snippet qstring/main.cpp 40

View File

@ -382,6 +382,9 @@ QStringList QtPrivate::QStringList_filter(const QStringList *that, const QRegula
text replaced with the \a after text wherever the \a before text
is found.
\note If you use an empty \a before argument, the \a after argument will be
inserted \e {before and after} each character of the string.
\include qstringlist.cpp comparison-case-sensitivity
For example: