Undeprecate QColor(string) constructors
They are used in a lot of code, deprecating them now just creates noise and porting effort without adding any value. For Qt 7 we can remove them if we deprecate them in time for the last Qt 6 release, at which point porting effort is expected anway. Leave a ### comment behind to that effect. Change-Id: I0a4e78cf1723b02373d23d7cd52783b3f7095428 Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io> (cherry picked from commit a18a88b19bbae81a407645df2bfdd7faa180e323) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
This commit is contained in:
parent
21137dadbe
commit
7801d05844
@ -784,12 +784,10 @@ QColor::QColor(Spec spec) noexcept
|
||||
}
|
||||
}
|
||||
|
||||
#if QT_DEPRECATED_SINCE(6, 6)
|
||||
// ### Qt 7: remove those after deprecating them for the last Qt 6 LTS release
|
||||
/*!
|
||||
\fn QColor::QColor(const QString &name)
|
||||
|
||||
\deprecated [6.6] Use fromString() instead.
|
||||
|
||||
Constructs a named color in the same way as setNamedColor() using
|
||||
the given \a name.
|
||||
|
||||
@ -801,8 +799,6 @@ QColor::QColor(Spec spec) noexcept
|
||||
/*!
|
||||
\fn QColor::QColor(const char *name)
|
||||
|
||||
\deprecated [6.6] Use fromString() instead.
|
||||
|
||||
Constructs a named color in the same way as setNamedColor() using
|
||||
the given \a name.
|
||||
|
||||
@ -813,8 +809,6 @@ QColor::QColor(Spec spec) noexcept
|
||||
/*!
|
||||
\fn QColor::QColor(QLatin1StringView name)
|
||||
|
||||
\deprecated [6.6] Use fromString() instead.
|
||||
|
||||
Constructs a named color in the same way as setNamedColor() using
|
||||
the given \a name.
|
||||
|
||||
@ -822,7 +816,6 @@ QColor::QColor(Spec spec) noexcept
|
||||
\since 5.8
|
||||
\sa setNamedColor(), name(), isValid()
|
||||
*/
|
||||
#endif // QT_DEPRECATED_SINCE(6, 6)
|
||||
|
||||
/*!
|
||||
\fn bool QColor::isValid() const
|
||||
|
@ -47,16 +47,10 @@ public:
|
||||
0) {}
|
||||
QColor(QRgb rgb) noexcept;
|
||||
QColor(QRgba64 rgba64) noexcept;
|
||||
#if QT_DEPRECATED_SINCE(6, 6)
|
||||
QT_DEPRECATED_VERSION_X_6_6("Use QColor::fromString() instead.")
|
||||
inline QColor(const QString& name);
|
||||
QT_DEPRECATED_VERSION_X_6_6("Use QColor::fromString() instead.")
|
||||
explicit inline QColor(QStringView name);
|
||||
QT_DEPRECATED_VERSION_X_6_6("Use QColor::fromString() instead.")
|
||||
inline QColor(const char *aname);
|
||||
QT_DEPRECATED_VERSION_X_6_6("Use QColor::fromString() instead.")
|
||||
inline QColor(QLatin1StringView name);
|
||||
#endif
|
||||
QColor(Spec spec) noexcept;
|
||||
|
||||
static QColor fromString(QAnyStringView name) noexcept;
|
||||
|
Loading…
x
Reference in New Issue
Block a user