summaryrefslogtreecommitdiff
path: root/svx/source/xoutdev
diff options
context:
space:
mode:
authorMiklos Vajna <vmiklos@suse.cz>2013-01-28 11:56:10 +0100
committerMiklos Vajna <vmiklos@suse.cz>2013-01-28 13:49:41 +0100
commita1bef744a24b072adc22035b5b15b376961351d8 (patch)
tree9bb035b3db18f8d85769469a7621bce710628f8c /svx/source/xoutdev
parent06de72bea24a83e4a4efbc235853a40781bce168 (diff)
SwXTextFrame: use XFillGradientItem instead of extending SvxBrushItem
Change-Id: I8863cbe1d01fceac0f4b4152264c1464c90e02b8
Diffstat (limited to 'svx/source/xoutdev')
-rw-r--r--svx/source/xoutdev/xattr.cxx16
1 files changed, 16 insertions, 0 deletions
diff --git a/svx/source/xoutdev/xattr.cxx b/svx/source/xoutdev/xattr.cxx
index 6e7355e56da8..5a176b2d7931 100644
--- a/svx/source/xoutdev/xattr.cxx
+++ b/svx/source/xoutdev/xattr.cxx
@@ -50,6 +50,7 @@
#include <basegfx/point/b2dpoint.hxx>
#include <basegfx/vector/b2dvector.hxx>
#include <basegfx/tools/unotools.hxx>
+#include <vcl/gradient.hxx>
#include <stdio.h>
@@ -3119,6 +3120,21 @@ bool XGradient::operator==(const XGradient& rGradient) const
nStepCount == rGradient.nStepCount );
}
+Gradient XGradient::VclGradient() const
+{
+ Gradient aGradient;
+ aGradient.SetStyle((GradientStyle)eStyle);
+ aGradient.SetStartColor(aStartColor);
+ aGradient.SetEndColor(aEndColor);
+ aGradient.SetAngle(nAngle);
+ aGradient.SetBorder(nBorder);
+ aGradient.SetOfsX(nOfsX);
+ aGradient.SetOfsY(nOfsY);
+ aGradient.SetStartIntensity(nIntensStart);
+ aGradient.SetEndIntensity(nIntensEnd);
+ aGradient.SetSteps(nStepCount);
+ return aGradient;
+}
// -----------------------
// class XFillGradientItem