QColor: eradicate QT_STRINGVIEW_LEVEL
It's not used and not useful. Task-number: QTBUG-100861 Pick-to: 6.3 6.2 Change-Id: I30f7f41311182f056f2f6d5a9b49385fb09d194e Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>bb10
parent
221df41572
commit
a24ef92468
|
|
@ -873,7 +873,6 @@ QString QColor::name(NameFormat format) const
|
|||
return QString();
|
||||
}
|
||||
|
||||
#if QT_STRINGVIEW_LEVEL < 2
|
||||
/*!
|
||||
Sets the RGB value of this QColor to \a name, which may be in one
|
||||
of these formats:
|
||||
|
|
@ -902,7 +901,6 @@ void QColor::setNamedColor(const QString &name)
|
|||
{
|
||||
setColorFromString(qToStringViewIgnoringNull(name));
|
||||
}
|
||||
#endif
|
||||
|
||||
/*!
|
||||
\overload
|
||||
|
|
@ -924,7 +922,6 @@ void QColor::setNamedColor(QLatin1String name)
|
|||
setColorFromString(name);
|
||||
}
|
||||
|
||||
#if QT_STRINGVIEW_LEVEL < 2
|
||||
/*!
|
||||
\since 4.7
|
||||
|
||||
|
|
@ -940,7 +937,6 @@ bool QColor::isValidColor(const QString &name)
|
|||
{
|
||||
return isValidColor(qToStringViewIgnoringNull(name));
|
||||
}
|
||||
#endif
|
||||
|
||||
/*!
|
||||
\overload
|
||||
|
|
|
|||
|
|
@ -83,9 +83,7 @@ public:
|
|||
0) {}
|
||||
QColor(QRgb rgb) noexcept;
|
||||
QColor(QRgba64 rgba64) noexcept;
|
||||
#if QT_STRINGVIEW_LEVEL < 2
|
||||
inline QColor(const QString& name);
|
||||
#endif
|
||||
explicit inline QColor(QStringView name);
|
||||
inline QColor(const char *aname) : QColor(QLatin1String(aname)) {}
|
||||
inline QColor(QLatin1String name);
|
||||
|
|
@ -97,9 +95,7 @@ public:
|
|||
|
||||
QString name(NameFormat format = HexRgb) const;
|
||||
|
||||
#if QT_STRINGVIEW_LEVEL < 2
|
||||
void setNamedColor(const QString& name);
|
||||
#endif
|
||||
void setNamedColor(QStringView name);
|
||||
void setNamedColor(QLatin1String name);
|
||||
|
||||
|
|
@ -225,9 +221,7 @@ public:
|
|||
|
||||
operator QVariant() const;
|
||||
|
||||
#if QT_STRINGVIEW_LEVEL < 2
|
||||
static bool isValidColor(const QString &name);
|
||||
#endif
|
||||
static bool isValidColor(QStringView) noexcept;
|
||||
static bool isValidColor(QLatin1String) noexcept;
|
||||
|
||||
|
|
@ -307,10 +301,8 @@ inline QColor::QColor(QLatin1String aname)
|
|||
inline QColor::QColor(QStringView aname)
|
||||
{ setNamedColor(aname); }
|
||||
|
||||
#if QT_STRINGVIEW_LEVEL < 2
|
||||
inline QColor::QColor(const QString& aname)
|
||||
{ setNamedColor(aname); }
|
||||
#endif
|
||||
|
||||
inline bool QColor::isValid() const noexcept
|
||||
{ return cspec != Invalid; }
|
||||
|
|
|
|||
Loading…
Reference in New Issue