summaryrefslogtreecommitdiff
path: root/vcl
diff options
context:
space:
mode:
authorMichael Stahl <mstahl@redhat.com>2014-07-01 17:48:28 +0200
committerCaolán McNamara <caolanm@redhat.com>2014-07-02 09:42:18 +0000
commita071dd3179536f1fb523ff082b5c5b155e443c59 (patch)
treeed2581c52f394a835d729cb312dc71f5b8a9b20d /vcl
parentf9d7927c615a0998456f2d72b4d88c16a0314c24 (diff)
fdo#80014: vcl: fix drawing of linear gradients
There is an off-by-one error in OutputDevice::ImplDrawLinearGradient() that causes the bottom line to remain black. (regression from 04d937c1ec36c2d9fa8c90604c81a37d30e97da6) (cherry picked from commit d51f53fedb8cd68b1b3122c7199c4ea2d3a6980f) Conflicts: vcl/source/outdev/gradient.cxx Change-Id: I33948ec8065e446a9ec7efeab5e506c93fa2e9e8 Reviewed-on: https://gerrit.libreoffice.org/10023 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'vcl')
-rw-r--r--vcl/source/gdi/outdev4.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/vcl/source/gdi/outdev4.cxx b/vcl/source/gdi/outdev4.cxx
index e817e57d6632..00e05a980fa9 100644
--- a/vcl/source/gdi/outdev4.cxx
+++ b/vcl/source/gdi/outdev4.cxx
@@ -303,7 +303,7 @@ void OutputDevice::ImplDrawLinearGradient( const Rectangle& rRect,
// Polygon for this color step
aRect.Top() = (long)( fGradientLine + ((double) i) * fScanInc );
- aRect.Bottom() = (long)( fGradientLine + ( ((double) i) + 1.0 ) * fScanInc + fScanInc*.1 );
+ aRect.Bottom() = (long)( fGradientLine + ( ((double) i) + 1.0 ) * fScanInc);
aPoly[0] = aRect.TopLeft();
aPoly[1] = aRect.TopRight();
aPoly[2] = aRect.BottomRight();