diff options
author | Liang Qi <liang.qi@theqtcompany.com> | 2015-04-06 19:10:10 +0200 |
---|---|---|
committer | Liang Qi <liang.qi@theqtcompany.com> | 2015-04-06 19:10:25 +0200 |
commit | 20cac3d9c9c22153e9e316daff32b6050ff6be6b (patch) | |
tree | b563a89475df9afb4f40841ec371be9488d5b1ed /src/widgets/styles/qfusionstyle.cpp | |
parent | 8ce85d74b692392a4ea0785360156f37418cff13 (diff) | |
parent | 9eb0b09abce28b11e4915fc9c3b3e996eb19cef2 (diff) |
Merge remote-tracking branch 'origin/5.5' into dev
Change-Id: If9fd98525b6b4ca07e5e006fc98bf372a73b8a21
Diffstat (limited to 'src/widgets/styles/qfusionstyle.cpp')
-rw-r--r-- | src/widgets/styles/qfusionstyle.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/widgets/styles/qfusionstyle.cpp b/src/widgets/styles/qfusionstyle.cpp index a5fc4eb3a2..6d722c680b 100644 --- a/src/widgets/styles/qfusionstyle.cpp +++ b/src/widgets/styles/qfusionstyle.cpp @@ -209,7 +209,10 @@ static QPixmap colorizedImage(const QString &fileName, const QColor &color, int unsigned char green = gray + qt_div_255(sourceGreen * colorDiff); unsigned char blue = gray + qt_div_255(sourceBlue * colorDiff); unsigned char alpha = qt_div_255(qAlpha(col) * qAlpha(source)); - data[x] = qRgba(red, green, blue, alpha); + data[x] = qRgba(std::min(alpha, red), + std::min(alpha, green), + std::min(alpha, blue), + alpha); } } if (rotation != 0) { |