summaryrefslogtreecommitdiffstats
path: root/src/gui/painting/qcolortransform.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/painting/qcolortransform.h')
-rw-r--r--src/gui/painting/qcolortransform.h9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/gui/painting/qcolortransform.h b/src/gui/painting/qcolortransform.h
index 3df5be7c8b..14673fe924 100644
--- a/src/gui/painting/qcolortransform.h
+++ b/src/gui/painting/qcolortransform.h
@@ -31,16 +31,21 @@ public:
QT_MOVE_ASSIGNMENT_OPERATOR_IMPL_VIA_MOVE_AND_SWAP(QColorTransform)
void swap(QColorTransform &other) noexcept { d.swap(other.d); }
+ Q_GUI_EXPORT bool isIdentity() const noexcept;
Q_GUI_EXPORT QRgb map(QRgb argb) const;
Q_GUI_EXPORT QRgba64 map(QRgba64 rgba64) const;
Q_GUI_EXPORT QColor map(const QColor &color) const;
+ friend bool operator==(const QColorTransform &ct1, const QColorTransform &ct2)
+ { return ct1.compare(ct2); }
+ friend bool operator!=(const QColorTransform &ct1, const QColorTransform &ct2)
+ { return !ct1.compare(ct2); }
+
private:
- friend class QColorSpace;
friend class QColorSpacePrivate;
friend class QColorTransformPrivate;
- friend class QImage;
+ Q_GUI_EXPORT bool compare(const QColorTransform &other) const;
QExplicitlySharedDataPointer<QColorTransformPrivate> d;
};