diff options
author | Simon Hausmann <simon.hausmann@theqtcompany.com> | 2015-06-04 05:56:06 +0000 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2015-06-04 05:56:06 +0000 |
commit | ccad00121d0a9d703cf715c54347b32bfc33bbfc (patch) | |
tree | 8e492f00f9ea81d87ae9126ad06c3dbc21fee3a3 /src/corelib/tools/qstring.cpp | |
parent | dc2617f35be61b4827b8e3d192c85e2feacf7f6a (diff) | |
parent | e2f66f921594b7be4af4a058c959557489e86879 (diff) |
Merge "Merge remote-tracking branch 'origin/5.5' into dev" into refs/staging/dev
Diffstat (limited to 'src/corelib/tools/qstring.cpp')
-rw-r--r-- | src/corelib/tools/qstring.cpp | 112 |
1 files changed, 109 insertions, 3 deletions
diff --git a/src/corelib/tools/qstring.cpp b/src/corelib/tools/qstring.cpp index 373d25c6ad..2585686156 100644 --- a/src/corelib/tools/qstring.cpp +++ b/src/corelib/tools/qstring.cpp @@ -2721,6 +2721,8 @@ bool QString::operator<(QLatin1String other) const /*! \fn bool QString::operator<=(const QString &s1, const QString &s2) + \relates Qstring + Returns \c true if string \a s1 is lexically less than or equal to string \a s2; otherwise returns \c false. @@ -2766,9 +2768,10 @@ bool QString::operator<(QLatin1String other) const */ /*! \fn bool QString::operator>(const QString &s1, const QString &s2) + \relates QString - Returns \c true if string \a s1 is lexically greater than string \a - s2; otherwise returns \c false. + Returns \c true if string \a s1 is lexically greater than string \a s2; + otherwise returns \c false. The comparison is based exclusively on the numeric Unicode values of the characters and is very fast, but is not what a human would @@ -8923,6 +8926,110 @@ bool operator<(const QStringRef &s1,const QStringRef &s2) */ /*! + \fn bool QStringRef::operator==(const char * s) const + + \overload operator==() + + The \a s byte array is converted to a QStringRef using the + fromUtf8() function. This function stops conversion at the + first NUL character found, or the end of the byte array. + + You can disable this operator by defining \c + QT_NO_CAST_FROM_ASCII when you compile your applications. This + can be useful if you want to ensure that all user-visible strings + go through QObject::tr(), for example. + + Returns \c true if this string is lexically equal to the parameter + string \a s. Otherwise returns \c false. + +*/ + +/*! + \fn bool QStringRef::operator!=(const char * s) const + + \overload operator!=() + + The \a s const char pointer is converted to a QStringRef using + the fromUtf8() function. + + You can disable this operator by defining \c + QT_NO_CAST_FROM_ASCII when you compile your applications. This + can be useful if you want to ensure that all user-visible strings + go through QObject::tr(), for example. + + Returns \c true if this string is not lexically equal to the parameter + string \a s. Otherwise returns \c false. +*/ + +/*! + \fn bool QStringRef::operator<(const char * s) const + + \overload operator<() + + The \a s const char pointer is converted to a QStringRef using + the fromUtf8() function. + + You can disable this operator by defining \c + QT_NO_CAST_FROM_ASCII when you compile your applications. This + can be useful if you want to ensure that all user-visible strings + go through QObject::tr(), for example. + + Returns \c true if this string is lexically smaller than the parameter + string \a s. Otherwise returns \c false. +*/ + +/*! + \fn bool QStringRef::operator<=(const char * s) const + + \overload operator<=() + + The \a s const char pointer is converted to a QStringRef using + the fromUtf8() function. + + You can disable this operator by defining \c + QT_NO_CAST_FROM_ASCII when you compile your applications. This + can be useful if you want to ensure that all user-visible strings + go through QObject::tr(), for example. + + Returns \c true if this string is lexically smaller than or equal to the parameter + string \a s. Otherwise returns \c false. +*/ + +/*! + \fn bool QStringRef::operator>(const char * s) const + + + \overload operator>() + + The \a s const char pointer is converted to a QStringRef using + the fromUtf8() function. + + You can disable this operator by defining \c + QT_NO_CAST_FROM_ASCII when you compile your applications. This + can be useful if you want to ensure that all user-visible strings + go through QObject::tr(), for example. + + Returns \c true if this string is lexically greater than the parameter + string \a s. Otherwise returns \c false. +*/ + +/*! + \fn bool QStringRef::operator>= (const char * s) const + + \overload operator>=() + + The \a s const char pointer is converted to a QStringRef using + the fromUtf8() function. + + You can disable this operator by defining \c + QT_NO_CAST_FROM_ASCII when you compile your applications. This + can be useful if you want to ensure that all user-visible strings + go through QObject::tr(), for example. + + Returns \c true if this string is lexically greater than or equal to the + parameter string \a s. Otherwise returns \c false. +*/ +/*! \typedef QString::Data \internal */ @@ -10332,7 +10439,6 @@ QString QString::toHtmlEscaped() const \endlist */ - /*! \internal */ |