chart2/qa/extras/chart2export.cxx | 12 ++++++++++++ chart2/qa/extras/data/docx/barChartRotation.docx |binary oox/source/drawingml/chart/plotareaconverter.cxx | 2 +- 3 files changed, 13 insertions(+), 1 deletion(-)
New commits: commit c753c0b937ee4a86ac6a5f2617ffb59f65e7e713 Author: PriyankaGaikwad <priyanka.gaik...@synerzip.com> Date: Mon Feb 3 17:30:49 2014 +0530 fdo#74111 3D Rotation is wrong after Round trip for bar chart 3D Rotation is lost after Round trip for bar chart. XML Difference: Original: <c:rotX val="30"/> <c:rotY val="50"/> Round Trip: <c:rotX val="42"/> <c:rotY val="42"/> Implementation: The RightAngledAxes should set first then the RotationVertical and RotationHorizontal because the RightAngledAxes is needed while setting Rotation. Conflicts: chart2/qa/extras/chart2export.cxx Change-Id: I64f3b6e56f8515bf6c3d935c59dfaf1d440dba31 diff --git a/chart2/qa/extras/chart2export.cxx b/chart2/qa/extras/chart2export.cxx index 77140840..1cd52be 100644 --- a/chart2/qa/extras/chart2export.cxx +++ b/chart2/qa/extras/chart2export.cxx @@ -45,6 +45,7 @@ public: void testDisplayUnits(); void testFdo74115WallGradientFill(); void testFdo74115WallBitmapFill(); + void testBarChartRotation(); CPPUNIT_TEST_SUITE(Chart2ExportTest); CPPUNIT_TEST(test); @@ -62,6 +63,7 @@ public: CPPUNIT_TEST(testDisplayUnits); CPPUNIT_TEST(testFdo74115WallGradientFill); CPPUNIT_TEST(testFdo74115WallBitmapFill); + CPPUNIT_TEST(testBarChartRotation); CPPUNIT_TEST_SUITE_END(); protected: @@ -566,6 +568,16 @@ void Chart2ExportTest::testFdo74115WallBitmapFill() assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:plotArea/c:spPr/a:blipFill"); } +void Chart2ExportTest::testBarChartRotation() +{ + load ("/chart2/qa/extras/data/docx/", "barChartRotation.docx"); + xmlDocPtr pXmlDoc = parseExport("word/charts/chart","Office Open XML Text"); + CPPUNIT_ASSERT(pXmlDoc); + + assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:view3D/c:rotX", "val", "30"); + assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:view3D/c:rotY", "val", "50"); +} + CPPUNIT_TEST_SUITE_REGISTRATION(Chart2ExportTest); CPPUNIT_PLUGIN_IMPLEMENT(); diff --git a/chart2/qa/extras/data/docx/barChartRotation.docx b/chart2/qa/extras/data/docx/barChartRotation.docx new file mode 100644 index 0000000..bf4be47 Binary files /dev/null and b/chart2/qa/extras/data/docx/barChartRotation.docx differ diff --git a/oox/source/drawingml/chart/plotareaconverter.cxx b/oox/source/drawingml/chart/plotareaconverter.cxx index c069078..8fcb625 100644 --- a/oox/source/drawingml/chart/plotareaconverter.cxx +++ b/oox/source/drawingml/chart/plotareaconverter.cxx @@ -255,10 +255,10 @@ void View3DConverter::convertFromModel( const Reference< XDiagram >& rxDiagram, cssd::ProjectionMode eProjMode = bParallel ? cssd::ProjectionMode_PARALLEL : cssd::ProjectionMode_PERSPECTIVE; // set rotation properties + aPropSet.setProperty( PROP_RightAngledAxes, bRightAngled ); aPropSet.setProperty( PROP_RotationVertical, nRotationY ); aPropSet.setProperty( PROP_RotationHorizontal, nRotationX ); aPropSet.setProperty( PROP_Perspective, nPerspective ); - aPropSet.setProperty( PROP_RightAngledAxes, bRightAngled ); aPropSet.setProperty( PROP_D3DScenePerspective, eProjMode ); // set light settings _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits