summaryrefslogtreecommitdiff
path: root/src/gui/image/qimage.h
diff options
context:
space:
mode:
authorAllan Sandfeld Jensen <allan.jensen@qt.io>2019-12-18 17:23:50 +0100
committerAllan Sandfeld Jensen <allan.jensen@qt.io>2020-01-05 22:30:19 +0100
commitaa542be4e005b1feedc2e17fd6ca2387bf2fea1b (patch)
tree468f6de2ccaf34d932263862e8ec5aa7489c93d2 /src/gui/image/qimage.h
parent1f87fb359fdff14e42662384a9c8a0bcb3837671 (diff)
downloadqtbase-aa542be4e005b1feedc2e17fd6ca2387bf2fea1b.tar.gz
Modernize setAlphaChannel(), and deprecated alphaChannel()
The two methods have been marked obsolete for a very long time, setAlphaChannel() is still convenient though, so this patch modernizes it and removes obsolete from the API, while marking QImage::alphaChannel() as deprecated. They don't work as getter and setter anyway, since setAlphaChannel() actually does an alpha composition. Change-Id: I634d6463f78c42bb9c5fa3df17500ec01bfcac33 Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
Diffstat (limited to 'src/gui/image/qimage.h')
-rw-r--r--src/gui/image/qimage.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/gui/image/qimage.h b/src/gui/image/qimage.h
index 7544ccca05..115071c16e 100644
--- a/src/gui/image/qimage.h
+++ b/src/gui/image/qimage.h
@@ -266,7 +266,9 @@ public:
bool hasAlphaChannel() const;
void setAlphaChannel(const QImage &alphaChannel);
- QImage alphaChannel() const;
+#if QT_DEPRECATED_SINCE(5, 15)
+ QT_DEPRECATED QImage alphaChannel() const;
+#endif
QImage createAlphaMask(Qt::ImageConversionFlags flags = Qt::AutoColor) const;
#ifndef QT_NO_IMAGE_HEURISTIC_MASK
QImage createHeuristicMask(bool clipTight = true) const;