diff options
author | Luboš Luňák <l.lunak@collabora.com> | 2020-12-01 12:39:39 +0100 |
---|---|---|
committer | Luboš Luňák <l.lunak@collabora.com> | 2020-12-01 16:28:59 +0100 |
commit | 8601eca3c8573b433933ab59180624d798c6189e (patch) | |
tree | 7b56a7200a3db81731e569d4cd8e2ca46fcdda4b /svx | |
parent | 4bf54eb22cfe604dc29c4f7e3ffa687324b19636 (diff) |
do not unnecessarily explicitly force gradient step count (tdf#138581)
Toolkits usually do not provide the ability to specify gradient steps,
which means VCL falls back to its algorithm, which at least with Skia
sometimes causes poor results.
Change-Id: I35dbf87e77d5ed36d8f257db877135a2a0be2ffe
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/106971
Tested-by: Jenkins
Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
Diffstat (limited to 'svx')
-rw-r--r-- | svx/source/sdr/primitive2d/sdrattributecreator.cxx | 3 | ||||
-rw-r--r-- | svx/source/xoutdev/xtabgrdt.cxx | 4 |
2 files changed, 2 insertions, 5 deletions
diff --git a/svx/source/sdr/primitive2d/sdrattributecreator.cxx b/svx/source/sdr/primitive2d/sdrattributecreator.cxx index d5baa905e0a8..5ee93efef85f 100644 --- a/svx/source/sdr/primitive2d/sdrattributecreator.cxx +++ b/svx/source/sdr/primitive2d/sdrattributecreator.cxx @@ -644,8 +644,7 @@ namespace drawinglayer::primitive2d static_cast<double>(rGradient.GetYOffset()) * 0.01, static_cast<double>(rGradient.GetAngle().get()) * F_PI1800, basegfx::BColor(fStartLum, fStartLum, fStartLum), - basegfx::BColor(fEndLum, fEndLum, fEndLum), - 0); + basegfx::BColor(fEndLum, fEndLum, fEndLum)); } } diff --git a/svx/source/xoutdev/xtabgrdt.cxx b/svx/source/xoutdev/xtabgrdt.cxx index fbb69a0ddd77..23bfc8313cb9 100644 --- a/svx/source/xoutdev/xtabgrdt.cxx +++ b/svx/source/xoutdev/xtabgrdt.cxx @@ -153,7 +153,6 @@ BitmapEx XGradientList::CreateBitmap( tools::Long nIndex, const Size& rSize ) co } } - const sal_uInt16 nSteps((rSize.Width() + rSize.Height()) / 3); const drawinglayer::attribute::FillGradientAttribute aFillGradient( aGradientStyle, static_cast<double>(rGradient.GetBorder()) * 0.01, @@ -161,8 +160,7 @@ BitmapEx XGradientList::CreateBitmap( tools::Long nIndex, const Size& rSize ) co static_cast<double>(rGradient.GetYOffset()) * 0.01, static_cast<double>(rGradient.GetAngle().get()) * F_PI1800, aStart, - aEnd, - nSteps); + aEnd); const drawinglayer::primitive2d::Primitive2DReference aGradientPrimitive( new drawinglayer::primitive2d::PolyPolygonGradientPrimitive2D( |