diff options
author | thb <thb@openoffice.org> | 2010-01-18 18:58:26 +0100 |
---|---|---|
committer | thb <thb@openoffice.org> | 2010-01-18 18:58:26 +0100 |
commit | 421435cce60b68ed759589522e9f01faf56268aa (patch) | |
tree | 3324928287843311c45dc8391e24c0a08004e8d8 /drawinglayer | |
parent | eb858abc185255dfc2f676918ba6b586b50a9083 (diff) |
#i105937# Post-merge fixes
* nicer gradient poly setup, made code more self-explanatory
* corrected order of rotation matrix multiplication
* fixed build breakage in presenter screen, type only implicitely
included
Diffstat (limited to 'drawinglayer')
-rw-r--r-- | drawinglayer/source/primitive2d/fillgradientprimitive2d.cxx | 8 | ||||
-rw-r--r-- | drawinglayer/source/processor2d/vclhelpergradient.cxx | 6 |
2 files changed, 7 insertions, 7 deletions
diff --git a/drawinglayer/source/primitive2d/fillgradientprimitive2d.cxx b/drawinglayer/source/primitive2d/fillgradientprimitive2d.cxx index 13c2d9be0971..a5bfaa39659b 100644 --- a/drawinglayer/source/primitive2d/fillgradientprimitive2d.cxx +++ b/drawinglayer/source/primitive2d/fillgradientprimitive2d.cxx @@ -221,16 +221,16 @@ namespace drawinglayer if(attribute::GRADIENTSTYLE_RADIAL == maFillGradient.getStyle() || attribute::GRADIENTSTYLE_ELLIPTICAL == maFillGradient.getStyle()) { - const basegfx::B2DPoint aCircleCenter(0.5, 0.5); - aUnitPolygon = basegfx::tools::createPolygonFromEllipse(aCircleCenter, 0.5, 0.5); + aUnitPolygon = basegfx::tools::createPolygonFromCircle( + basegfx::B2DPoint(0,0), 1); } else if(attribute::GRADIENTSTYLE_LINEAR == maFillGradient.getStyle()) { - aUnitPolygon = basegfx::tools::createPolygonFromRect(basegfx::B2DRange(0.0, 0.0, 1.0, 1.0)); + aUnitPolygon = basegfx::tools::createPolygonFromRect(basegfx::B2DRange(0, 0, 1, 1)); } else { - aUnitPolygon = basegfx::tools::createPolygonFromRect(basegfx::B2DRange(-1.0, -1.0, 1.0, 1.0)); + aUnitPolygon = basegfx::tools::createPolygonFromRect(basegfx::B2DRange(-1, -1, 1, 1)); } // get the transform matrices and colors (where colors diff --git a/drawinglayer/source/processor2d/vclhelpergradient.cxx b/drawinglayer/source/processor2d/vclhelpergradient.cxx index fb6ba566f19c..aa8da41347b5 100644 --- a/drawinglayer/source/processor2d/vclhelpergradient.cxx +++ b/drawinglayer/source/processor2d/vclhelpergradient.cxx @@ -229,7 +229,7 @@ namespace drawinglayer texture::GeoTexSvxGradientLinear aGradient(aOutlineRange, rStart, rEnd, nSteps, fBorder, fAngle); aGradient.appendTransformations(aMatrices); aGradient.appendColors(aColors); - aUnitPolygon = basegfx::tools::createPolygonFromRect(basegfx::B2DRange(0.0, 0.0, 1.0, 1.0)); + aUnitPolygon = basegfx::tools::createPolygonFromRect(basegfx::B2DRange(0, 0, 1, 1)); break; } case attribute::GRADIENTSTYLE_AXIAL: @@ -245,7 +245,7 @@ namespace drawinglayer texture::GeoTexSvxGradientRadial aGradient(aOutlineRange, rStart, rEnd, nSteps, fBorder, fOffsetX, fOffsetY); aGradient.appendTransformations(aMatrices); aGradient.appendColors(aColors); - aUnitPolygon = basegfx::tools::createPolygonFromEllipse(basegfx::B2DPoint(0,0), 1, 1); + aUnitPolygon = basegfx::tools::createPolygonFromCircle(basegfx::B2DPoint(0,0), 1); break; } case attribute::GRADIENTSTYLE_ELLIPTICAL: @@ -253,7 +253,7 @@ namespace drawinglayer texture::GeoTexSvxGradientElliptical aGradient(aOutlineRange, rStart, rEnd, nSteps, fBorder, fOffsetX, fOffsetX, fAngle); aGradient.appendTransformations(aMatrices); aGradient.appendColors(aColors); - aUnitPolygon = basegfx::tools::createPolygonFromEllipse(basegfx::B2DPoint(0,0), 1, 1); + aUnitPolygon = basegfx::tools::createPolygonFromCircle(basegfx::B2DPoint(0,0), 1); break; } case attribute::GRADIENTSTYLE_SQUARE: |