Kaydet (Commit) 5a3f165b authored tarafından Miklos Vajna's avatar Miklos Vajna

svx, drawinglayer: handle tools Color <-> BackgroundColorPrimitive2D roundtrip

Change-Id: Ia8c080ef50e1ddbfce17b5c5d357a240edea46f2
(cherry picked from commit b1a9aba3)
üst e97e59a6
...@@ -1161,7 +1161,9 @@ namespace drawinglayer ...@@ -1161,7 +1161,9 @@ namespace drawinglayer
// create color for fill // create color for fill
const basegfx::BColor aPolygonColor(maBColorModifierStack.getModifiedColor(rPrimitive.getBColor())); const basegfx::BColor aPolygonColor(maBColorModifierStack.getModifiedColor(rPrimitive.getBColor()));
mpOutputDevice->SetFillColor(Color(aPolygonColor)); Color aFillColor(aPolygonColor);
aFillColor.SetTransparency(sal_uInt8((rPrimitive.getTransparency() * 255.0) + 0.5));
mpOutputDevice->SetFillColor(aFillColor);
mpOutputDevice->SetLineColor(); mpOutputDevice->SetLineColor();
// create rectangle for fill // create rectangle for fill
......
...@@ -142,7 +142,7 @@ drawinglayer::primitive2d::Primitive2DSequence ViewObjectContactOfPageBackground ...@@ -142,7 +142,7 @@ drawinglayer::primitive2d::Primitive2DSequence ViewObjectContactOfPageBackground
// init background with InitColor // init background with InitColor
xRetval.realloc(1); xRetval.realloc(1);
const basegfx::BColor aRGBColor(aInitColor.getBColor()); const basegfx::BColor aRGBColor(aInitColor.getBColor());
xRetval[0] = drawinglayer::primitive2d::Primitive2DReference(new drawinglayer::primitive2d::BackgroundColorPrimitive2D(aRGBColor)); xRetval[0] = drawinglayer::primitive2d::Primitive2DReference(new drawinglayer::primitive2d::BackgroundColorPrimitive2D(aRGBColor, aInitColor.GetTransparency() / 255.0));
} }
return xRetval; return xRetval;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment