qtbase/examples/widgets/tools/codecs
Giuseppe D'Angelo 529f052add Port QRegularExpression to QStringView, drop QStringRef
The idea is pretty simple -- add QRegularExpression matching over
QStringView. When matching over a QString, keep the string
alive (by taking a copy), and set the view onto that string.
Otherwise, just use the view provided by the user (who is then
responsible for ensuring the data stays valid while matching).

Do just minor refactorings to support this use case in a cleaner
fashion.

In QRegularExpressionMatch drop the QStringRef-returning methods, as
they cannot work any more -- in the general case there won't be a
QString to build a QStringRef from.

[ChangeLog][QtCore][QRegularExpression] All the APIs dealing
with QStringRef have been ported to QStringView, following
QStringRef deprecation in Qt 6.0.

Change-Id: Ic367991d9583cc108c045e4387c9b7288c8f1ffd
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
2020-05-31 21:46:32 +02:00
..
doc Unify license header usage. 2016-03-29 10:20:03 +00:00
encodedfiles
images Codecs example: Add a dialog for showing common C++ encodings 2018-11-30 10:00:04 +00:00
CMakeLists.txt Regenerate examples 2020-02-04 18:50:39 +00:00
codecs.pro Codecs example: Add a dialog for showing common C++ encodings 2018-11-30 10:00:04 +00:00
codecs.qrc Codecs example: Add a dialog for showing common C++ encodings 2018-11-30 10:00:04 +00:00
encodingdialog.cpp Deprecate QStringViewLiteral 2019-08-10 22:13:49 +02:00
encodingdialog.h Codecs example: Add a dialog for showing common C++ encodings 2018-11-30 10:00:04 +00:00
main.cpp Unify license header usage. 2016-03-29 10:20:03 +00:00
mainwindow.cpp Port QRegularExpression to QStringView, drop QStringRef 2020-05-31 21:46:32 +02:00
mainwindow.h Cleanup QtWidgets (tools) examples 2019-09-11 20:36:17 +02:00
previewform.cpp QComboBox: remove deprecated signals 2020-02-10 18:28:45 +01:00
previewform.h Cleanup QtWidgets (tools) examples 2019-09-11 20:36:17 +02:00