Extended loplugin:ostr: sd
Change-Id: Iadfe05a173bacd236086728ac23de1e610f0bf27 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/159679 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
This commit is contained in:
@@ -88,7 +88,7 @@ CPPUNIT_TEST_FIXTURE(Test, testThemeExport)
|
||||
|
||||
// Verify that this color is not lost:
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("ppt/theme/theme1.xml");
|
||||
assertXPath(pXmlDoc, "//a:clrScheme/a:lt1/a:srgbClr", "val",
|
||||
assertXPath(pXmlDoc, "//a:clrScheme/a:lt1/a:srgbClr"_ostr, "val"_ostr,
|
||||
"222222"); // expected color 22-22-22
|
||||
|
||||
// Check the theme after loading again
|
||||
@@ -126,7 +126,7 @@ CPPUNIT_TEST_FIXTURE(Test, testLoopingFromAnimation)
|
||||
// - Actual : 0
|
||||
// - In <>, XPath '//p:cMediaNode/p:cTn' number of nodes is incorrect
|
||||
// i.e. the media node was lost on export, the video no longer looped.
|
||||
assertXPath(pXmlDoc, "//p:cMediaNode/p:cTn", "repeatCount", "indefinite");
|
||||
assertXPath(pXmlDoc, "//p:cMediaNode/p:cTn"_ostr, "repeatCount"_ostr, "indefinite");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -26,18 +26,19 @@ public:
|
||||
save("impress_html_Export");
|
||||
htmlDocUniquePtr htmlDoc = parseHtml(maTempFile);
|
||||
|
||||
assertXPath(htmlDoc, "/html", 1);
|
||||
assertXPath(htmlDoc, "/html/body", 1);
|
||||
assertXPath(htmlDoc, "/html/body/h1", 4);
|
||||
assertXPath(htmlDoc, "/html/body/table", 1);
|
||||
assertXPath(htmlDoc, "/html/body/table/tr", 5);
|
||||
assertXPath(htmlDoc, "/html/body/ul", 1);
|
||||
assertXPath(htmlDoc, "/html/body/ul/li", 2);
|
||||
assertXPath(htmlDoc, "/html"_ostr, 1);
|
||||
assertXPath(htmlDoc, "/html/body"_ostr, 1);
|
||||
assertXPath(htmlDoc, "/html/body/h1"_ostr, 4);
|
||||
assertXPath(htmlDoc, "/html/body/table"_ostr, 1);
|
||||
assertXPath(htmlDoc, "/html/body/table/tr"_ostr, 5);
|
||||
assertXPath(htmlDoc, "/html/body/ul"_ostr, 1);
|
||||
assertXPath(htmlDoc, "/html/body/ul/li"_ostr, 2);
|
||||
|
||||
assertXPath(htmlDoc, "/html/head/meta[1]", "content", "text/html; charset=utf-8");
|
||||
assertXPath(htmlDoc, "/html/head/meta[2]", "name", "generator");
|
||||
assertXPath(htmlDoc, "/html/head/meta[3]", "name", "created");
|
||||
assertXPath(htmlDoc, "/html/head/meta[3]", "content", "2014-04-09T17:05:41.987922038");
|
||||
assertXPath(htmlDoc, "/html/head/meta[1]"_ostr, "content"_ostr, "text/html; charset=utf-8");
|
||||
assertXPath(htmlDoc, "/html/head/meta[2]"_ostr, "name"_ostr, "generator");
|
||||
assertXPath(htmlDoc, "/html/head/meta[3]"_ostr, "name"_ostr, "created");
|
||||
assertXPath(htmlDoc, "/html/head/meta[3]"_ostr, "content"_ostr,
|
||||
"2014-04-09T17:05:41.987922038");
|
||||
}
|
||||
|
||||
void testTdf154989()
|
||||
@@ -46,21 +47,23 @@ public:
|
||||
save("XHTML Draw File");
|
||||
xmlDocUniquePtr pXmlDoc = parseXml(maTempFile);
|
||||
|
||||
assertXPath(pXmlDoc, "/xhtml:html", 1);
|
||||
assertXPath(pXmlDoc, "/xhtml:html"_ostr, 1);
|
||||
// 1 page
|
||||
assertXPath(pXmlDoc, "/xhtml:html/xhtml:body/xhtml:div", 1);
|
||||
assertXPath(pXmlDoc, "/xhtml:html/xhtml:body/xhtml:div"_ostr, 1);
|
||||
// 4 shapes
|
||||
assertXPath(pXmlDoc, "/xhtml:html/xhtml:body/xhtml:div[1]/xhtml:div", 4);
|
||||
assertXPath(pXmlDoc, "/xhtml:html/xhtml:body/xhtml:div[1]/xhtml:div"_ostr, 4);
|
||||
// 3 of them are text boxes
|
||||
assertXPath(pXmlDoc, "/xhtml:html/xhtml:body/xhtml:div[1]/xhtml:div/xhtml:div", 3);
|
||||
assertXPath(pXmlDoc, "/xhtml:html/xhtml:body/xhtml:div[1]/xhtml:div/xhtml:div"_ostr, 3);
|
||||
// not sure if the order of these is stable?
|
||||
assertXPathContent(pXmlDoc,
|
||||
"/xhtml:html/xhtml:body/xhtml:div[1]/xhtml:div[2]/xhtml:div/xhtml:p",
|
||||
"before");
|
||||
assertXPathContent(
|
||||
pXmlDoc, "/xhtml:html/xhtml:body/xhtml:div[1]/xhtml:div[3]/xhtml:div/xhtml:p", "above");
|
||||
pXmlDoc, "/xhtml:html/xhtml:body/xhtml:div[1]/xhtml:div[2]/xhtml:div/xhtml:p"_ostr,
|
||||
"before");
|
||||
assertXPathContent(
|
||||
pXmlDoc, "/xhtml:html/xhtml:body/xhtml:div[1]/xhtml:div[4]/xhtml:div/xhtml:p", "below");
|
||||
pXmlDoc, "/xhtml:html/xhtml:body/xhtml:div[1]/xhtml:div[3]/xhtml:div/xhtml:p"_ostr,
|
||||
"above");
|
||||
assertXPathContent(
|
||||
pXmlDoc, "/xhtml:html/xhtml:body/xhtml:div[1]/xhtml:div[4]/xhtml:div/xhtml:p"_ostr,
|
||||
"below");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_SUITE(SdHTMLFilterTest);
|
||||
|
||||
@@ -85,16 +85,16 @@ public:
|
||||
svgDoc->name = reinterpret_cast<char *>(xmlStrdup(reinterpret_cast<xmlChar const *>(OUStringToOString(maTempFile.GetURL(), RTL_TEXTENCODING_UTF8).getStr())));
|
||||
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG ), 1);
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2] ), "class", "SlideGroup");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G/SVG_G/SVG_G ), "class", "Slide");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G/SVG_G/SVG_G/SVG_G/SVG_G[1] ), "class", "TitleText");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G/SVG_G/SVG_G/SVG_G/SVG_G[1]/SVG_G/SVG_TEXT ), "class", "SVGTextShape");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G/SVG_G/SVG_G/SVG_G/SVG_G[1]/SVG_G/SVG_TEXT/SVG_TSPAN/SVG_TSPAN ), "class", "TextPosition");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G/SVG_G/SVG_G/SVG_G/SVG_G[1]/SVG_G/SVG_TEXT/SVG_TSPAN/SVG_TSPAN/SVG_TSPAN[1] ), "text-decoration", "underline");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2] ), "class"_ostr, "SlideGroup");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G/SVG_G/SVG_G ), "class"_ostr, "Slide");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G/SVG_G/SVG_G/SVG_G/SVG_G[1] ), "class"_ostr, "TitleText");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G/SVG_G/SVG_G/SVG_G/SVG_G[1]/SVG_G/SVG_TEXT ), "class"_ostr, "SVGTextShape");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G/SVG_G/SVG_G/SVG_G/SVG_G[1]/SVG_G/SVG_TEXT/SVG_TSPAN/SVG_TSPAN ), "class"_ostr, "TextPosition");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G/SVG_G/SVG_G/SVG_G/SVG_G[1]/SVG_G/SVG_TEXT/SVG_TSPAN/SVG_TSPAN/SVG_TSPAN[1] ), "text-decoration"_ostr, "underline");
|
||||
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G/SVG_G/SVG_G/SVG_G/SVG_G[2]/SVG_G/SVG_TEXT ), "class", "SVGTextShape");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G/SVG_G/SVG_G/SVG_G/SVG_G[2]/SVG_G/SVG_TEXT/SVG_TSPAN/SVG_TSPAN ), "class", "TextPosition");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G/SVG_G/SVG_G/SVG_G/SVG_G[2]/SVG_G/SVG_TEXT/SVG_TSPAN/SVG_TSPAN/SVG_TSPAN ), "text-decoration", "line-through");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G/SVG_G/SVG_G/SVG_G/SVG_G[2]/SVG_G/SVG_TEXT ), "class"_ostr, "SVGTextShape");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G/SVG_G/SVG_G/SVG_G/SVG_G[2]/SVG_G/SVG_TEXT/SVG_TSPAN/SVG_TSPAN ), "class"_ostr, "TextPosition");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G/SVG_G/SVG_G/SVG_G/SVG_G[2]/SVG_G/SVG_TEXT/SVG_TSPAN/SVG_TSPAN/SVG_TSPAN ), "text-decoration"_ostr, "line-through");
|
||||
}
|
||||
|
||||
void testSVGExportJavascriptURL()
|
||||
@@ -120,7 +120,7 @@ public:
|
||||
xmlDocUniquePtr svgDoc = parseXml(maTempFile);
|
||||
CPPUNIT_ASSERT(svgDoc);
|
||||
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G/SVG_G/SVG_G/SVG_G/SVG_DEFS ), "class", "SlideBackground");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G/SVG_G/SVG_G/SVG_G/SVG_DEFS ), "class"_ostr, "SlideBackground");
|
||||
}
|
||||
|
||||
void testSVGExportTextFieldsInMasterPage()
|
||||
@@ -131,20 +131,20 @@ public:
|
||||
xmlDocUniquePtr svgDoc = parseXml(maTempFile);
|
||||
CPPUNIT_ASSERT(svgDoc);
|
||||
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_G[2] ), "class", "Master_Slide");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_G[2]/SVG_G[2] ), "class", "BackgroundObjects");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_G[2] ), "class"_ostr, "Master_Slide");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_G[2]/SVG_G[2] ), "class"_ostr, "BackgroundObjects");
|
||||
// Current Date Field
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_G[2]/SVG_G[2]/SVG_G[4] ), "class", "TextShape");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_G[2]/SVG_G[2]/SVG_G[4]/SVG_G/SVG_TEXT/SVG_TSPAN/SVG_TSPAN/SVG_TSPAN ), "class", "PlaceholderText Date");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_G[2]/SVG_G[2]/SVG_G[4] ), "class"_ostr, "TextShape");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_G[2]/SVG_G[2]/SVG_G[4]/SVG_G/SVG_TEXT/SVG_TSPAN/SVG_TSPAN/SVG_TSPAN ), "class"_ostr, "PlaceholderText Date");
|
||||
// Current Time Field
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_G[2]/SVG_G[2]/SVG_G[5] ), "class", "TextShape");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_G[2]/SVG_G[2]/SVG_G[5]/SVG_G/SVG_TEXT/SVG_TSPAN/SVG_TSPAN/SVG_TSPAN ), "class", "PlaceholderText Time");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_G[2]/SVG_G[2]/SVG_G[5] ), "class"_ostr, "TextShape");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_G[2]/SVG_G[2]/SVG_G[5]/SVG_G/SVG_TEXT/SVG_TSPAN/SVG_TSPAN/SVG_TSPAN ), "class"_ostr, "PlaceholderText Time");
|
||||
// Slide Name Field
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_G[2]/SVG_G[2]/SVG_G[6] ), "class", "TextShape");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_G[2]/SVG_G[2]/SVG_G[6]/SVG_G/SVG_TEXT/SVG_TSPAN/SVG_TSPAN/SVG_TSPAN ), "class", "PlaceholderText PageName");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_G[2]/SVG_G[2]/SVG_G[6] ), "class"_ostr, "TextShape");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_G[2]/SVG_G[2]/SVG_G[6]/SVG_G/SVG_TEXT/SVG_TSPAN/SVG_TSPAN/SVG_TSPAN ), "class"_ostr, "PlaceholderText PageName");
|
||||
// Slide Number Field
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_G[2]/SVG_G[2]/SVG_G[7] ), "class", "TextShape");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_G[2]/SVG_G[2]/SVG_G[7]/SVG_G/SVG_TEXT/SVG_TSPAN/SVG_TSPAN/SVG_TSPAN ), "class", "PlaceholderText PageNumber");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_G[2]/SVG_G[2]/SVG_G[7] ), "class"_ostr, "TextShape");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_G[2]/SVG_G[2]/SVG_G[7]/SVG_G/SVG_TEXT/SVG_TSPAN/SVG_TSPAN/SVG_TSPAN ), "class"_ostr, "PlaceholderText PageNumber");
|
||||
}
|
||||
|
||||
void testSVGExportEmbeddedVideo()
|
||||
@@ -156,25 +156,25 @@ public:
|
||||
CPPUNIT_ASSERT(svgDoc);
|
||||
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG ), 1);
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2] ), "class", "SlideGroup");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G[1] ), "visibility", "hidden");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G[1]/SVG_G[1] ), "id", "container-id1");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G[1]/SVG_G[1]/SVG_G[1] ), "class", "Slide");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G[1]/SVG_G[1]/SVG_G[1]/SVG_G[1] ), "class", "Page");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G[1]/SVG_G[1]/SVG_G[1]/SVG_G[1]/SVG_G[1] ), "class", "TitleText");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2] ), "class"_ostr, "SlideGroup");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G[1] ), "visibility"_ostr, "hidden");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G[1]/SVG_G[1] ), "id"_ostr, "container-id1");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G[1]/SVG_G[1]/SVG_G[1] ), "class"_ostr, "Slide");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G[1]/SVG_G[1]/SVG_G[1]/SVG_G[1] ), "class"_ostr, "Page");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G[1]/SVG_G[1]/SVG_G[1]/SVG_G[1]/SVG_G[1] ), "class"_ostr, "TitleText");
|
||||
|
||||
// First one has no valid video, so we just generate the stock thumbnail as an image.
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G[1]/SVG_G[1]/SVG_G[1]/SVG_G[1]/SVG_G[2] ), "class", "com.sun.star.presentation.MediaShape");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G[1]/SVG_G[1]/SVG_G[1]/SVG_G[1]/SVG_G[2] ), "class"_ostr, "com.sun.star.presentation.MediaShape");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G[1]/SVG_G[1]/SVG_G[1]/SVG_G[1]/SVG_G[2]/SVG_G[1]/SVG_IMAGE ), 1);
|
||||
|
||||
// The second one is a valid video, with the thumbnail embedded.
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G[1]/SVG_G[1]/SVG_G[1]/SVG_G[1]/SVG_G[5] ), "class", "com.sun.star.drawing.MediaShape");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G[1]/SVG_G[1]/SVG_G[1]/SVG_G[1]/SVG_G[5] ), "class"_ostr, "com.sun.star.drawing.MediaShape");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G[1]/SVG_G[1]/SVG_G[1]/SVG_G[1]/SVG_G[5]/SVG_G[1] ), 1);
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G[1]/SVG_G[1]/SVG_G[1]/SVG_G[1]/SVG_G[5]/SVG_G[1]/SVG_FOREIGNOBJECT ), 1);
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G[1]/SVG_G[1]/SVG_G[1]/SVG_G[1]/SVG_G[5]/SVG_G[1]/SVG_FOREIGNOBJECT/SVG_BODY ), 1);
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G[1]/SVG_G[1]/SVG_G[1]/SVG_G[1]/SVG_G[5]/SVG_G[1]/SVG_FOREIGNOBJECT/SVG_BODY/SVG_VIDEO ), "preload", "auto");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G[1]/SVG_G[1]/SVG_G[1]/SVG_G[1]/SVG_G[5]/SVG_G[1]/SVG_FOREIGNOBJECT/SVG_BODY/SVG_VIDEO ), "preload"_ostr, "auto");
|
||||
|
||||
const OUString poster = getXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G[1]/SVG_G[1]/SVG_G[1]/SVG_G[1]/SVG_G[5]/SVG_G[1]/SVG_FOREIGNOBJECT/SVG_BODY/SVG_VIDEO), "poster");
|
||||
const OUString poster = getXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G[1]/SVG_G[1]/SVG_G[1]/SVG_G[1]/SVG_G[5]/SVG_G[1]/SVG_FOREIGNOBJECT/SVG_BODY/SVG_VIDEO), "poster"_ostr);
|
||||
CPPUNIT_ASSERT_MESSAGE("The video poster is invalid", poster.startsWith("data:image/png;base64,"));
|
||||
}
|
||||
|
||||
@@ -186,19 +186,19 @@ public:
|
||||
xmlDocUniquePtr svgDoc = parseXml(maTempFile);
|
||||
CPPUNIT_ASSERT(svgDoc);
|
||||
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9] ), "class", "BackgroundBitmaps");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9] ), "class"_ostr, "BackgroundBitmaps");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_IMAGE ), 1);
|
||||
|
||||
OUString sImageId = getXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_IMAGE ), "id");
|
||||
OUString sImageId = getXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_IMAGE ), "id"_ostr);
|
||||
CPPUNIT_ASSERT_MESSAGE(OString("The exported bitmap has not a valid id: " + sImageId.toUtf8()).getStr(), isValidBitmapId(sImageId));
|
||||
|
||||
BitmapChecksum nChecksum = getBitmapChecksumFromId(sImageId);
|
||||
CPPUNIT_ASSERT_MESSAGE(OString("The exported bitmap has not a valid checksum: " + sImageId.toUtf8()).getStr(), nChecksum != 0);
|
||||
|
||||
// single image case
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G[1]/SVG_G/SVG_G/SVG_G/SVG_DEFS ), "class", "SlideBackground");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G[1]/SVG_G/SVG_G/SVG_G/SVG_DEFS ), "class"_ostr, "SlideBackground");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G[1]/SVG_G/SVG_G/SVG_G/SVG_DEFS/SVG_G/SVG_G/SVG_USE ), 1);
|
||||
OUString sRef = getXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G[1]/SVG_G/SVG_G/SVG_G/SVG_DEFS/SVG_G/SVG_G/SVG_USE ), "href");
|
||||
OUString sRef = getXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G[1]/SVG_G/SVG_G/SVG_G/SVG_DEFS/SVG_G/SVG_G/SVG_USE ), "href"_ostr);
|
||||
CPPUNIT_ASSERT_MESSAGE("The <use> element has not a valid href attribute: starting '#' not present.", sRef.startsWith("#"));
|
||||
sRef = sRef.copy(1);
|
||||
CPPUNIT_ASSERT_MESSAGE(OString("The <use> element does not point to a valid bitmap id: " + sRef.toUtf8()).getStr(), isValidBitmapId(sRef));
|
||||
@@ -216,46 +216,46 @@ public:
|
||||
CPPUNIT_ASSERT(svgDoc);
|
||||
|
||||
// check the bitmap
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9] ), "class", "BackgroundBitmaps");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9] ), "class"_ostr, "BackgroundBitmaps");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_IMAGE ), 1);
|
||||
|
||||
// check the pattern and background rectangle
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[10] ), "class", "BackgroundPatterns");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[10] ), "class"_ostr, "BackgroundPatterns");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[10]/SVG_PATTERN ), 1);
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[10]/SVG_PATTERN/SVG_USE ), 1);
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[10]/SVG_G/SVG_RECT ), 1);
|
||||
|
||||
|
||||
// check that <pattern><use> is pointing to the correct <image>
|
||||
OUString sImageId = getXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_IMAGE ), "id");
|
||||
OUString sImageId = getXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_IMAGE ), "id"_ostr);
|
||||
CPPUNIT_ASSERT_MESSAGE(OString("The exported bitmap has not a valid id: " + sImageId.toUtf8()).getStr(), isValidBitmapId(sImageId));
|
||||
|
||||
BitmapChecksum nChecksum = getBitmapChecksumFromId(sImageId);
|
||||
CPPUNIT_ASSERT_MESSAGE(OString("The exported bitmap has not a valid checksum: " + sImageId.toUtf8()).getStr(), nChecksum != 0);
|
||||
|
||||
OUString sRef = getXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[10]/SVG_PATTERN/SVG_USE ), "href");
|
||||
OUString sRef = getXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[10]/SVG_PATTERN/SVG_USE ), "href"_ostr);
|
||||
CPPUNIT_ASSERT_MESSAGE("The <pattern><use> element has not a valid href attribute: starting '#' not present.", sRef.startsWith("#"));
|
||||
sRef = sRef.copy(1);
|
||||
CPPUNIT_ASSERT_EQUAL_MESSAGE("The href attribute for <pattern><use> does not match the <image> id attribute: ", sImageId, sRef);
|
||||
|
||||
OUString sPatternId = getXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[10]/SVG_PATTERN ), "id");
|
||||
OUString sPatternId = getXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[10]/SVG_PATTERN ), "id"_ostr);
|
||||
CPPUNIT_ASSERT_MESSAGE(OString("The exported pattern has not a valid id: " + sPatternId.toUtf8()).getStr(), isValidBackgroundPatternId(sPatternId));
|
||||
|
||||
OUString sFillUrl = getXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[10]/SVG_G/SVG_RECT ), "fill");
|
||||
OUString sFillUrl = getXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[10]/SVG_G/SVG_RECT ), "fill"_ostr);
|
||||
bool bIsUrlFormat = sFillUrl.startsWith("url(#") && sFillUrl.endsWith(")");
|
||||
CPPUNIT_ASSERT_MESSAGE("The fill attribute for the <rectangle> element has not a url format .", bIsUrlFormat);
|
||||
// remove "url(#" and ")"
|
||||
sFillUrl = sFillUrl.copy(5, sFillUrl.getLength() - 6);
|
||||
CPPUNIT_ASSERT_EQUAL_MESSAGE("The fill url for <rectangle> does not match the <pattern> id attribute: ", sPatternId, sFillUrl);
|
||||
|
||||
OUString sBackgroundId = getXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[10]/SVG_G ), "id");
|
||||
OUString sBackgroundId = getXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[10]/SVG_G ), "id"_ostr);
|
||||
CPPUNIT_ASSERT_MESSAGE(OString("The exported tiled background has not a valid id: " + sBackgroundId.toUtf8()).getStr(), isValidTiledBackgroundId(sBackgroundId));
|
||||
|
||||
// check <use> element that point to the tiled background
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G[1]/SVG_G/SVG_G/SVG_G/SVG_DEFS ), "class", "SlideBackground");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G[1]/SVG_G/SVG_G/SVG_G/SVG_DEFS ), "class"_ostr, "SlideBackground");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G[1]/SVG_G/SVG_G/SVG_G/SVG_DEFS/SVG_G/SVG_USE ), 1);
|
||||
|
||||
sRef = getXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G[1]/SVG_G/SVG_G/SVG_G/SVG_DEFS/SVG_G/SVG_USE ), "href");
|
||||
sRef = getXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_G[2]/SVG_G[1]/SVG_G/SVG_G/SVG_G/SVG_DEFS/SVG_G/SVG_USE ), "href"_ostr);
|
||||
CPPUNIT_ASSERT_MESSAGE("The <use> element has not a valid href attribute: starting '#' not present.", sRef.startsWith("#"));
|
||||
sRef = sRef.copy(1);
|
||||
CPPUNIT_ASSERT_EQUAL_MESSAGE("The href attribute for <use> does not match the tiled background id attribute: ", sBackgroundId, sRef);
|
||||
@@ -280,15 +280,15 @@ public:
|
||||
xmlDocUniquePtr svgDoc = parseXml(maTempFile);
|
||||
CPPUNIT_ASSERT(svgDoc);
|
||||
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_G[2] ), "class", "Master_Slide");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_G[2]/SVG_G[2] ), "class", "BackgroundObjects");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_G[2] ), "class"_ostr, "Master_Slide");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_G[2]/SVG_G[2] ), "class"_ostr, "BackgroundObjects");
|
||||
|
||||
// Slide Name Field
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_G[2]/SVG_G[2]/SVG_G[6] ), "class", "TextShape");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_G[2]/SVG_G[2]/SVG_G[6]/SVG_G/SVG_TEXT/SVG_TSPAN/SVG_TSPAN/SVG_TSPAN ), "class", "PlaceholderText PageName");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_G[2]/SVG_G[2]/SVG_G[6] ), "class"_ostr, "TextShape");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_G[2]/SVG_G[2]/SVG_G[6]/SVG_G/SVG_TEXT/SVG_TSPAN/SVG_TSPAN/SVG_TSPAN ), "class"_ostr, "PlaceholderText PageName");
|
||||
// Slide Number Field
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_G[2]/SVG_G[2]/SVG_G[7] ), "class", "TextShape");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_G[2]/SVG_G[2]/SVG_G[7]/SVG_G/SVG_TEXT/SVG_TSPAN/SVG_TSPAN/SVG_TSPAN ), "class", "PlaceholderText PageNumber");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_G[2]/SVG_G[2]/SVG_G[7] ), "class"_ostr, "TextShape");
|
||||
assertXPath(svgDoc, SAL_STRINGIFY( /SVG_SVG/SVG_DEFS[9]/SVG_G[2]/SVG_G[2]/SVG_G[7]/SVG_G/SVG_TEXT/SVG_TSPAN/SVG_TSPAN/SVG_TSPAN ), "class"_ostr, "PlaceholderText PageNumber");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_SUITE(SdSVGFilterTest);
|
||||
|
||||
@@ -261,107 +261,117 @@ void ShapeImportExportTest::testTextDistancesOOXML_Export()
|
||||
CPPUNIT_ASSERT(pXmlDoc);
|
||||
|
||||
//Check shape Top/Bottom - 0cm, 4cm
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[1]/p:nvSpPr/p:cNvPr", "name", "Text_TB_0_4");
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[1]/p:txBody/a:bodyPr",
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[1]/p:nvSpPr/p:cNvPr"_ostr, "name"_ostr,
|
||||
"Text_TB_0_4");
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[1]/p:txBody/a:bodyPr"_ostr,
|
||||
{ { "tIns", "-360000" }, { "bIns", "1079640" } });
|
||||
|
||||
//Check shape Top/Bottom - 4cm, 0cm
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:nvSpPr/p:cNvPr", "name", "Text_TB_4_0");
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:bodyPr",
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:nvSpPr/p:cNvPr"_ostr, "name"_ostr,
|
||||
"Text_TB_4_0");
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:bodyPr"_ostr,
|
||||
{ { "tIns", "1079640" }, { "bIns", "-360000" } });
|
||||
|
||||
//Check shape Top/Bottom - 0cm, 3cm
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[3]/p:nvSpPr/p:cNvPr", "name", "Text_TB_0_3");
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[3]/p:txBody/a:bodyPr",
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[3]/p:nvSpPr/p:cNvPr"_ostr, "name"_ostr,
|
||||
"Text_TB_0_3");
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[3]/p:txBody/a:bodyPr"_ostr,
|
||||
{ { "tIns", "-180000" }, { "bIns", "899640" } });
|
||||
|
||||
//Check shape Top/Bottom - 2cm, 1cm
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[4]/p:nvSpPr/p:cNvPr", "name", "Text_TB_2_1");
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[4]/p:txBody/a:bodyPr",
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[4]/p:nvSpPr/p:cNvPr"_ostr, "name"_ostr,
|
||||
"Text_TB_2_1");
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[4]/p:txBody/a:bodyPr"_ostr,
|
||||
{ { "tIns", "540000" }, { "bIns", "180000" } });
|
||||
|
||||
//Check shape Top/Bottom - 0cm, 2.5cm
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[5]/p:nvSpPr/p:cNvPr", "name",
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[5]/p:nvSpPr/p:cNvPr"_ostr, "name"_ostr,
|
||||
"Text_TB_0_2.5");
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[5]/p:txBody/a:bodyPr",
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[5]/p:txBody/a:bodyPr"_ostr,
|
||||
{ { "tIns", "-90000" }, { "bIns", "809640" } });
|
||||
|
||||
//Check shape Top/Bottom - 0cm, 2cm
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[6]/p:nvSpPr/p:cNvPr", "name", "Text_TB_0_2");
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[6]/p:txBody/a:bodyPr",
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[6]/p:nvSpPr/p:cNvPr"_ostr, "name"_ostr,
|
||||
"Text_TB_0_2");
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[6]/p:txBody/a:bodyPr"_ostr,
|
||||
{ { "tIns", "0" }, { "bIns", "720000" } });
|
||||
|
||||
//Check shape Top/Bottom - 0cm, 1.5cm
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[7]/p:nvSpPr/p:cNvPr", "name",
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[7]/p:nvSpPr/p:cNvPr"_ostr, "name"_ostr,
|
||||
"Text_TB_0_1.5");
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[7]/p:txBody/a:bodyPr",
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[7]/p:txBody/a:bodyPr"_ostr,
|
||||
{ { "tIns", "0" }, { "bIns", "540000" } });
|
||||
|
||||
//Check shape Top/Bottom - 3cm, 0cm
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[8]/p:nvSpPr/p:cNvPr", "name", "Text_TB_3_0");
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[8]/p:txBody/a:bodyPr",
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[8]/p:nvSpPr/p:cNvPr"_ostr, "name"_ostr,
|
||||
"Text_TB_3_0");
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[8]/p:txBody/a:bodyPr"_ostr,
|
||||
{ { "tIns", "899640" }, { "bIns", "-180000" } });
|
||||
|
||||
//Check shape Top/Bottom - 2.5cm, 0cm
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[9]/p:nvSpPr/p:cNvPr", "name",
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[9]/p:nvSpPr/p:cNvPr"_ostr, "name"_ostr,
|
||||
"Text_TB_2.5_0");
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[9]/p:txBody/a:bodyPr",
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[9]/p:txBody/a:bodyPr"_ostr,
|
||||
{ { "tIns", "809640" }, { "bIns", "-90000" } });
|
||||
|
||||
//Check shape Top/Bottom - 2cm, 0cm
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[10]/p:nvSpPr/p:cNvPr", "name", "Text_TB_2_0");
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[10]/p:txBody/a:bodyPr",
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[10]/p:nvSpPr/p:cNvPr"_ostr, "name"_ostr,
|
||||
"Text_TB_2_0");
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[10]/p:txBody/a:bodyPr"_ostr,
|
||||
{ { "tIns", "720000" }, { "bIns", "0" } });
|
||||
|
||||
//Check shape Top/Bottom - 1.5cm, 0cm
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[11]/p:nvSpPr/p:cNvPr", "name",
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[11]/p:nvSpPr/p:cNvPr"_ostr, "name"_ostr,
|
||||
"Text_TB_1.5_0");
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[11]/p:txBody/a:bodyPr",
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[11]/p:txBody/a:bodyPr"_ostr,
|
||||
{ { "tIns", "540000" }, { "bIns", "0" } });
|
||||
|
||||
//Check shape Top/Bottom - 1cm, 2cm
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[12]/p:nvSpPr/p:cNvPr", "name", "Text_TB_1_2");
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[12]/p:txBody/a:bodyPr",
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[12]/p:nvSpPr/p:cNvPr"_ostr, "name"_ostr,
|
||||
"Text_TB_1_2");
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[12]/p:txBody/a:bodyPr"_ostr,
|
||||
{ { "tIns", "180000" }, { "bIns", "540000" } });
|
||||
|
||||
//Check shape Top/Bottom - 2cm, 1.5cm
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[13]/p:nvSpPr/p:cNvPr", "name",
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[13]/p:nvSpPr/p:cNvPr"_ostr, "name"_ostr,
|
||||
"Text_TB_2_1.5");
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[13]/p:txBody/a:bodyPr",
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[13]/p:txBody/a:bodyPr"_ostr,
|
||||
{ { "tIns", "450000" }, { "bIns", "270000" } });
|
||||
|
||||
//Check shape Top/Bottom - 1.5cm, 2cm
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[14]/p:nvSpPr/p:cNvPr", "name",
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[14]/p:nvSpPr/p:cNvPr"_ostr, "name"_ostr,
|
||||
"Text_TB_1.5_2");
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[14]/p:txBody/a:bodyPr",
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[14]/p:txBody/a:bodyPr"_ostr,
|
||||
{ { "tIns", "270000" }, { "bIns", "450000" } });
|
||||
|
||||
//Check shape Top/Bottom - 2cm, 1.75cm
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[15]/p:nvSpPr/p:cNvPr", "name",
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[15]/p:nvSpPr/p:cNvPr"_ostr, "name"_ostr,
|
||||
"Text_TB_2_1.75");
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[15]/p:txBody/a:bodyPr",
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[15]/p:txBody/a:bodyPr"_ostr,
|
||||
{ { "tIns", "405000" }, { "bIns", "315000" } });
|
||||
|
||||
//Check shape Top/Bottom - 1.75cm, 2cm
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[16]/p:nvSpPr/p:cNvPr", "name",
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[16]/p:nvSpPr/p:cNvPr"_ostr, "name"_ostr,
|
||||
"Text_TB_1.75_2");
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[16]/p:txBody/a:bodyPr",
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[16]/p:txBody/a:bodyPr"_ostr,
|
||||
{ { "tIns", "315000" }, { "bIns", "405000" } });
|
||||
|
||||
//Check shape Top/Bottom - 2cm, 2cm
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[17]/p:nvSpPr/p:cNvPr", "name", "Text_TB_2_2");
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[17]/p:txBody/a:bodyPr",
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[17]/p:nvSpPr/p:cNvPr"_ostr, "name"_ostr,
|
||||
"Text_TB_2_2");
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[17]/p:txBody/a:bodyPr"_ostr,
|
||||
{ { "tIns", "360000" }, { "bIns", "360000" } });
|
||||
|
||||
//Check shape Top/Bottom - 1cm, 1cm
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[18]/p:nvSpPr/p:cNvPr", "name", "Text_TB_1_1");
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[18]/p:txBody/a:bodyPr",
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[18]/p:nvSpPr/p:cNvPr"_ostr, "name"_ostr,
|
||||
"Text_TB_1_1");
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[18]/p:txBody/a:bodyPr"_ostr,
|
||||
{ { "tIns", "360000" }, { "bIns", "360000" } });
|
||||
|
||||
//Check shape Top/Bottom - 0.5cm, 0.5cm
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[19]/p:nvSpPr/p:cNvPr", "name",
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[19]/p:nvSpPr/p:cNvPr"_ostr, "name"_ostr,
|
||||
"Text_TB_0.5_0.5");
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[19]/p:txBody/a:bodyPr",
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[19]/p:txBody/a:bodyPr"_ostr,
|
||||
{ { "tIns", "180000" }, { "bIns", "180000" } });
|
||||
}
|
||||
|
||||
@@ -375,7 +385,7 @@ void ShapeImportExportTest::testTextDistancesODP_OOXML_Export()
|
||||
// The text ends 5cm below the top edge of the shape.
|
||||
// Without the fix we exported tIns="3600000" and bIns="5400000".
|
||||
// The text had ended about 3.3cm below the top edge in PowerPoint.
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[1]/p:txBody/a:bodyPr",
|
||||
assertXPathAttrs(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[1]/p:txBody/a:bodyPr"_ostr,
|
||||
{ { "tIns", "720000" }, { "bIns", "2520000" } });
|
||||
}
|
||||
|
||||
|
||||
+22
-22
@@ -209,28 +209,28 @@ const SfxItemSet& SdDialogsTest::getEmptyFillStyleSfxItemSet()
|
||||
void SdDialogsTest::registerKnownDialogsByID(mapType& rKnownDialogs)
|
||||
{
|
||||
// fill map of known dialogs
|
||||
rKnownDialogs["modules/sdraw/ui/breakdialog.ui"] = 0;
|
||||
rKnownDialogs["modules/sdraw/ui/copydlg.ui"] = 1;
|
||||
rKnownDialogs["modules/simpress/ui/customslideshows.ui"] = 2;
|
||||
rKnownDialogs["modules/sdraw/ui/drawchardialog.ui"] = 3;
|
||||
rKnownDialogs["modules/sdraw/ui/drawpagedialog.ui"] = 4;
|
||||
rKnownDialogs["modules/simpress/ui/dlgfield.ui"] = 5;
|
||||
rKnownDialogs["modules/sdraw/ui/dlgsnap.ui"] = 6;
|
||||
rKnownDialogs["modules/sdraw/ui/insertlayer.ui"] = 7;
|
||||
rKnownDialogs["modules/sdraw/ui/insertslidesdialog.ui"] = 8;
|
||||
rKnownDialogs["modules/sdraw/ui/crossfadedialog.ui"] = 9;
|
||||
rKnownDialogs["modules/sdraw/ui/bulletsandnumbering.ui"] = 10;
|
||||
rKnownDialogs["modules/sdraw/ui/drawparadialog.ui"] = 11;
|
||||
rKnownDialogs["modules/simpress/ui/presentationdialog.ui"] = 12;
|
||||
rKnownDialogs["modules/simpress/ui/remotedialog.ui"] = 13;
|
||||
rKnownDialogs["modules/sdraw/ui/drawprtldialog.ui"] = 14;
|
||||
rKnownDialogs["modules/simpress/ui/slidedesigndialog.ui"] = 15;
|
||||
rKnownDialogs["modules/simpress/ui/templatedialog.ui"] = 16;
|
||||
rKnownDialogs["modules/simpress/ui/interactiondialog.ui"] = 17;
|
||||
rKnownDialogs["modules/sdraw/ui/vectorize.ui"] = 18;
|
||||
rKnownDialogs["modules/simpress/ui/photoalbum.ui"] = 19;
|
||||
rKnownDialogs["modules/simpress/ui/masterlayoutdlg.ui"] = 20;
|
||||
rKnownDialogs["modules/simpress/ui/headerfooterdialog.ui"] = 21;
|
||||
rKnownDialogs["modules/sdraw/ui/breakdialog.ui"_ostr] = 0;
|
||||
rKnownDialogs["modules/sdraw/ui/copydlg.ui"_ostr] = 1;
|
||||
rKnownDialogs["modules/simpress/ui/customslideshows.ui"_ostr] = 2;
|
||||
rKnownDialogs["modules/sdraw/ui/drawchardialog.ui"_ostr] = 3;
|
||||
rKnownDialogs["modules/sdraw/ui/drawpagedialog.ui"_ostr] = 4;
|
||||
rKnownDialogs["modules/simpress/ui/dlgfield.ui"_ostr] = 5;
|
||||
rKnownDialogs["modules/sdraw/ui/dlgsnap.ui"_ostr] = 6;
|
||||
rKnownDialogs["modules/sdraw/ui/insertlayer.ui"_ostr] = 7;
|
||||
rKnownDialogs["modules/sdraw/ui/insertslidesdialog.ui"_ostr] = 8;
|
||||
rKnownDialogs["modules/sdraw/ui/crossfadedialog.ui"_ostr] = 9;
|
||||
rKnownDialogs["modules/sdraw/ui/bulletsandnumbering.ui"_ostr] = 10;
|
||||
rKnownDialogs["modules/sdraw/ui/drawparadialog.ui"_ostr] = 11;
|
||||
rKnownDialogs["modules/simpress/ui/presentationdialog.ui"_ostr] = 12;
|
||||
rKnownDialogs["modules/simpress/ui/remotedialog.ui"_ostr] = 13;
|
||||
rKnownDialogs["modules/sdraw/ui/drawprtldialog.ui"_ostr] = 14;
|
||||
rKnownDialogs["modules/simpress/ui/slidedesigndialog.ui"_ostr] = 15;
|
||||
rKnownDialogs["modules/simpress/ui/templatedialog.ui"_ostr] = 16;
|
||||
rKnownDialogs["modules/simpress/ui/interactiondialog.ui"_ostr] = 17;
|
||||
rKnownDialogs["modules/sdraw/ui/vectorize.ui"_ostr] = 18;
|
||||
rKnownDialogs["modules/simpress/ui/photoalbum.ui"_ostr] = 19;
|
||||
rKnownDialogs["modules/simpress/ui/masterlayoutdlg.ui"_ostr] = 20;
|
||||
rKnownDialogs["modules/simpress/ui/headerfooterdialog.ui"_ostr] = 21;
|
||||
}
|
||||
|
||||
VclPtr<VclAbstractDialog> SdDialogsTest::createDialogByID(sal_uInt32 nID)
|
||||
|
||||
+204
-183
@@ -80,7 +80,8 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf152335)
|
||||
|
||||
xmlDocUniquePtr pXmlDocTheme = parseExport("ppt/theme/theme1.xml");
|
||||
assertXPathChildren(
|
||||
pXmlDocTheme, "/a:theme/a:themeElements/a:fmtScheme/a:effectStyleLst/a:effectStyle[3]", 1);
|
||||
pXmlDocTheme, "/a:theme/a:themeElements/a:fmtScheme/a:effectStyleLst/a:effectStyle[3]"_ostr,
|
||||
1);
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf149803)
|
||||
@@ -89,7 +90,7 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf149803)
|
||||
save("Impress Office Open XML");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp", "useBgFill", "1");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp"_ostr, "useBgFill"_ostr, "1");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf149311)
|
||||
@@ -99,7 +100,7 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf149311)
|
||||
|
||||
xmlDocUniquePtr pRelsDoc = parseExport("ppt/slides/_rels/slide1.xml.rels");
|
||||
|
||||
assertXPath(pRelsDoc, "/rels:Relationships/rels:Relationship[@Id='rId1']", "Target",
|
||||
assertXPath(pRelsDoc, "/rels:Relationships/rels:Relationship[@Id='rId1']"_ostr, "Target"_ostr,
|
||||
"slide2.xml");
|
||||
}
|
||||
|
||||
@@ -109,14 +110,14 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf149128)
|
||||
save("Impress Office Open XML");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp/p:nvCxnSpPr/p:cNvCxnSpPr/a:stCxn", "id",
|
||||
"42");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp/p:nvCxnSpPr/p:cNvCxnSpPr/a:stCxn", "idx",
|
||||
"0");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp/p:nvCxnSpPr/p:cNvCxnSpPr/a:endCxn", "id",
|
||||
"43");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp/p:nvCxnSpPr/p:cNvCxnSpPr/a:endCxn", "idx",
|
||||
"2");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp/p:nvCxnSpPr/p:cNvCxnSpPr/a:stCxn"_ostr,
|
||||
"id"_ostr, "42");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp/p:nvCxnSpPr/p:cNvCxnSpPr/a:stCxn"_ostr,
|
||||
"idx"_ostr, "0");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp/p:nvCxnSpPr/p:cNvCxnSpPr/a:endCxn"_ostr,
|
||||
"id"_ostr, "43");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp/p:nvCxnSpPr/p:cNvCxnSpPr/a:endCxn"_ostr,
|
||||
"idx"_ostr, "2");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf66228)
|
||||
@@ -125,7 +126,7 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf66228)
|
||||
save("Impress Office Open XML");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp/p:spPr/a:prstGeom", "prst",
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp/p:spPr/a:prstGeom"_ostr, "prst"_ostr,
|
||||
"bentConnector3");
|
||||
}
|
||||
|
||||
@@ -135,66 +136,72 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf147919)
|
||||
save("Impress Office Open XML");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[1]/p:spPr/a:prstGeom", "prst",
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[1]/p:spPr/a:prstGeom"_ostr, "prst"_ostr,
|
||||
"bentConnector2");
|
||||
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[2]/p:spPr/a:prstGeom/a:avLst/a:gd", "name",
|
||||
"adj1");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[2]/p:spPr/a:prstGeom", "prst",
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[2]/p:spPr/a:prstGeom/a:avLst/a:gd"_ostr,
|
||||
"name"_ostr, "adj1");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[2]/p:spPr/a:prstGeom"_ostr, "prst"_ostr,
|
||||
"bentConnector3");
|
||||
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[3]/p:spPr/a:xfrm", "flipH", "1");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[3]/p:spPr/a:xfrm", "rot", "16200000");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[3]/p:spPr/a:prstGeom/a:avLst/a:gd[1]",
|
||||
"name", "adj1");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[3]/p:spPr/a:prstGeom/a:avLst/a:gd[2]",
|
||||
"name", "adj2");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[3]/p:spPr/a:prstGeom", "prst",
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[3]/p:spPr/a:xfrm"_ostr, "flipH"_ostr, "1");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[3]/p:spPr/a:xfrm"_ostr, "rot"_ostr,
|
||||
"16200000");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[3]/p:spPr/a:prstGeom/a:avLst/a:gd[1]"_ostr,
|
||||
"name"_ostr, "adj1");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[3]/p:spPr/a:prstGeom/a:avLst/a:gd[2]"_ostr,
|
||||
"name"_ostr, "adj2");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[3]/p:spPr/a:prstGeom"_ostr, "prst"_ostr,
|
||||
"bentConnector4");
|
||||
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[4]/p:spPr/a:xfrm", "flipH", "1");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[4]/p:spPr/a:xfrm", "flipV", "1");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[4]/p:spPr/a:xfrm", "rot", "10800000");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[4]/p:spPr/a:prstGeom/a:avLst/a:gd[1]",
|
||||
"name", "adj1");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[4]/p:spPr/a:prstGeom/a:avLst/a:gd[2]",
|
||||
"name", "adj2");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[4]/p:spPr/a:prstGeom/a:avLst/a:gd[3]",
|
||||
"name", "adj3");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[4]/p:spPr/a:prstGeom", "prst",
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[4]/p:spPr/a:xfrm"_ostr, "flipH"_ostr, "1");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[4]/p:spPr/a:xfrm"_ostr, "flipV"_ostr, "1");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[4]/p:spPr/a:xfrm"_ostr, "rot"_ostr,
|
||||
"10800000");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[4]/p:spPr/a:prstGeom/a:avLst/a:gd[1]"_ostr,
|
||||
"name"_ostr, "adj1");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[4]/p:spPr/a:prstGeom/a:avLst/a:gd[2]"_ostr,
|
||||
"name"_ostr, "adj2");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[4]/p:spPr/a:prstGeom/a:avLst/a:gd[3]"_ostr,
|
||||
"name"_ostr, "adj3");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[4]/p:spPr/a:prstGeom"_ostr, "prst"_ostr,
|
||||
"bentConnector5");
|
||||
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[5]/p:spPr/a:xfrm", "flipH", "1");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[5]/p:spPr/a:xfrm", "rot", "16200000");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[5]/p:spPr/a:prstGeom", "prst",
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[5]/p:spPr/a:xfrm"_ostr, "flipH"_ostr, "1");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[5]/p:spPr/a:xfrm"_ostr, "rot"_ostr,
|
||||
"16200000");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[5]/p:spPr/a:prstGeom"_ostr, "prst"_ostr,
|
||||
"curvedConnector2");
|
||||
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[6]/p:spPr/a:xfrm", "flipH", "1");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[6]/p:spPr/a:xfrm", "rot", "16200000");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[6]/p:spPr/a:prstGeom/a:avLst/a:gd", "name",
|
||||
"adj1");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[6]/p:spPr/a:prstGeom", "prst",
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[6]/p:spPr/a:xfrm"_ostr, "flipH"_ostr, "1");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[6]/p:spPr/a:xfrm"_ostr, "rot"_ostr,
|
||||
"16200000");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[6]/p:spPr/a:prstGeom/a:avLst/a:gd"_ostr,
|
||||
"name"_ostr, "adj1");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[6]/p:spPr/a:prstGeom"_ostr, "prst"_ostr,
|
||||
"curvedConnector3");
|
||||
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[7]/p:spPr/a:xfrm", "flipH", "1");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[7]/p:spPr/a:xfrm", "flipV", "1");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[7]/p:spPr/a:xfrm", "rot", "10800000");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[7]/p:spPr/a:prstGeom/a:avLst/a:gd[1]",
|
||||
"name", "adj1");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[7]/p:spPr/a:prstGeom/a:avLst/a:gd[2]",
|
||||
"name", "adj2");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[7]/p:spPr/a:prstGeom", "prst",
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[7]/p:spPr/a:xfrm"_ostr, "flipH"_ostr, "1");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[7]/p:spPr/a:xfrm"_ostr, "flipV"_ostr, "1");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[7]/p:spPr/a:xfrm"_ostr, "rot"_ostr,
|
||||
"10800000");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[7]/p:spPr/a:prstGeom/a:avLst/a:gd[1]"_ostr,
|
||||
"name"_ostr, "adj1");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[7]/p:spPr/a:prstGeom/a:avLst/a:gd[2]"_ostr,
|
||||
"name"_ostr, "adj2");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[7]/p:spPr/a:prstGeom"_ostr, "prst"_ostr,
|
||||
"curvedConnector4");
|
||||
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[8]/p:spPr/a:xfrm", "flipV", "1");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[8]/p:spPr/a:xfrm", "rot", "16200000");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[8]/p:spPr/a:prstGeom/a:avLst/a:gd[1]",
|
||||
"name", "adj1");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[8]/p:spPr/a:prstGeom/a:avLst/a:gd[2]",
|
||||
"name", "adj2");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[8]/p:spPr/a:prstGeom/a:avLst/a:gd[3]",
|
||||
"name", "adj3");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[8]/p:spPr/a:prstGeom", "prst",
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[8]/p:spPr/a:xfrm"_ostr, "flipV"_ostr, "1");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[8]/p:spPr/a:xfrm"_ostr, "rot"_ostr,
|
||||
"16200000");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[8]/p:spPr/a:prstGeom/a:avLst/a:gd[1]"_ostr,
|
||||
"name"_ostr, "adj1");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[8]/p:spPr/a:prstGeom/a:avLst/a:gd[2]"_ostr,
|
||||
"name"_ostr, "adj2");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[8]/p:spPr/a:prstGeom/a:avLst/a:gd[3]"_ostr,
|
||||
"name"_ostr, "adj3");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:cxnSp[8]/p:spPr/a:prstGeom"_ostr, "prst"_ostr,
|
||||
"curvedConnector5");
|
||||
}
|
||||
|
||||
@@ -204,7 +211,7 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf130165)
|
||||
save("Impress Office Open XML");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDoc, "/p:sld", "showMasterSp", "0");
|
||||
assertXPath(pXmlDoc, "/p:sld"_ostr, "showMasterSp"_ostr, "0");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf124781)
|
||||
@@ -213,12 +220,12 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf124781)
|
||||
save("Impress Office Open XML");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc1 = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDoc1, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p[1]/a:r[2]/a:rPr", "baseline",
|
||||
"33000");
|
||||
assertXPath(pXmlDoc1, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p[1]/a:r[2]/a:rPr"_ostr,
|
||||
"baseline"_ostr, "33000");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc2 = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDoc2, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p[2]/a:r[2]/a:rPr", "baseline",
|
||||
"-8000");
|
||||
assertXPath(pXmlDoc2, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p[2]/a:r[2]/a:rPr"_ostr,
|
||||
"baseline"_ostr, "-8000");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf144914)
|
||||
@@ -227,37 +234,37 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf144914)
|
||||
save("Impress Office Open XML");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc1 = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDoc1, "/p:sld/p:cSld/p:spTree/p:sp[1]/p:nvSpPr/p:cNvPr/a:hlinkClick", "action",
|
||||
"ppaction://hlinkshowjump?jump=firstslide");
|
||||
assertXPath(pXmlDoc1, "/p:sld/p:cSld/p:spTree/p:sp[1]/p:nvSpPr/p:cNvPr/a:hlinkClick"_ostr,
|
||||
"action"_ostr, "ppaction://hlinkshowjump?jump=firstslide");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc2 = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDoc2, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:nvSpPr/p:cNvPr/a:hlinkClick", "action",
|
||||
"ppaction://hlinkshowjump?jump=lastslide");
|
||||
assertXPath(pXmlDoc2, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:nvSpPr/p:cNvPr/a:hlinkClick"_ostr,
|
||||
"action"_ostr, "ppaction://hlinkshowjump?jump=lastslide");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc3 = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDoc3, "/p:sld/p:cSld/p:spTree/p:sp[3]/p:nvSpPr/p:cNvPr/a:hlinkClick", "action",
|
||||
"ppaction://hlinkshowjump?jump=nextslide");
|
||||
assertXPath(pXmlDoc3, "/p:sld/p:cSld/p:spTree/p:sp[3]/p:nvSpPr/p:cNvPr/a:hlinkClick"_ostr,
|
||||
"action"_ostr, "ppaction://hlinkshowjump?jump=nextslide");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc4 = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDoc4, "/p:sld/p:cSld/p:spTree/p:sp[4]/p:nvSpPr/p:cNvPr/a:hlinkClick", "action",
|
||||
"ppaction://hlinkshowjump?jump=previousslide");
|
||||
assertXPath(pXmlDoc4, "/p:sld/p:cSld/p:spTree/p:sp[4]/p:nvSpPr/p:cNvPr/a:hlinkClick"_ostr,
|
||||
"action"_ostr, "ppaction://hlinkshowjump?jump=previousslide");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc5 = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDoc5, "/p:sld/p:cSld/p:spTree/p:sp[5]/p:nvSpPr/p:cNvPr/a:hlinkClick", "action",
|
||||
"ppaction://hlinksldjump");
|
||||
assertXPath(pXmlDoc5, "/p:sld/p:cSld/p:spTree/p:sp[5]/p:nvSpPr/p:cNvPr/a:hlinkClick"_ostr,
|
||||
"action"_ostr, "ppaction://hlinksldjump");
|
||||
xmlDocUniquePtr pRelsDoc5 = parseExport("ppt/slides/_rels/slide1.xml.rels");
|
||||
assertXPath(pRelsDoc5, "/rels:Relationships/rels:Relationship[@Id='rId1']", "Target",
|
||||
assertXPath(pRelsDoc5, "/rels:Relationships/rels:Relationship[@Id='rId1']"_ostr, "Target"_ostr,
|
||||
"slide2.xml");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc6 = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDoc6, "/p:sld/p:cSld/p:spTree/p:sp[6]/p:nvSpPr/p:cNvPr/a:hlinkClick", "action",
|
||||
"ppaction://hlinkshowjump?jump=endshow");
|
||||
assertXPath(pXmlDoc6, "/p:sld/p:cSld/p:spTree/p:sp[6]/p:nvSpPr/p:cNvPr/a:hlinkClick"_ostr,
|
||||
"action"_ostr, "ppaction://hlinkshowjump?jump=endshow");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc7 = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDoc7, "/p:sld/p:cSld/p:spTree/p:sp[7]/p:nvSpPr/p:cNvPr/a:hlinkClick", "id",
|
||||
"rId2");
|
||||
assertXPath(pXmlDoc7, "/p:sld/p:cSld/p:spTree/p:sp[7]/p:nvSpPr/p:cNvPr/a:hlinkClick"_ostr,
|
||||
"id"_ostr, "rId2");
|
||||
xmlDocUniquePtr pRelsDoc7 = parseExport("ppt/slides/_rels/slide1.xml.rels");
|
||||
assertXPath(pRelsDoc7, "/rels:Relationships/rels:Relationship[@Id='rId2']", "Target",
|
||||
assertXPath(pRelsDoc7, "/rels:Relationships/rels:Relationship[@Id='rId2']"_ostr, "Target"_ostr,
|
||||
"http://www.example.com/");
|
||||
}
|
||||
|
||||
@@ -267,38 +274,38 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf124232)
|
||||
save("Impress Office Open XML");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc1 = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDoc1, "/p:sld/p:cSld/p:spTree/p:pic/p:nvPicPr/p:cNvPr/a:hlinkClick", "action",
|
||||
"ppaction://hlinkshowjump?jump=lastslide");
|
||||
assertXPath(pXmlDoc1, "/p:sld/p:cSld/p:spTree/p:pic/p:nvPicPr/p:cNvPr/a:hlinkClick"_ostr,
|
||||
"action"_ostr, "ppaction://hlinkshowjump?jump=lastslide");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc2 = parseExport("ppt/slides/slide2.xml");
|
||||
assertXPath(pXmlDoc2, "/p:sld/p:cSld/p:spTree/p:pic/p:nvPicPr/p:cNvPr/a:hlinkClick", "action",
|
||||
"ppaction://hlinkshowjump?jump=nextslide");
|
||||
assertXPath(pXmlDoc2, "/p:sld/p:cSld/p:spTree/p:pic/p:nvPicPr/p:cNvPr/a:hlinkClick"_ostr,
|
||||
"action"_ostr, "ppaction://hlinkshowjump?jump=nextslide");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc3 = parseExport("ppt/slides/slide3.xml");
|
||||
assertXPath(pXmlDoc3, "/p:sld/p:cSld/p:spTree/p:pic/p:nvPicPr/p:cNvPr/a:hlinkClick", "action",
|
||||
"ppaction://hlinkshowjump?jump=previousslide");
|
||||
assertXPath(pXmlDoc3, "/p:sld/p:cSld/p:spTree/p:pic/p:nvPicPr/p:cNvPr/a:hlinkClick"_ostr,
|
||||
"action"_ostr, "ppaction://hlinkshowjump?jump=previousslide");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc4 = parseExport("ppt/slides/slide4.xml");
|
||||
assertXPath(pXmlDoc4, "/p:sld/p:cSld/p:spTree/p:pic/p:nvPicPr/p:cNvPr/a:hlinkClick", "id",
|
||||
"rId1");
|
||||
assertXPath(pXmlDoc4, "/p:sld/p:cSld/p:spTree/p:pic/p:nvPicPr/p:cNvPr/a:hlinkClick"_ostr,
|
||||
"id"_ostr, "rId1");
|
||||
xmlDocUniquePtr pRelsDoc4 = parseExport("ppt/slides/_rels/slide4.xml.rels");
|
||||
assertXPath(pRelsDoc4, "/rels:Relationships/rels:Relationship[@Id='rId1']", "Target",
|
||||
assertXPath(pRelsDoc4, "/rels:Relationships/rels:Relationship[@Id='rId1']"_ostr, "Target"_ostr,
|
||||
"http://www.example.com/");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc5 = parseExport("ppt/slides/slide5.xml");
|
||||
assertXPath(pXmlDoc5, "/p:sld/p:cSld/p:spTree/p:pic/p:nvPicPr/p:cNvPr/a:hlinkClick", "action",
|
||||
"ppaction://hlinksldjump");
|
||||
assertXPath(pXmlDoc5, "/p:sld/p:cSld/p:spTree/p:pic/p:nvPicPr/p:cNvPr/a:hlinkClick"_ostr,
|
||||
"action"_ostr, "ppaction://hlinksldjump");
|
||||
xmlDocUniquePtr pRelsDoc5 = parseExport("ppt/slides/_rels/slide5.xml.rels");
|
||||
assertXPath(pRelsDoc5, "/rels:Relationships/rels:Relationship[@Id='rId1']", "Target",
|
||||
assertXPath(pRelsDoc5, "/rels:Relationships/rels:Relationship[@Id='rId1']"_ostr, "Target"_ostr,
|
||||
"slide6.xml");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc6 = parseExport("ppt/slides/slide6.xml");
|
||||
assertXPath(pXmlDoc6, "/p:sld/p:cSld/p:spTree/p:pic/p:nvPicPr/p:cNvPr/a:hlinkClick", "action",
|
||||
"ppaction://hlinkshowjump?jump=endshow");
|
||||
assertXPath(pXmlDoc6, "/p:sld/p:cSld/p:spTree/p:pic/p:nvPicPr/p:cNvPr/a:hlinkClick"_ostr,
|
||||
"action"_ostr, "ppaction://hlinkshowjump?jump=endshow");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc7 = parseExport("ppt/slides/slide7.xml");
|
||||
assertXPath(pXmlDoc7, "/p:sld/p:cSld/p:spTree/p:pic/p:nvPicPr/p:cNvPr/a:hlinkClick", "action",
|
||||
"ppaction://hlinkshowjump?jump=firstslide");
|
||||
assertXPath(pXmlDoc7, "/p:sld/p:cSld/p:spTree/p:pic/p:nvPicPr/p:cNvPr/a:hlinkClick"_ostr,
|
||||
"action"_ostr, "ppaction://hlinkshowjump?jump=firstslide");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf143624)
|
||||
@@ -308,9 +315,9 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf143624)
|
||||
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("ppt/presProps.xml");
|
||||
|
||||
assertXPath(pXmlDoc, "/p:presentationPr/p:showPr", "useTimings", "0");
|
||||
assertXPath(pXmlDoc, "/p:presentationPr/p:showPr"_ostr, "useTimings"_ostr, "0");
|
||||
|
||||
assertXPath(pXmlDoc, "/p:presentationPr/p:showPr", "showNarration", "1");
|
||||
assertXPath(pXmlDoc, "/p:presentationPr/p:showPr"_ostr, "showNarration"_ostr, "1");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf142648)
|
||||
@@ -328,7 +335,7 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf142648)
|
||||
|
||||
xmlDocUniquePtr pRelsDoc = parseExport("ppt/slides/_rels/slide2.xml.rels");
|
||||
|
||||
assertXPath(pRelsDoc, "/rels:Relationships/rels:Relationship[@Id='rId1']", "Target",
|
||||
assertXPath(pRelsDoc, "/rels:Relationships/rels:Relationship[@Id='rId1']"_ostr, "Target"_ostr,
|
||||
"slide1.xml");
|
||||
}
|
||||
|
||||
@@ -339,9 +346,9 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf47365)
|
||||
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("ppt/presProps.xml");
|
||||
|
||||
assertXPath(pXmlDoc, "/p:presentationPr/p:showPr", "loop", "1");
|
||||
assertXPath(pXmlDoc, "/p:presentationPr/p:showPr"_ostr, "loop"_ostr, "1");
|
||||
|
||||
assertXPath(pXmlDoc, "/p:presentationPr/p:showPr", "showNarration", "1");
|
||||
assertXPath(pXmlDoc, "/p:presentationPr/p:showPr"_ostr, "showNarration"_ostr, "1");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf125071)
|
||||
@@ -351,8 +358,10 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf125071)
|
||||
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("ppt/presentation.xml");
|
||||
|
||||
assertXPath(pXmlDoc, "/p:presentation/p:custShowLst/p:custShow[1]", "name", "Custom1");
|
||||
assertXPath(pXmlDoc, "/p:presentation/p:custShowLst/p:custShow[2]", "name", "Custom2");
|
||||
assertXPath(pXmlDoc, "/p:presentation/p:custShowLst/p:custShow[1]"_ostr, "name"_ostr,
|
||||
"Custom1");
|
||||
assertXPath(pXmlDoc, "/p:presentation/p:custShowLst/p:custShow[2]"_ostr, "name"_ostr,
|
||||
"Custom2");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf54037)
|
||||
@@ -363,13 +372,13 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf54037)
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("ppt/slides/slide1.xml");
|
||||
xmlDocUniquePtr pRelsDoc = parseExport("ppt/slides/_rels/slide1.xml.rels");
|
||||
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p[1]/a:r/a:rPr/a:hlinkClick",
|
||||
"action", "ppaction://hlinksldjump");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p[1]/a:r/a:rPr/a:hlinkClick"_ostr,
|
||||
"action"_ostr, "ppaction://hlinksldjump");
|
||||
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p[2]/a:r/a:rPr/a:hlinkClick",
|
||||
"action", "ppaction://hlinkshowjump?jump=nextslide");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p[2]/a:r/a:rPr/a:hlinkClick"_ostr,
|
||||
"action"_ostr, "ppaction://hlinkshowjump?jump=nextslide");
|
||||
|
||||
assertXPath(pRelsDoc, "/rels:Relationships/rels:Relationship[@Id='rId1']", "Target",
|
||||
assertXPath(pRelsDoc, "/rels:Relationships/rels:Relationship[@Id='rId1']"_ostr, "Target"_ostr,
|
||||
"slide2.xml");
|
||||
}
|
||||
|
||||
@@ -1136,16 +1145,16 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf112633)
|
||||
// Check image with artistic effect exists in the slide
|
||||
assertXPath(pXmlDoc,
|
||||
"/p:sld/p:cSld/p:spTree/p:pic/p:blipFill/a:blip/a:extLst/a:ext/a14:imgProps/"
|
||||
"a14:imgLayer/a14:imgEffect/a14:artisticPencilGrayscale",
|
||||
"pencilSize", "80");
|
||||
"a14:imgLayer/a14:imgEffect/a14:artisticPencilGrayscale"_ostr,
|
||||
"pencilSize"_ostr, "80");
|
||||
|
||||
// Check there is a relation with the .wdp file that contains the backed up image
|
||||
OUString sEmbedId1 = getXPath(pXmlDoc,
|
||||
"/p:sld/p:cSld/p:spTree/p:pic/p:blipFill/a:blip/a:extLst/"
|
||||
"a:ext/a14:imgProps/a14:imgLayer",
|
||||
"embed");
|
||||
"a:ext/a14:imgProps/a14:imgLayer"_ostr,
|
||||
"embed"_ostr);
|
||||
OUString sXmlPath = "/rels:Relationships/rels:Relationship[@Id='" + sEmbedId1 + "']";
|
||||
assertXPath(pRelsDoc, OUStringToOString(sXmlPath, RTL_TEXTENCODING_UTF8), "Target",
|
||||
assertXPath(pRelsDoc, OUStringToOString(sXmlPath, RTL_TEXTENCODING_UTF8), "Target"_ostr,
|
||||
"../media/hdphoto1.wdp");
|
||||
|
||||
// Check the .wdp file exists
|
||||
@@ -1162,10 +1171,12 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf128952)
|
||||
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("ppt/slides/slide1.xml");
|
||||
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp/p:spPr/a:xfrm/a:off", "x", "360");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp/p:spPr/a:xfrm/a:off", "y", "-360");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp/p:spPr/a:xfrm/a:ext", "cx", "1919880");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp/p:spPr/a:xfrm/a:ext", "cy", "1462680");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp/p:spPr/a:xfrm/a:off"_ostr, "x"_ostr, "360");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp/p:spPr/a:xfrm/a:off"_ostr, "y"_ostr, "-360");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp/p:spPr/a:xfrm/a:ext"_ostr, "cx"_ostr,
|
||||
"1919880");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp/p:spPr/a:xfrm/a:ext"_ostr, "cy"_ostr,
|
||||
"1462680");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf127090)
|
||||
@@ -1175,7 +1186,8 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf127090)
|
||||
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("ppt/slides/slide1.xml");
|
||||
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:bodyPr", "rot", "-5400000");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:bodyPr"_ostr, "rot"_ostr,
|
||||
"-5400000");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testCustomXml)
|
||||
@@ -1190,8 +1202,8 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testCustomXml)
|
||||
CPPUNIT_ASSERT(pRelsDoc);
|
||||
|
||||
// Check there is a relation to itemProps1.xml.
|
||||
assertXPath(pRelsDoc, "/rels:Relationships/rels:Relationship", 1);
|
||||
assertXPath(pRelsDoc, "/rels:Relationships/rels:Relationship[@Id='rId1']", "Target",
|
||||
assertXPath(pRelsDoc, "/rels:Relationships/rels:Relationship"_ostr, 1);
|
||||
assertXPath(pRelsDoc, "/rels:Relationships/rels:Relationship[@Id='rId1']"_ostr, "Target"_ostr,
|
||||
"itemProps1.xml");
|
||||
|
||||
std::unique_ptr<SvStream> pStream = parseExportStream(maTempFile.GetURL(), "ddp/ddpfile.xen");
|
||||
@@ -1330,7 +1342,7 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testRoundtripPrstDash)
|
||||
for (sal_uInt16 i = 0; i < 10; i++)
|
||||
{
|
||||
OString sXmlPath = sStart + OString::number(i + 1) + sEnd;
|
||||
OUString sResaved = getXPath(pXmlDoc, sXmlPath, "val");
|
||||
OUString sResaved = getXPath(pXmlDoc, sXmlPath, "val"_ostr);
|
||||
CPPUNIT_ASSERT_EQUAL_MESSAGE("wrong prstDash", sOriginal[i], sResaved);
|
||||
}
|
||||
|
||||
@@ -1359,7 +1371,7 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testDashOnHairline)
|
||||
save("Impress Office Open XML");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp/p:spPr/a:ln/a:custDash/a:ds", 11);
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp/p:spPr/a:ln/a:custDash/a:ds"_ostr, 11);
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testNarrationNonMediaShape)
|
||||
@@ -1386,7 +1398,7 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testCustomshapeBitmapfillSrcrect)
|
||||
// i.e. <a:srcRect> was exported as <a:fillRect> in <a:stretch>, which made part of the image
|
||||
// invisible.
|
||||
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp/p:spPr/a:blipFill/a:srcRect");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp/p:spPr/a:blipFill/a:srcRect"_ostr);
|
||||
|
||||
// tdf#134210
|
||||
// Original values of attribute of l and r in xml files: <a:srcRect l="4393" r="4393"/>
|
||||
@@ -1395,10 +1407,14 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testCustomshapeBitmapfillSrcrect)
|
||||
// future if we add core feature to LibreOffice, we should change the control value with
|
||||
// 4393.
|
||||
|
||||
assertXPathNoAttribute(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp/p:spPr/a:blipFill/a:srcRect", "l");
|
||||
assertXPathNoAttribute(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp/p:spPr/a:blipFill/a:srcRect", "r");
|
||||
assertXPathNoAttribute(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp/p:spPr/a:blipFill/a:srcRect", "t");
|
||||
assertXPathNoAttribute(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp/p:spPr/a:blipFill/a:srcRect", "b");
|
||||
assertXPathNoAttribute(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp/p:spPr/a:blipFill/a:srcRect"_ostr,
|
||||
"l"_ostr);
|
||||
assertXPathNoAttribute(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp/p:spPr/a:blipFill/a:srcRect"_ostr,
|
||||
"r"_ostr);
|
||||
assertXPathNoAttribute(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp/p:spPr/a:blipFill/a:srcRect"_ostr,
|
||||
"t"_ostr);
|
||||
assertXPathNoAttribute(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp/p:spPr/a:blipFill/a:srcRect"_ostr,
|
||||
"b"_ostr);
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf100348FontworkBitmapFill)
|
||||
@@ -1411,7 +1427,7 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf100348FontworkBitmapFill)
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("ppt/slides/slide1.xml");
|
||||
static constexpr OString sPathStart("//p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p/a:r/a:rPr"_ostr);
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:blipFill/a:blip", 1);
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:ln/a:solidFill/a:srgbClr", "val", "ffbf00");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:ln/a:solidFill/a:srgbClr", "val"_ostr, "ffbf00");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf100348FontworkGradientGlow)
|
||||
@@ -1423,9 +1439,10 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf100348FontworkGradientGlow)
|
||||
// Without the patch, fill was black and no glow applied.
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("ppt/slides/slide1.xml");
|
||||
static constexpr OString sPathStart("//p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p/a:r/a:rPr"_ostr);
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:gradFill/a:gsLst/a:gs[1]/a:srgbClr", "val", "8d281e");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:effectLst/a:glow", "rad", "63360");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:effectLst/a:glow/a:srgbClr", "val", "ff4500");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:gradFill/a:gsLst/a:gs[1]/a:srgbClr", "val"_ostr,
|
||||
"8d281e");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:effectLst/a:glow", "rad"_ostr, "63360");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:effectLst/a:glow/a:srgbClr", "val"_ostr, "ff4500");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf128345FullTransparentGradient)
|
||||
@@ -1435,7 +1452,7 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf128345FullTransparentGradient)
|
||||
|
||||
// Make sure the shape has no fill. Without the patch, fill was solid red.
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDoc, "//p:sld/p:cSld/p:spTree/p:sp/p:spPr/a:noFill");
|
||||
assertXPath(pXmlDoc, "//p:sld/p:cSld/p:spTree/p:sp/p:spPr/a:noFill"_ostr);
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf128345GradientLinear)
|
||||
@@ -1446,14 +1463,14 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf128345GradientLinear)
|
||||
// Make sure the shape has a lin fill. Without the patch, fill was solid red.
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("ppt/slides/slide1.xml");
|
||||
static constexpr OString sPathStart("//p:sld/p:cSld/p:spTree/p:sp/p:spPr/a:gradFill"_ostr);
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:lin", "ang", "3600000");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:lin", "ang"_ostr, "3600000");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:gsLst/a:gs", 2);
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:gsLst/a:gs[1]", "pos", "25000");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:gsLst/a:gs[1]/a:srgbClr", "val", "ff0000");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:gsLst/a:gs[1]/a:srgbClr/a:alpha", "val", "20000");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:gsLst/a:gs[2]", "pos", "100000");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:gsLst/a:gs[2]/a:srgbClr", "val", "ff0000");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:gsLst/a:gs[2]/a:srgbClr/a:alpha", "val", "80000");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:gsLst/a:gs[1]", "pos"_ostr, "25000");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:gsLst/a:gs[1]/a:srgbClr", "val"_ostr, "ff0000");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:gsLst/a:gs[1]/a:srgbClr/a:alpha", "val"_ostr, "20000");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:gsLst/a:gs[2]", "pos"_ostr, "100000");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:gsLst/a:gs[2]/a:srgbClr", "val"_ostr, "ff0000");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:gsLst/a:gs[2]/a:srgbClr/a:alpha", "val"_ostr, "80000");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf128345GradientRadial)
|
||||
@@ -1466,10 +1483,10 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf128345GradientRadial)
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("ppt/slides/slide1.xml");
|
||||
static constexpr OString sPathStart("//p:sld/p:cSld/p:spTree/p:sp/p:spPr/a:gradFill"_ostr);
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:gsLst/a:gs", 2);
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:gsLst/a:gs[1]/a:srgbClr", "val", "ff0000");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:gsLst/a:gs[1]/a:srgbClr", "val"_ostr, "ff0000");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:gsLst/a:gs[1]/a:srgbClr/a:alpha", 0);
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:gsLst/a:gs[2]/a:srgbClr", "val", "ffffff");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:gsLst/a:gs[2]/a:srgbClr/a:alpha", "val", "0");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:gsLst/a:gs[2]/a:srgbClr", "val"_ostr, "ffffff");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:gsLst/a:gs[2]/a:srgbClr/a:alpha", "val"_ostr, "0");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf128345GradientAxial)
|
||||
@@ -1506,8 +1523,8 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf134969TransparencyOnColorGradien
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("ppt/slides/slide1.xml");
|
||||
static constexpr OString sPathStart("//p:sld/p:cSld/p:spTree/p:sp/p:spPr/a:gradFill"_ostr);
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:gsLst/a:gs", 2);
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:gsLst/a:gs[1]/a:srgbClr/a:alpha", "val", "60000");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:gsLst/a:gs[2]/a:srgbClr/a:alpha", "val", "60000");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:gsLst/a:gs[1]/a:srgbClr/a:alpha", "val"_ostr, "60000");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:gsLst/a:gs[2]/a:srgbClr/a:alpha", "val"_ostr, "60000");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testArcTo)
|
||||
@@ -1517,10 +1534,10 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testArcTo)
|
||||
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("ppt/slides/slide1.xml");
|
||||
static constexpr OString sPath("//a:custGeom/a:pathLst/a:path/a:arcTo"_ostr);
|
||||
assertXPath(pXmlDoc, sPath, "wR", "3");
|
||||
assertXPath(pXmlDoc, sPath, "hR", "3");
|
||||
assertXPath(pXmlDoc, sPath, "stAng", "1800000");
|
||||
assertXPath(pXmlDoc, sPath, "swAng", "2700000");
|
||||
assertXPath(pXmlDoc, sPath, "wR"_ostr, "3");
|
||||
assertXPath(pXmlDoc, sPath, "hR"_ostr, "3");
|
||||
assertXPath(pXmlDoc, sPath, "stAng"_ostr, "1800000");
|
||||
assertXPath(pXmlDoc, sPath, "swAng"_ostr, "2700000");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testNarrationMimeType)
|
||||
@@ -1533,17 +1550,17 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testNarrationMimeType)
|
||||
// - Actual : application/vnd.sun.star.media
|
||||
// i.e. the mime type of the narration was incorrect.
|
||||
assertXPath(pXmlDoc,
|
||||
"/ContentType:Types/ContentType:Override[@PartName='/ppt/media/media1.m4a']",
|
||||
"ContentType", "audio/mp4");
|
||||
"/ContentType:Types/ContentType:Override[@PartName='/ppt/media/media1.m4a']"_ostr,
|
||||
"ContentType"_ostr, "audio/mp4");
|
||||
|
||||
// Check if the bitmap of the media shape is exported correctly.
|
||||
xmlDocUniquePtr pSlideDoc = parseExport("ppt/slides/slide1.xml");
|
||||
OUString aImageId
|
||||
= getXPath(pSlideDoc, "/p:sld/p:cSld/p:spTree/p:pic/p:blipFill/a:blip", "embed");
|
||||
= getXPath(pSlideDoc, "/p:sld/p:cSld/p:spTree/p:pic/p:blipFill/a:blip"_ostr, "embed"_ostr);
|
||||
xmlDocUniquePtr pRelsDoc = parseExport("ppt/slides/_rels/slide1.xml.rels");
|
||||
OUString aImagePath = "/rels:Relationships/rels:Relationship[@Id='" + aImageId + "']";
|
||||
// Something like ../media/image2.png.
|
||||
OUString aImageStreamName = getXPath(pRelsDoc, aImagePath.toUtf8(), "Target");
|
||||
OUString aImageStreamName = getXPath(pRelsDoc, aImagePath.toUtf8(), "Target"_ostr);
|
||||
OUString aImageAbsName = rtl::Uri::convertRelToAbs("file:///ppt/slides/", aImageStreamName);
|
||||
// Something like ppt/media/image2.png.
|
||||
OUString aImageRelName;
|
||||
@@ -1561,28 +1578,28 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testNarrationMimeType)
|
||||
// - Expected: 1
|
||||
// - Actual : 0
|
||||
// i.e. p:blipFill was missing its a:stretch child element, so the shape was invisible.
|
||||
assertXPath(pSlideDoc, "/p:sld/p:cSld/p:spTree/p:pic/p:blipFill/a:stretch/a:fillRect", 1);
|
||||
assertXPath(pSlideDoc, "/p:sld/p:cSld/p:spTree/p:pic/p:blipFill/a:stretch/a:fillRect"_ostr, 1);
|
||||
|
||||
// Without the accompanying fix in place, this test would have failed with:
|
||||
// - ... no attribute 'cmd' exist
|
||||
// i.e. '<p:cmd type="call">' was written instead of '<p:cmd type="call" cmd="playFrom(0.0)">'.
|
||||
assertXPath(pSlideDoc, "//p:cmd", "cmd", "playFrom(0.0)");
|
||||
assertXPath(pSlideDoc, "//p:cmd"_ostr, "cmd"_ostr, "playFrom(0.0)");
|
||||
|
||||
// Without the accompanying fix in place, this test would have failed with:
|
||||
// - Expected: 1
|
||||
// - Actual : 0
|
||||
// i.e. <p:childTnLst> had no <p:audio> children, the whole audio animation node was lost.
|
||||
assertXPath(pSlideDoc, "//p:childTnLst/p:audio/p:cMediaNode", 1);
|
||||
assertXPath(pSlideDoc, "//p:childTnLst/p:audio/p:cMediaNode"_ostr, 1);
|
||||
|
||||
// Without the accompanying fix in place, this test would have failed with:
|
||||
// - ... no attribute 'showWhenStopped' exist
|
||||
// i.e. <p:cMediaNode> had the default visibility -> bitmap was visible during slideshow.
|
||||
assertXPath(pSlideDoc, "//p:childTnLst/p:audio/p:cMediaNode", "showWhenStopped", "0");
|
||||
assertXPath(pSlideDoc, "//p:childTnLst/p:audio/p:cMediaNode"_ostr, "showWhenStopped"_ostr, "0");
|
||||
|
||||
// Without the accompanying fix in place, this test would have failed with:
|
||||
// - ... no attribute 'isNarration' exist
|
||||
// i.e. <p:audio> was not a narration -> could not mass-remove narrations on the UI.
|
||||
assertXPath(pSlideDoc, "//p:childTnLst/p:audio", "isNarration", "1");
|
||||
assertXPath(pSlideDoc, "//p:childTnLst/p:audio"_ostr, "isNarration"_ostr, "1");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf150316)
|
||||
@@ -1591,7 +1608,8 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf150316)
|
||||
save("Impress Office Open XML");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[1]/p:txBody/a:p/a:pPr", "indent", "-343080");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[1]/p:txBody/a:p/a:pPr"_ostr, "indent"_ostr,
|
||||
"-343080");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf140865Wordart3D)
|
||||
@@ -1602,14 +1620,14 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf140865Wordart3D)
|
||||
|
||||
// without the fix in place a:sp3d was lost on round trip, and so extrusion was lost.
|
||||
constexpr OString sPathStart("//p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:bodyPr"_ostr);
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:sp3d", "extrusionH", "342900");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:sp3d", "contourW", "12700");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:sp3d/a:bevelT", "w", "114300");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:sp3d/a:bevelT", "h", "38100");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:sp3d/a:bevelT", "prst", "softRound");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:sp3d/a:bevelB", "h", "152400");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:sp3d/a:extrusionClr/a:srgbClr", "val", "990000");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:sp3d/a:contourClr/a:srgbClr", "val", "009876");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:sp3d", "extrusionH"_ostr, "342900");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:sp3d", "contourW"_ostr, "12700");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:sp3d/a:bevelT", "w"_ostr, "114300");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:sp3d/a:bevelT", "h"_ostr, "38100");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:sp3d/a:bevelT", "prst"_ostr, "softRound");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:sp3d/a:bevelB", "h"_ostr, "152400");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:sp3d/a:extrusionClr/a:srgbClr", "val"_ostr, "990000");
|
||||
assertXPath(pXmlDoc, sPathStart + "/a:sp3d/a:contourClr/a:srgbClr", "val"_ostr, "009876");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf124457)
|
||||
@@ -1619,15 +1637,17 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf124457)
|
||||
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("ppt/slides/slide1.xml");
|
||||
|
||||
assertXPath(pXmlDoc,
|
||||
"/p:sld/p:timing/p:tnLst/p:par/p:cTn/p:childTnLst/p:seq/p:cTn/"
|
||||
"p:childTnLst/p:par/p:cTn/p:childTnLst/p:par/p:cTn/p:childTnLst/p:par[1]/p:cTn",
|
||||
"repeatCount", "3000");
|
||||
assertXPath(
|
||||
pXmlDoc,
|
||||
"/p:sld/p:timing/p:tnLst/p:par/p:cTn/p:childTnLst/p:seq/p:cTn/"
|
||||
"p:childTnLst/p:par/p:cTn/p:childTnLst/p:par/p:cTn/p:childTnLst/p:par[1]/p:cTn"_ostr,
|
||||
"repeatCount"_ostr, "3000");
|
||||
|
||||
assertXPath(pXmlDoc,
|
||||
"/p:sld/p:timing/p:tnLst/p:par/p:cTn/p:childTnLst/p:seq/p:cTn/"
|
||||
"p:childTnLst/p:par/p:cTn/p:childTnLst/p:par/p:cTn/p:childTnLst/p:par[2]/p:cTn",
|
||||
"repeatCount", "indefinite");
|
||||
assertXPath(
|
||||
pXmlDoc,
|
||||
"/p:sld/p:timing/p:tnLst/p:par/p:cTn/p:childTnLst/p:seq/p:cTn/"
|
||||
"p:childTnLst/p:par/p:cTn/p:childTnLst/p:par/p:cTn/p:childTnLst/p:par[2]/p:cTn"_ostr,
|
||||
"repeatCount"_ostr, "indefinite");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf143126)
|
||||
@@ -1637,9 +1657,9 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf143126)
|
||||
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("ppt/presProps.xml");
|
||||
|
||||
assertXPath(pXmlDoc, "/p:presentationPr/p:showPr", "showNarration", "1");
|
||||
assertXPath(pXmlDoc, "/p:presentationPr/p:showPr/p:sldRg", "st", "2");
|
||||
assertXPath(pXmlDoc, "/p:presentationPr/p:showPr/p:sldRg", "end", "3");
|
||||
assertXPath(pXmlDoc, "/p:presentationPr/p:showPr"_ostr, "showNarration"_ostr, "1");
|
||||
assertXPath(pXmlDoc, "/p:presentationPr/p:showPr/p:sldRg"_ostr, "st"_ostr, "2");
|
||||
assertXPath(pXmlDoc, "/p:presentationPr/p:showPr/p:sldRg"_ostr, "end"_ostr, "3");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf143129)
|
||||
@@ -1649,8 +1669,8 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf143129)
|
||||
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("ppt/presProps.xml");
|
||||
|
||||
assertXPath(pXmlDoc, "/p:presentationPr/p:showPr", "showNarration", "1");
|
||||
assertXPath(pXmlDoc, "/p:presentationPr/p:showPr/p:custShow", "id", "0");
|
||||
assertXPath(pXmlDoc, "/p:presentationPr/p:showPr"_ostr, "showNarration"_ostr, "1");
|
||||
assertXPath(pXmlDoc, "/p:presentationPr/p:showPr/p:custShow"_ostr, "id"_ostr, "0");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf118045)
|
||||
@@ -1659,8 +1679,8 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf118045)
|
||||
save("Impress Office Open XML");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc1 = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDoc1, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p/a:pPr/a:lnSpc/a:spcPct", "val",
|
||||
"110000");
|
||||
assertXPath(pXmlDoc1, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p/a:pPr/a:lnSpc/a:spcPct"_ostr,
|
||||
"val"_ostr, "110000");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf137675)
|
||||
@@ -1669,8 +1689,8 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf137675)
|
||||
save("Impress Office Open XML");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp/p:spPr/a:custGeom/a:pathLst/a:path", "fill",
|
||||
"none");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp/p:spPr/a:custGeom/a:pathLst/a:path"_ostr,
|
||||
"fill"_ostr, "none");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf151134)
|
||||
@@ -1679,7 +1699,8 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest1, testTdf151134)
|
||||
save("Impress Office Open XML");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[1]/p:txBody/a:bodyPr", "lIns", "91440");
|
||||
assertXPath(pXmlDoc, "/p:sld/p:cSld/p:spTree/p:sp[1]/p:txBody/a:bodyPr"_ostr, "lIns"_ostr,
|
||||
"91440");
|
||||
}
|
||||
|
||||
CPPUNIT_PLUGIN_IMPLEMENT();
|
||||
|
||||
+363
-310
File diff suppressed because it is too large
Load Diff
+166
-136
@@ -33,14 +33,14 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf153105)
|
||||
save("Impress Office Open XML");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc1 = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDoc1, "/p:sld/p:cSld/p:bg/p:bgPr/a:blipFill/a:stretch/a:fillRect", "l",
|
||||
"20000");
|
||||
assertXPath(pXmlDoc1, "/p:sld/p:cSld/p:bg/p:bgPr/a:blipFill/a:stretch/a:fillRect", "t",
|
||||
"30000");
|
||||
assertXPath(pXmlDoc1, "/p:sld/p:cSld/p:bg/p:bgPr/a:blipFill/a:stretch/a:fillRect", "r",
|
||||
"20000");
|
||||
assertXPath(pXmlDoc1, "/p:sld/p:cSld/p:bg/p:bgPr/a:blipFill/a:stretch/a:fillRect", "b",
|
||||
"30000");
|
||||
assertXPath(pXmlDoc1, "/p:sld/p:cSld/p:bg/p:bgPr/a:blipFill/a:stretch/a:fillRect"_ostr,
|
||||
"l"_ostr, "20000");
|
||||
assertXPath(pXmlDoc1, "/p:sld/p:cSld/p:bg/p:bgPr/a:blipFill/a:stretch/a:fillRect"_ostr,
|
||||
"t"_ostr, "30000");
|
||||
assertXPath(pXmlDoc1, "/p:sld/p:cSld/p:bg/p:bgPr/a:blipFill/a:stretch/a:fillRect"_ostr,
|
||||
"r"_ostr, "20000");
|
||||
assertXPath(pXmlDoc1, "/p:sld/p:cSld/p:bg/p:bgPr/a:blipFill/a:stretch/a:fillRect"_ostr,
|
||||
"b"_ostr, "30000");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf92222)
|
||||
@@ -49,12 +49,12 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf92222)
|
||||
save("Impress Office Open XML");
|
||||
|
||||
xmlDocUniquePtr pXmlDocTheme = parseExport("ppt/theme/theme1.xml");
|
||||
assertXPath(pXmlDocTheme, "/a:theme/a:themeElements/a:fmtScheme/a:lnStyleLst/a:ln[1]", "w",
|
||||
"6350");
|
||||
assertXPath(pXmlDocTheme, "/a:theme/a:themeElements/a:fmtScheme/a:lnStyleLst/a:ln[2]", "w",
|
||||
"12700");
|
||||
assertXPath(pXmlDocTheme, "/a:theme/a:themeElements/a:fmtScheme/a:lnStyleLst/a:ln[3]", "w",
|
||||
"19050");
|
||||
assertXPath(pXmlDocTheme, "/a:theme/a:themeElements/a:fmtScheme/a:lnStyleLst/a:ln[1]"_ostr,
|
||||
"w"_ostr, "6350");
|
||||
assertXPath(pXmlDocTheme, "/a:theme/a:themeElements/a:fmtScheme/a:lnStyleLst/a:ln[2]"_ostr,
|
||||
"w"_ostr, "12700");
|
||||
assertXPath(pXmlDocTheme, "/a:theme/a:themeElements/a:fmtScheme/a:lnStyleLst/a:ln[3]"_ostr,
|
||||
"w"_ostr, "19050");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf129430)
|
||||
@@ -63,8 +63,8 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf129430)
|
||||
save("Impress Office Open XML");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc1 = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDoc1, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p[2]/a:pPr/a:lnSpc/a:spcPct",
|
||||
"val", "100000");
|
||||
assertXPath(pXmlDoc1, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p[2]/a:pPr/a:lnSpc/a:spcPct"_ostr,
|
||||
"val"_ostr, "100000");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf114848)
|
||||
@@ -73,8 +73,8 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf114848)
|
||||
save("Impress Office Open XML");
|
||||
|
||||
xmlDocUniquePtr pXmlDocTheme1 = parseExport("ppt/theme/theme1.xml");
|
||||
assertXPath(pXmlDocTheme1, "/a:theme/a:themeElements/a:clrScheme/a:dk2/a:srgbClr", "val",
|
||||
"1f497d");
|
||||
assertXPath(pXmlDocTheme1, "/a:theme/a:themeElements/a:clrScheme/a:dk2/a:srgbClr"_ostr,
|
||||
"val"_ostr, "1f497d");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf147586)
|
||||
@@ -87,11 +87,11 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf147586)
|
||||
// - Expected: 227fc7
|
||||
// - Actual : 4f4f4f
|
||||
assertXPath(pXmlDocContent,
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[1]/p:txBody/a:p[1]/a:pPr/a:buClr/a:srgbClr", "val",
|
||||
"227fc7");
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[1]/p:txBody/a:p[1]/a:pPr/a:buClr/a:srgbClr"_ostr,
|
||||
"val"_ostr, "227fc7");
|
||||
assertXPath(pXmlDocContent,
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[1]/p:txBody/a:p[2]/a:pPr/a:buClr/a:srgbClr", "val",
|
||||
"227fc7");
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[1]/p:txBody/a:p[2]/a:pPr/a:buClr/a:srgbClr"_ostr,
|
||||
"val"_ostr, "227fc7");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf68759)
|
||||
@@ -100,21 +100,24 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf68759)
|
||||
save("Impress Office Open XML");
|
||||
|
||||
xmlDocUniquePtr pXmlDocContent = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:pic[1]/p:spPr/a:xfrm/a:off", "x",
|
||||
"1687320");
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:pic[1]/p:spPr/a:xfrm/a:off", "y",
|
||||
"1615320");
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:pic[2]/p:spPr/a:xfrm", "flipH", "1");
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:pic[2]/p:spPr/a:xfrm", "rot", "9600000");
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:pic[2]/p:spPr/a:xfrm/a:off", "x",
|
||||
"3847320");
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:pic[2]/p:spPr/a:xfrm/a:off", "y",
|
||||
"1614600");
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:pic[3]/p:spPr/a:xfrm", "flipH", "1");
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:pic[3]/p:spPr/a:xfrm/a:off", "x",
|
||||
"5934960");
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:pic[3]/p:spPr/a:xfrm/a:off", "y",
|
||||
"1615320");
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:pic[1]/p:spPr/a:xfrm/a:off"_ostr,
|
||||
"x"_ostr, "1687320");
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:pic[1]/p:spPr/a:xfrm/a:off"_ostr,
|
||||
"y"_ostr, "1615320");
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:pic[2]/p:spPr/a:xfrm"_ostr, "flipH"_ostr,
|
||||
"1");
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:pic[2]/p:spPr/a:xfrm"_ostr, "rot"_ostr,
|
||||
"9600000");
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:pic[2]/p:spPr/a:xfrm/a:off"_ostr,
|
||||
"x"_ostr, "3847320");
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:pic[2]/p:spPr/a:xfrm/a:off"_ostr,
|
||||
"y"_ostr, "1614600");
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:pic[3]/p:spPr/a:xfrm"_ostr, "flipH"_ostr,
|
||||
"1");
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:pic[3]/p:spPr/a:xfrm/a:off"_ostr,
|
||||
"x"_ostr, "5934960");
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:pic[3]/p:spPr/a:xfrm/a:off"_ostr,
|
||||
"y"_ostr, "1615320");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf127901)
|
||||
@@ -123,17 +126,18 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf127901)
|
||||
save("Impress Office Open XML");
|
||||
|
||||
xmlDocUniquePtr pXmlDocContent1 = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDocContent1, "/p:sld/p:cSld/p:spTree/p:pic/p:blipFill/a:blip/a:lum", "bright",
|
||||
"70000");
|
||||
assertXPath(pXmlDocContent1, "/p:sld/p:cSld/p:spTree/p:pic/p:blipFill/a:blip/a:lum", "contrast",
|
||||
"-70000");
|
||||
assertXPath(pXmlDocContent1, "/p:sld/p:cSld/p:spTree/p:pic/p:blipFill/a:blip/a:lum"_ostr,
|
||||
"bright"_ostr, "70000");
|
||||
assertXPath(pXmlDocContent1, "/p:sld/p:cSld/p:spTree/p:pic/p:blipFill/a:blip/a:lum"_ostr,
|
||||
"contrast"_ostr, "-70000");
|
||||
|
||||
xmlDocUniquePtr pXmlDocContent2 = parseExport("ppt/slides/slide2.xml");
|
||||
assertXPath(pXmlDocContent2, "/p:sld/p:cSld/p:spTree/p:pic/p:blipFill/a:blip/a:grayscl", 1);
|
||||
assertXPath(pXmlDocContent2, "/p:sld/p:cSld/p:spTree/p:pic/p:blipFill/a:blip/a:grayscl"_ostr,
|
||||
1);
|
||||
|
||||
xmlDocUniquePtr pXmlDocContent3 = parseExport("ppt/slides/slide3.xml");
|
||||
assertXPath(pXmlDocContent3, "/p:sld/p:cSld/p:spTree/p:pic/p:blipFill/a:blip/a:biLevel",
|
||||
"thresh", "50000");
|
||||
assertXPath(pXmlDocContent3, "/p:sld/p:cSld/p:spTree/p:pic/p:blipFill/a:blip/a:biLevel"_ostr,
|
||||
"thresh"_ostr, "50000");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf48735)
|
||||
@@ -142,10 +146,14 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf48735)
|
||||
save("Impress Office Open XML");
|
||||
|
||||
xmlDocUniquePtr pXmlDocContent1 = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDocContent1, "/p:sld/p:cSld/p:spTree/p:pic/p:blipFill/a:srcRect", "b", "23627");
|
||||
assertXPath(pXmlDocContent1, "/p:sld/p:cSld/p:spTree/p:pic/p:blipFill/a:srcRect", "l", "23627");
|
||||
assertXPath(pXmlDocContent1, "/p:sld/p:cSld/p:spTree/p:pic/p:blipFill/a:srcRect", "r", "23627");
|
||||
assertXPath(pXmlDocContent1, "/p:sld/p:cSld/p:spTree/p:pic/p:blipFill/a:srcRect", "t", "18842");
|
||||
assertXPath(pXmlDocContent1, "/p:sld/p:cSld/p:spTree/p:pic/p:blipFill/a:srcRect"_ostr, "b"_ostr,
|
||||
"23627");
|
||||
assertXPath(pXmlDocContent1, "/p:sld/p:cSld/p:spTree/p:pic/p:blipFill/a:srcRect"_ostr, "l"_ostr,
|
||||
"23627");
|
||||
assertXPath(pXmlDocContent1, "/p:sld/p:cSld/p:spTree/p:pic/p:blipFill/a:srcRect"_ostr, "r"_ostr,
|
||||
"23627");
|
||||
assertXPath(pXmlDocContent1, "/p:sld/p:cSld/p:spTree/p:pic/p:blipFill/a:srcRect"_ostr, "t"_ostr,
|
||||
"18842");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf90626)
|
||||
@@ -154,14 +162,18 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf90626)
|
||||
save("Impress Office Open XML");
|
||||
|
||||
xmlDocUniquePtr pXmlDocContent = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[1]/a:pPr/a:buSzPct",
|
||||
"val", "100000");
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[2]/a:pPr/a:buSzPct",
|
||||
"val", "150142");
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[3]/a:pPr/a:buSzPct",
|
||||
"val", "100000");
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[4]/a:pPr/a:buSzPct",
|
||||
"val", "150142");
|
||||
assertXPath(pXmlDocContent,
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[1]/a:pPr/a:buSzPct"_ostr, "val"_ostr,
|
||||
"100000");
|
||||
assertXPath(pXmlDocContent,
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[2]/a:pPr/a:buSzPct"_ostr, "val"_ostr,
|
||||
"150142");
|
||||
assertXPath(pXmlDocContent,
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[3]/a:pPr/a:buSzPct"_ostr, "val"_ostr,
|
||||
"100000");
|
||||
assertXPath(pXmlDocContent,
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[4]/a:pPr/a:buSzPct"_ostr, "val"_ostr,
|
||||
"150142");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf107608)
|
||||
@@ -211,8 +223,9 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testFontScale)
|
||||
xmlDocUniquePtr pXmlDocContent = parseExport("ppt/slides/slide1.xml");
|
||||
|
||||
// Rounding errors possible, approximate value (+/- 1%)
|
||||
OUString sScale = getXPath(
|
||||
pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:bodyPr/a:normAutofit", "fontScale");
|
||||
OUString sScale = getXPath(pXmlDocContent,
|
||||
"/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:bodyPr/a:normAutofit"_ostr,
|
||||
"fontScale"_ostr);
|
||||
CPPUNIT_ASSERT_DOUBLES_EQUAL(sal_Int32(81111), sScale.toInt32(), 1000);
|
||||
}
|
||||
|
||||
@@ -224,9 +237,11 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testShapeAutofitPPTX)
|
||||
CPPUNIT_ASSERT(pXmlDocContent);
|
||||
|
||||
// TextAutoGrowHeight --> "Resize shape to fit text" --> true
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:sp[1]/p:txBody/a:bodyPr/a:spAutoFit", 1);
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:sp[1]/p:txBody/a:bodyPr/a:spAutoFit"_ostr,
|
||||
1);
|
||||
// TextAutoGrowHeight --> "Resize shape to fit text" --> false
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:bodyPr/a:noAutofit", 1);
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:bodyPr/a:noAutofit"_ostr,
|
||||
1);
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testLegacyShapeAutofitPPTX)
|
||||
@@ -237,11 +252,14 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testLegacyShapeAutofitPPTX)
|
||||
CPPUNIT_ASSERT(pXmlDocContent);
|
||||
|
||||
// Text in a legacy rectangle
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:sp[1]/p:txBody/a:bodyPr/a:noAutofit", 1);
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:sp[1]/p:txBody/a:bodyPr/a:noAutofit"_ostr,
|
||||
1);
|
||||
// Text in (closed) Polygon
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:bodyPr/a:noAutofit", 1);
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:bodyPr/a:noAutofit"_ostr,
|
||||
1);
|
||||
// Text in a legacy ellipse
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:sp[3]/p:txBody/a:bodyPr/a:noAutofit", 1);
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:sp[3]/p:txBody/a:bodyPr/a:noAutofit"_ostr,
|
||||
1);
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf115394)
|
||||
@@ -371,7 +389,7 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf118806)
|
||||
save("Impress Office Open XML");
|
||||
|
||||
xmlDocUniquePtr pXmlDocContent = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDocContent, "//p:animMotion", "origin", "layout");
|
||||
assertXPath(pXmlDocContent, "//p:animMotion"_ostr, "origin"_ostr, "layout");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf130058)
|
||||
@@ -449,7 +467,8 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf145162)
|
||||
save("Impress Office Open XML");
|
||||
xmlDocUniquePtr pXmlDocContent = parseExport("ppt/slides/slide1.xml");
|
||||
|
||||
assertXPath(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[2]/a:pPr/a:buNone");
|
||||
assertXPath(pXmlDocContent,
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[2]/a:pPr/a:buNone"_ostr);
|
||||
// Before the fix, that tag was missing so PP put bullet to each para.
|
||||
}
|
||||
|
||||
@@ -471,19 +490,25 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testZeroIndentExport)
|
||||
// Each slide has 3 paragraphs, one full line, an empty and a normal para.
|
||||
// Check the indent and bullet. These have to match with PP. Before the fix,
|
||||
// they were different.
|
||||
assertXPath(pSlide1, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[2]/a:pPr/a:buNone");
|
||||
assertXPath(pSlide1, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[2]/a:pPr/a:buNone"_ostr);
|
||||
|
||||
assertXPath(pSlide2, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[1]/a:pPr/a:buNone");
|
||||
assertXPath(pSlide2, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[1]/a:pPr", "indent", "0");
|
||||
assertXPath(pSlide2, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[2]/a:pPr/a:buNone");
|
||||
assertXPath(pSlide2, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[2]/a:pPr", "indent", "0");
|
||||
assertXPath(pSlide2, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[3]/a:pPr/a:buNone");
|
||||
assertXPath(pSlide2, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[3]/a:pPr", "indent", "0");
|
||||
assertXPath(pSlide2, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[1]/a:pPr/a:buNone"_ostr);
|
||||
assertXPath(pSlide2, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[1]/a:pPr"_ostr, "indent"_ostr,
|
||||
"0");
|
||||
assertXPath(pSlide2, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[2]/a:pPr/a:buNone"_ostr);
|
||||
assertXPath(pSlide2, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[2]/a:pPr"_ostr, "indent"_ostr,
|
||||
"0");
|
||||
assertXPath(pSlide2, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[3]/a:pPr/a:buNone"_ostr);
|
||||
assertXPath(pSlide2, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[3]/a:pPr"_ostr, "indent"_ostr,
|
||||
"0");
|
||||
|
||||
assertXPath(pSlide3, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[1]/a:pPr", "indent", "0");
|
||||
assertXPath(pSlide3, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[2]/a:pPr/a:buNone");
|
||||
assertXPath(pSlide3, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[2]/a:pPr", "indent", "0");
|
||||
assertXPath(pSlide3, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[3]/a:pPr", "indent", "0");
|
||||
assertXPath(pSlide3, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[1]/a:pPr"_ostr, "indent"_ostr,
|
||||
"0");
|
||||
assertXPath(pSlide3, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[2]/a:pPr/a:buNone"_ostr);
|
||||
assertXPath(pSlide3, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[2]/a:pPr"_ostr, "indent"_ostr,
|
||||
"0");
|
||||
assertXPath(pSlide3, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[3]/a:pPr"_ostr, "indent"_ostr,
|
||||
"0");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf100348_convert_Fontwork2TextWarp)
|
||||
@@ -548,7 +573,7 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf125573_FontWorkScaleX)
|
||||
// ensure, resulting pptx has fromWordArt="1" on textArchDown shape
|
||||
xmlDocUniquePtr pXmlDocContent = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDocContent,
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[1]/p:txBody/a:bodyPr[@fromWordArt='1']");
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[1]/p:txBody/a:bodyPr[@fromWordArt='1']"_ostr);
|
||||
|
||||
// Error was, that text in legacy shapes of category "Follow Path" was not scaled to the path.
|
||||
uno::Reference<beans::XPropertySet> xShapeArchProps(getShapeFromPage(0, 0));
|
||||
@@ -585,7 +610,7 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf99497_keepAppearanceOfCircleKind
|
||||
const OString sPathAdj1(sPathStart1 + "/a:avLst/a:gd");
|
||||
assertXPath(pXmlDocContent1, sPathAdj1 + "[@name='adj1' and @fmla='val 20493903']");
|
||||
assertXPath(pXmlDocContent1, sPathAdj1 + "[@name='adj2' and @fmla='val 5400000']");
|
||||
assertXPath(pXmlDocContent1, "/p:sld/p:cSld/p:spTree/p:sp/p:spPr/a:noFill");
|
||||
assertXPath(pXmlDocContent1, "/p:sld/p:cSld/p:spTree/p:sp/p:spPr/a:noFill"_ostr);
|
||||
|
||||
// slide 2 270° -> adj1 = 5400000, 180° -> adj2 = 10800000
|
||||
xmlDocUniquePtr pXmlDocContent2 = parseExport("ppt/slides/slide2.xml");
|
||||
@@ -613,7 +638,7 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf104792)
|
||||
assertXPath(pXmlDocContent,
|
||||
"/p:sld/p:timing/p:tnLst/p:par/p:cTn/p:childTnLst[1]/p:seq/p:cTn/p:childTnLst[1]/"
|
||||
"p:par[1]/p:cTn/p:childTnLst[1]/p:par/p:cTn/p:childTnLst[1]/p:par/p:cTn/"
|
||||
"p:childTnLst[1]/p:set/p:cBhvr/p:tgtEl/p:spTgt",
|
||||
"p:childTnLst[1]/p:set/p:cBhvr/p:tgtEl/p:spTgt"_ostr,
|
||||
1);
|
||||
}
|
||||
|
||||
@@ -627,7 +652,7 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf90627)
|
||||
assertXPath(pXmlDocContent,
|
||||
"/p:sld/p:timing/p:tnLst/p:par/p:cTn/p:childTnLst[1]/p:seq/p:cTn/p:childTnLst[1]/"
|
||||
"p:par[2]/p:cTn/p:childTnLst[1]/p:par/p:cTn/p:childTnLst[1]/p:par/p:cTn/"
|
||||
"p:endCondLst[not(*)]",
|
||||
"p:endCondLst[not(*)]"_ostr,
|
||||
0);
|
||||
}
|
||||
|
||||
@@ -641,7 +666,7 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf104786)
|
||||
assertXPath(pXmlDocContent,
|
||||
"/p:sld/p:timing/p:tnLst/p:par/p:cTn/p:childTnLst[1]/p:seq/p:cTn/p:childTnLst[1]/"
|
||||
"p:par[2]/p:cTn/p:childTnLst[1]/p:par/p:cTn/p:childTnLst[1]/p:par/p:cTn/"
|
||||
"p:childTnLst/p:set[2]/p:to",
|
||||
"p:childTnLst/p:set[2]/p:to"_ostr,
|
||||
0);
|
||||
}
|
||||
|
||||
@@ -652,7 +677,7 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf118783)
|
||||
|
||||
xmlDocUniquePtr pXmlDocContent = parseExport("ppt/slides/slide1.xml");
|
||||
OUString sAttributeName
|
||||
= getXPathContent(pXmlDocContent, "//p:animRot/p:cBhvr/p:attrNameLst/p:attrName");
|
||||
= getXPathContent(pXmlDocContent, "//p:animRot/p:cBhvr/p:attrNameLst/p:attrName"_ostr);
|
||||
CPPUNIT_ASSERT_EQUAL(OUString("r"), sAttributeName);
|
||||
}
|
||||
|
||||
@@ -665,7 +690,7 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf104789)
|
||||
OUString sAttributeName = getXPathContent(
|
||||
pXmlDocContent, "/p:sld/p:timing/p:tnLst/p:par/p:cTn/p:childTnLst/p:seq/p:cTn/p:childTnLst/"
|
||||
"p:par/p:cTn/p:childTnLst/p:par/p:cTn/p:childTnLst/p:par/p:cTn/"
|
||||
"p:childTnLst/p:set/p:cBhvr/p:attrNameLst/p:attrName");
|
||||
"p:childTnLst/p:set/p:cBhvr/p:attrNameLst/p:attrName"_ostr);
|
||||
CPPUNIT_ASSERT_EQUAL(OUString("style.opacity"), sAttributeName);
|
||||
}
|
||||
|
||||
@@ -689,23 +714,23 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf118835)
|
||||
save("Impress Office Open XML");
|
||||
|
||||
xmlDocUniquePtr pXmlDocContent = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDocContent, "(//p:animClr)[1]", "clrSpc", "rgb");
|
||||
assertXPathContent(pXmlDocContent, "(//p:animClr)[1]//p:attrName", "style.color");
|
||||
assertXPath(pXmlDocContent, "(//p:animClr)[1]//p:to/a:srgbClr", "val", "ed1c24");
|
||||
assertXPath(pXmlDocContent, "(//p:animClr)[1]"_ostr, "clrSpc"_ostr, "rgb");
|
||||
assertXPathContent(pXmlDocContent, "(//p:animClr)[1]//p:attrName"_ostr, "style.color");
|
||||
assertXPath(pXmlDocContent, "(//p:animClr)[1]//p:to/a:srgbClr"_ostr, "val"_ostr, "ed1c24");
|
||||
|
||||
assertXPath(pXmlDocContent, "(//p:animClr)[2]", "clrSpc", "rgb");
|
||||
assertXPathContent(pXmlDocContent, "(//p:animClr)[2]//p:attrName", "stroke.color");
|
||||
assertXPath(pXmlDocContent, "(//p:animClr)[2]//p:to/a:srgbClr", "val", "333399");
|
||||
assertXPath(pXmlDocContent, "(//p:animClr)[2]"_ostr, "clrSpc"_ostr, "rgb");
|
||||
assertXPathContent(pXmlDocContent, "(//p:animClr)[2]//p:attrName"_ostr, "stroke.color");
|
||||
assertXPath(pXmlDocContent, "(//p:animClr)[2]//p:to/a:srgbClr"_ostr, "val"_ostr, "333399");
|
||||
|
||||
assertXPath(pXmlDocContent, "(//p:animClr)[3]", "clrSpc", "rgb");
|
||||
assertXPathContent(pXmlDocContent, "(//p:animClr)[3]//p:attrName", "fillcolor");
|
||||
assertXPath(pXmlDocContent, "(//p:animClr)[3]//p:to/a:srgbClr", "val", "fcd3c1");
|
||||
assertXPath(pXmlDocContent, "(//p:animClr)[3]"_ostr, "clrSpc"_ostr, "rgb");
|
||||
assertXPathContent(pXmlDocContent, "(//p:animClr)[3]//p:attrName"_ostr, "fillcolor");
|
||||
assertXPath(pXmlDocContent, "(//p:animClr)[3]//p:to/a:srgbClr"_ostr, "val"_ostr, "fcd3c1");
|
||||
|
||||
assertXPath(pXmlDocContent, "(//p:animClr)[5]", "clrSpc", "hsl");
|
||||
assertXPathContent(pXmlDocContent, "(//p:animClr)[5]//p:attrName", "fillcolor");
|
||||
assertXPath(pXmlDocContent, "(//p:animClr)[5]//p:by/p:hsl", "h", "10800000");
|
||||
assertXPath(pXmlDocContent, "(//p:animClr)[5]//p:by/p:hsl", "s", "0");
|
||||
assertXPath(pXmlDocContent, "(//p:animClr)[5]//p:by/p:hsl", "l", "0");
|
||||
assertXPath(pXmlDocContent, "(//p:animClr)[5]"_ostr, "clrSpc"_ostr, "hsl");
|
||||
assertXPathContent(pXmlDocContent, "(//p:animClr)[5]//p:attrName"_ostr, "fillcolor");
|
||||
assertXPath(pXmlDocContent, "(//p:animClr)[5]//p:by/p:hsl"_ostr, "h"_ostr, "10800000");
|
||||
assertXPath(pXmlDocContent, "(//p:animClr)[5]//p:by/p:hsl"_ostr, "s"_ostr, "0");
|
||||
assertXPath(pXmlDocContent, "(//p:animClr)[5]//p:by/p:hsl"_ostr, "l"_ostr, "0");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf118768)
|
||||
@@ -714,15 +739,15 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf118768)
|
||||
save("Impress Office Open XML");
|
||||
|
||||
xmlDocUniquePtr pXmlDocContent = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDocContent, "//p:anim[1]", "from", "(-#ppt_w/2)");
|
||||
assertXPath(pXmlDocContent, "//p:anim[1]", "to", "(#ppt_x)");
|
||||
assertXPath(pXmlDocContent, "//p:anim[2]", "from", "0");
|
||||
assertXPath(pXmlDocContent, "//p:anim[1]"_ostr, "from"_ostr, "(-#ppt_w/2)");
|
||||
assertXPath(pXmlDocContent, "//p:anim[1]"_ostr, "to"_ostr, "(#ppt_x)");
|
||||
assertXPath(pXmlDocContent, "//p:anim[2]"_ostr, "from"_ostr, "0");
|
||||
|
||||
assertXPath(pXmlDocContent, "//p:anim[2]", "to", "-1");
|
||||
assertXPath(pXmlDocContent, "//p:anim[2]/p:cBhvr/p:cTn", "autoRev", "1");
|
||||
assertXPath(pXmlDocContent, "//p:anim[2]"_ostr, "to"_ostr, "-1");
|
||||
assertXPath(pXmlDocContent, "//p:anim[2]/p:cBhvr/p:cTn"_ostr, "autoRev"_ostr, "1");
|
||||
|
||||
assertXPath(pXmlDocContent, "//p:anim[3]", "by", "(#ppt_h/3+#ppt_w*0.1)");
|
||||
assertXPath(pXmlDocContent, "//p:anim[3]/p:cBhvr/p:cTn", "autoRev", "1");
|
||||
assertXPath(pXmlDocContent, "//p:anim[3]"_ostr, "by"_ostr, "(#ppt_h/3+#ppt_w*0.1)");
|
||||
assertXPath(pXmlDocContent, "//p:anim[3]/p:cBhvr/p:cTn"_ostr, "autoRev"_ostr, "1");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf118836)
|
||||
@@ -731,8 +756,8 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf118836)
|
||||
save("Impress Office Open XML");
|
||||
|
||||
xmlDocUniquePtr pXmlDocContent = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDocContent, "//p:animScale/p:by", "x", "250000");
|
||||
assertXPath(pXmlDocContent, "//p:animScale/p:by", "y", "250000");
|
||||
assertXPath(pXmlDocContent, "//p:animScale/p:by"_ostr, "x"_ostr, "250000");
|
||||
assertXPath(pXmlDocContent, "//p:animScale/p:by"_ostr, "y"_ostr, "250000");
|
||||
}
|
||||
|
||||
static double getAdjustmentValue(const uno::Reference<beans::XPropertySet>& xSet)
|
||||
@@ -820,9 +845,11 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf116350TextEffects)
|
||||
save("Impress Office Open XML");
|
||||
|
||||
xmlDocUniquePtr pXmlDocContent = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDocContent, "//p:sp[1]/p:txBody/a:bodyPr/a:prstTxWarp", "prst", "textArchUp");
|
||||
assertXPath(pXmlDocContent, "//p:sp[14]/p:txBody/a:bodyPr/a:prstTxWarp", "prst", "textCircle");
|
||||
assertXPath(pXmlDocContent, "//p:sp[14]/p:spPr/a:solidFill/a:srgbClr", 0);
|
||||
assertXPath(pXmlDocContent, "//p:sp[1]/p:txBody/a:bodyPr/a:prstTxWarp"_ostr, "prst"_ostr,
|
||||
"textArchUp");
|
||||
assertXPath(pXmlDocContent, "//p:sp[14]/p:txBody/a:bodyPr/a:prstTxWarp"_ostr, "prst"_ostr,
|
||||
"textCircle");
|
||||
assertXPath(pXmlDocContent, "//p:sp[14]/p:spPr/a:solidFill/a:srgbClr"_ostr, 0);
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf128096)
|
||||
@@ -832,14 +859,14 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf128096)
|
||||
|
||||
xmlDocUniquePtr pXmlDocContent1 = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDocContent1,
|
||||
"//p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p/a:r/a:rPr/a:highlight/a:srgbClr", "val",
|
||||
"ffff00");
|
||||
"//p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p/a:r/a:rPr/a:highlight/a:srgbClr"_ostr,
|
||||
"val"_ostr, "ffff00");
|
||||
|
||||
// Check that underlined content is also highlighted
|
||||
xmlDocUniquePtr pXmlDocContent2 = parseExport("ppt/slides/slide2.xml");
|
||||
assertXPath(pXmlDocContent2,
|
||||
"//p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p/a:r/a:rPr/a:highlight/a:srgbClr", "val",
|
||||
"ffff00");
|
||||
"//p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p/a:r/a:rPr/a:highlight/a:srgbClr"_ostr,
|
||||
"val"_ostr, "ffff00");
|
||||
}
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf120573)
|
||||
{
|
||||
@@ -847,18 +874,19 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf120573)
|
||||
save("Impress Office Open XML");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDoc, "//p:sld/p:cSld/p:spTree/p:pic/p:nvPicPr/p:nvPr/a:audioFile", 1);
|
||||
assertXPath(pXmlDoc, "//p:sld/p:cSld/p:spTree/p:pic/p:nvPicPr/p:nvPr/a:videoFile", 0);
|
||||
assertXPath(pXmlDoc, "//p:sld/p:cSld/p:spTree/p:pic/p:nvPicPr/p:nvPr/a:audioFile"_ostr, 1);
|
||||
assertXPath(pXmlDoc, "//p:sld/p:cSld/p:spTree/p:pic/p:nvPicPr/p:nvPr/a:videoFile"_ostr, 0);
|
||||
|
||||
xmlDocUniquePtr pXmlDocRels = parseExport("ppt/slides/_rels/slide1.xml.rels");
|
||||
assertXPath(pXmlDocRels,
|
||||
"(/rels:Relationships/rels:Relationship[@Target='../media/media1.wav'])[1]", "Type",
|
||||
"(/rels:Relationships/rels:Relationship[@Target='../media/media1.wav'])[1]"_ostr,
|
||||
"Type"_ostr,
|
||||
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/audio");
|
||||
|
||||
xmlDocUniquePtr pXmlContentType = parseExport("[Content_Types].xml");
|
||||
assertXPath(pXmlContentType,
|
||||
"/ContentType:Types/ContentType:Override[@PartName='/ppt/media/media1.wav']",
|
||||
"ContentType", "audio/x-wav");
|
||||
"/ContentType:Types/ContentType:Override[@PartName='/ppt/media/media1.wav']"_ostr,
|
||||
"ContentType"_ostr, "audio/x-wav");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf119118)
|
||||
@@ -866,8 +894,8 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf119118)
|
||||
createSdImpressDoc("pptx/tdf119118.pptx");
|
||||
save("Impress Office Open XML");
|
||||
xmlDocUniquePtr pXmlDocContent = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDocContent, "//p:iterate", "type", "lt");
|
||||
assertXPath(pXmlDocContent, "//p:tmAbs", "val", "200");
|
||||
assertXPath(pXmlDocContent, "//p:iterate"_ostr, "type"_ostr, "lt");
|
||||
assertXPath(pXmlDocContent, "//p:tmAbs"_ostr, "val"_ostr, "200");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf99213)
|
||||
@@ -876,9 +904,9 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf99213)
|
||||
save("Impress Office Open XML");
|
||||
xmlDocUniquePtr pXmlDocContent = parseExport("ppt/slides/slide1.xml");
|
||||
// Number of nodes with p:attrNameLst was 3, including one that missed tgtEl
|
||||
assertXPath(pXmlDocContent, "//p:attrNameLst", 2);
|
||||
assertXPath(pXmlDocContent, "//p:attrNameLst"_ostr, 2);
|
||||
// Timenode that miss its target element should be filtered.
|
||||
assertXPath(pXmlDocContent, "//p:attrNameLst/preceding-sibling::p:tgtEl", 2);
|
||||
assertXPath(pXmlDocContent, "//p:attrNameLst/preceding-sibling::p:tgtEl"_ostr, 2);
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testPotxExport)
|
||||
@@ -893,8 +921,8 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testPotxExport)
|
||||
xmlDocUniquePtr pContentTypes = parseExport("[Content_Types].xml");
|
||||
CPPUNIT_ASSERT(pContentTypes);
|
||||
assertXPath(pContentTypes,
|
||||
"/ContentType:Types/ContentType:Override[@PartName='/ppt/presentation.xml']",
|
||||
"ContentType",
|
||||
"/ContentType:Types/ContentType:Override[@PartName='/ppt/presentation.xml']"_ostr,
|
||||
"ContentType"_ostr,
|
||||
"application/vnd.openxmlformats-officedocument.presentationml.template.main+xml");
|
||||
}
|
||||
|
||||
@@ -913,31 +941,33 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf44223)
|
||||
|
||||
xmlDocUniquePtr pXmlContentType = parseExport("[Content_Types].xml");
|
||||
assertXPath(pXmlContentType,
|
||||
"/ContentType:Types/ContentType:Override[@PartName='/ppt/media/audio1.wav']",
|
||||
"ContentType", "audio/x-wav");
|
||||
"/ContentType:Types/ContentType:Override[@PartName='/ppt/media/audio1.wav']"_ostr,
|
||||
"ContentType"_ostr, "audio/x-wav");
|
||||
|
||||
assertXPath(pXmlContentType,
|
||||
"/ContentType:Types/ContentType:Override[@PartName='/ppt/media/audio2.wav']",
|
||||
"ContentType", "audio/x-wav");
|
||||
"/ContentType:Types/ContentType:Override[@PartName='/ppt/media/audio2.wav']"_ostr,
|
||||
"ContentType"_ostr, "audio/x-wav");
|
||||
|
||||
xmlDocUniquePtr pDoc1 = parseExport("ppt/slides/slide1.xml");
|
||||
|
||||
// tdf#124230 all nodes were under p:childTnLst, but event triggered nodes need
|
||||
// to be under p:subTnLst, especially for audio to work correctly.
|
||||
// Start condition: 0s after timenode id 5 begins.
|
||||
assertXPath(pDoc1, "//p:subTnLst/p:audio/p:cMediaNode/p:cTn/p:stCondLst/p:cond", "evt",
|
||||
"begin");
|
||||
assertXPath(pDoc1, "//p:subTnLst/p:audio/p:cMediaNode/p:cTn/p:stCondLst/p:cond", "delay", "0");
|
||||
assertXPath(pDoc1, "//p:subTnLst/p:audio/p:cMediaNode/p:cTn/p:stCondLst/p:cond/p:tn", "val",
|
||||
"5");
|
||||
assertXPath(pDoc1, "//p:subTnLst/p:audio/p:cMediaNode/p:cTn/p:stCondLst/p:cond"_ostr,
|
||||
"evt"_ostr, "begin");
|
||||
assertXPath(pDoc1, "//p:subTnLst/p:audio/p:cMediaNode/p:cTn/p:stCondLst/p:cond"_ostr,
|
||||
"delay"_ostr, "0");
|
||||
assertXPath(pDoc1, "//p:subTnLst/p:audio/p:cMediaNode/p:cTn/p:stCondLst/p:cond/p:tn"_ostr,
|
||||
"val"_ostr, "5");
|
||||
|
||||
xmlDocUniquePtr pDoc2 = parseExport("ppt/slides/slide2.xml");
|
||||
assertXPath(pDoc2, "//p:transition/p:sndAc/p:stSnd/p:snd[@r:embed]", 2);
|
||||
assertXPath(pDoc2, "//p:transition/p:sndAc/p:stSnd/p:snd[@r:embed]"_ostr, 2);
|
||||
|
||||
xmlDocUniquePtr pRels1 = parseExport("ppt/slides/_rels/slide1.xml.rels");
|
||||
assertXPath(pRels1, "//rels:Relationship[@Id='rId1']", "Type",
|
||||
assertXPath(pRels1, "//rels:Relationship[@Id='rId1']"_ostr, "Type"_ostr,
|
||||
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/audio");
|
||||
assertXPath(pRels1, "//rels:Relationship[@Id='rId1']", "Target", "../media/audio1.wav");
|
||||
assertXPath(pRels1, "//rels:Relationship[@Id='rId1']"_ostr, "Target"_ostr,
|
||||
"../media/audio1.wav");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest3, testTdf135843)
|
||||
|
||||
@@ -43,49 +43,57 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testSmartArtPreserve)
|
||||
save("Impress Office Open XML");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDoc, "//p:sld/p:cSld/p:spTree/p:graphicFrame/p:nvGraphicFramePr/p:cNvPr");
|
||||
assertXPath(pXmlDoc, "//p:sld/p:cSld/p:spTree/p:graphicFrame/p:nvGraphicFramePr/p:cNvPr"_ostr);
|
||||
assertXPath(pXmlDoc,
|
||||
"//p:sld/p:cSld/p:spTree/p:graphicFrame/a:graphic/a:graphicData/dgm:relIds");
|
||||
assertXPath(pXmlDoc,
|
||||
"//p:sld/p:cSld/p:spTree/p:graphicFrame/p:nvGraphicFramePr/p:nvPr/p:extLst/p:ext",
|
||||
"uri", "{D42A27DB-BD31-4B8C-83A1-F6EECF244321}");
|
||||
"//p:sld/p:cSld/p:spTree/p:graphicFrame/a:graphic/a:graphicData/dgm:relIds"_ostr);
|
||||
assertXPath(
|
||||
pXmlDoc,
|
||||
"//p:sld/p:cSld/p:spTree/p:graphicFrame/p:nvGraphicFramePr/p:nvPr/p:extLst/p:ext"_ostr,
|
||||
"uri"_ostr, "{D42A27DB-BD31-4B8C-83A1-F6EECF244321}");
|
||||
assertXPath(pXmlDoc, "//p:sld/p:cSld/p:spTree/p:graphicFrame/p:nvGraphicFramePr/p:nvPr/"
|
||||
"p:extLst/p:ext/p14:modId");
|
||||
"p:extLst/p:ext/p14:modId"_ostr);
|
||||
|
||||
xmlDocUniquePtr pXmlDocRels = parseExport("ppt/slides/_rels/slide1.xml.rels");
|
||||
assertXPath(
|
||||
pXmlDocRels,
|
||||
"(/rels:Relationships/rels:Relationship[@Target='../diagrams/layout1.xml'])[1]", "Type",
|
||||
"(/rels:Relationships/rels:Relationship[@Target='../diagrams/layout1.xml'])[1]"_ostr,
|
||||
"Type"_ostr,
|
||||
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/diagramLayout");
|
||||
assertXPath(
|
||||
pXmlDocRels, "(/rels:Relationships/rels:Relationship[@Target='../diagrams/data1.xml'])[1]",
|
||||
"Type", "http://schemas.openxmlformats.org/officeDocument/2006/relationships/diagramData");
|
||||
assertXPath(pXmlDocRels,
|
||||
"(/rels:Relationships/rels:Relationship[@Target='../diagrams/data1.xml'])[1]"_ostr,
|
||||
"Type"_ostr,
|
||||
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/diagramData");
|
||||
assertXPath(
|
||||
pXmlDocRels,
|
||||
"(/rels:Relationships/rels:Relationship[@Target='../diagrams/colors1.xml'])[1]", "Type",
|
||||
"(/rels:Relationships/rels:Relationship[@Target='../diagrams/colors1.xml'])[1]"_ostr,
|
||||
"Type"_ostr,
|
||||
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/diagramColors");
|
||||
assertXPath(
|
||||
pXmlDocRels,
|
||||
"(/rels:Relationships/rels:Relationship[@Target='../diagrams/quickStyle1.xml'])[1]", "Type",
|
||||
"(/rels:Relationships/rels:Relationship[@Target='../diagrams/quickStyle1.xml'])[1]"_ostr,
|
||||
"Type"_ostr,
|
||||
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/diagramQuickStyle");
|
||||
|
||||
xmlDocUniquePtr pXmlContentType = parseExport("[Content_Types].xml");
|
||||
assertXPath(pXmlContentType,
|
||||
"/ContentType:Types/ContentType:Override[@PartName='/ppt/diagrams/layout1.xml']",
|
||||
"ContentType",
|
||||
"application/vnd.openxmlformats-officedocument.drawingml.diagramLayout+xml");
|
||||
assertXPath(pXmlContentType,
|
||||
"/ContentType:Types/ContentType:Override[@PartName='/ppt/diagrams/data1.xml']",
|
||||
"ContentType",
|
||||
"application/vnd.openxmlformats-officedocument.drawingml.diagramData+xml");
|
||||
assertXPath(pXmlContentType,
|
||||
"/ContentType:Types/ContentType:Override[@PartName='/ppt/diagrams/colors1.xml']",
|
||||
"ContentType",
|
||||
"application/vnd.openxmlformats-officedocument.drawingml.diagramColors+xml");
|
||||
assertXPath(
|
||||
pXmlContentType,
|
||||
"/ContentType:Types/ContentType:Override[@PartName='/ppt/diagrams/quickStyle1.xml']",
|
||||
"ContentType", "application/vnd.openxmlformats-officedocument.drawingml.diagramStyle+xml");
|
||||
"/ContentType:Types/ContentType:Override[@PartName='/ppt/diagrams/layout1.xml']"_ostr,
|
||||
"ContentType"_ostr,
|
||||
"application/vnd.openxmlformats-officedocument.drawingml.diagramLayout+xml");
|
||||
assertXPath(pXmlContentType,
|
||||
"/ContentType:Types/ContentType:Override[@PartName='/ppt/diagrams/data1.xml']"_ostr,
|
||||
"ContentType"_ostr,
|
||||
"application/vnd.openxmlformats-officedocument.drawingml.diagramData+xml");
|
||||
assertXPath(
|
||||
pXmlContentType,
|
||||
"/ContentType:Types/ContentType:Override[@PartName='/ppt/diagrams/colors1.xml']"_ostr,
|
||||
"ContentType"_ostr,
|
||||
"application/vnd.openxmlformats-officedocument.drawingml.diagramColors+xml");
|
||||
assertXPath(
|
||||
pXmlContentType,
|
||||
"/ContentType:Types/ContentType:Override[@PartName='/ppt/diagrams/quickStyle1.xml']"_ostr,
|
||||
"ContentType"_ostr,
|
||||
"application/vnd.openxmlformats-officedocument.drawingml.diagramStyle+xml");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTdf125346)
|
||||
@@ -365,7 +373,8 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTdf128213)
|
||||
save("Impress Office Open XML");
|
||||
|
||||
xmlDocUniquePtr pXmlDocContent = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPathNoAttribute(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:sp/p:spPr/a:xfrm", "rot");
|
||||
assertXPathNoAttribute(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:sp/p:spPr/a:xfrm"_ostr,
|
||||
"rot"_ostr);
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTdf79082)
|
||||
@@ -375,36 +384,39 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTdf79082)
|
||||
|
||||
xmlDocUniquePtr pXmlDocContent = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDocContent,
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p/a:pPr/a:tabLst/a:tab[1]", "pos",
|
||||
"360000");
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p/a:pPr/a:tabLst/a:tab[1]"_ostr,
|
||||
"pos"_ostr, "360000");
|
||||
assertXPath(pXmlDocContent,
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p/a:pPr/a:tabLst/a:tab[1]", "algn", "l");
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p/a:pPr/a:tabLst/a:tab[1]"_ostr,
|
||||
"algn"_ostr, "l");
|
||||
|
||||
assertXPath(pXmlDocContent,
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p/a:pPr/a:tabLst/a:tab[2]", "pos",
|
||||
"756000");
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p/a:pPr/a:tabLst/a:tab[2]"_ostr,
|
||||
"pos"_ostr, "756000");
|
||||
assertXPath(pXmlDocContent,
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p/a:pPr/a:tabLst/a:tab[2]", "algn", "l");
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p/a:pPr/a:tabLst/a:tab[2]"_ostr,
|
||||
"algn"_ostr, "l");
|
||||
|
||||
assertXPath(pXmlDocContent,
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p/a:pPr/a:tabLst/a:tab[3]", "pos",
|
||||
"1440000");
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p/a:pPr/a:tabLst/a:tab[3]"_ostr,
|
||||
"pos"_ostr, "1440000");
|
||||
assertXPath(pXmlDocContent,
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p/a:pPr/a:tabLst/a:tab[3]", "algn",
|
||||
"ctr");
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p/a:pPr/a:tabLst/a:tab[3]"_ostr,
|
||||
"algn"_ostr, "ctr");
|
||||
|
||||
assertXPath(pXmlDocContent,
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p/a:pPr/a:tabLst/a:tab[4]", "pos",
|
||||
"1800000");
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p/a:pPr/a:tabLst/a:tab[4]"_ostr,
|
||||
"pos"_ostr, "1800000");
|
||||
assertXPath(pXmlDocContent,
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p/a:pPr/a:tabLst/a:tab[4]", "algn", "r");
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p/a:pPr/a:tabLst/a:tab[4]"_ostr,
|
||||
"algn"_ostr, "r");
|
||||
|
||||
assertXPath(pXmlDocContent,
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p/a:pPr/a:tabLst/a:tab[5]", "pos",
|
||||
"3240000");
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p/a:pPr/a:tabLst/a:tab[5]"_ostr,
|
||||
"pos"_ostr, "3240000");
|
||||
assertXPath(pXmlDocContent,
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p/a:pPr/a:tabLst/a:tab[5]", "algn",
|
||||
"dec");
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p/a:pPr/a:tabLst/a:tab[5]"_ostr,
|
||||
"algn"_ostr, "dec");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTdf129372)
|
||||
@@ -517,14 +529,15 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTdf132201EffectOrder)
|
||||
createSdImpressDoc("pptx/effectOrder.pptx");
|
||||
save("Impress Office Open XML");
|
||||
xmlDocUniquePtr pXmlDocContent = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPathChildren(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:sp[3]/p:spPr/a:effectLst", 2);
|
||||
assertXPathChildren(pXmlDocContent, "/p:sld/p:cSld/p:spTree/p:sp[3]/p:spPr/a:effectLst"_ostr,
|
||||
2);
|
||||
// The relative order of effects is important: glow must be before shadow
|
||||
CPPUNIT_ASSERT_EQUAL(0, getXPathPosition(pXmlDocContent,
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[3]/p:spPr/a:effectLst",
|
||||
"glow"));
|
||||
CPPUNIT_ASSERT_EQUAL(1, getXPathPosition(pXmlDocContent,
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[3]/p:spPr/a:effectLst",
|
||||
"outerShdw"));
|
||||
CPPUNIT_ASSERT_EQUAL(
|
||||
0, getXPathPosition(pXmlDocContent,
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[3]/p:spPr/a:effectLst"_ostr, "glow"));
|
||||
CPPUNIT_ASSERT_EQUAL(
|
||||
1, getXPathPosition(pXmlDocContent,
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[3]/p:spPr/a:effectLst"_ostr, "outerShdw"));
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testShapeSoftEdgeEffect)
|
||||
@@ -556,19 +569,19 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTdf119223)
|
||||
save("Impress Office Open XML");
|
||||
|
||||
xmlDocUniquePtr pXmlDocRels = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDocRels, "//p:cNvPr[@name='SomeCustomShape']");
|
||||
assertXPath(pXmlDocRels, "//p:cNvPr[@name='SomeCustomShape']"_ostr);
|
||||
|
||||
assertXPath(pXmlDocRels, "//p:cNvPr[@name='SomePicture']");
|
||||
assertXPath(pXmlDocRels, "//p:cNvPr[@name='SomePicture']"_ostr);
|
||||
|
||||
assertXPath(pXmlDocRels, "//p:cNvPr[@name='SomeFormula']");
|
||||
assertXPath(pXmlDocRels, "//p:cNvPr[@name='SomeFormula']"_ostr);
|
||||
|
||||
assertXPath(pXmlDocRels, "//p:cNvPr[@name='SomeLine']");
|
||||
assertXPath(pXmlDocRels, "//p:cNvPr[@name='SomeLine']"_ostr);
|
||||
|
||||
assertXPath(pXmlDocRels, "//p:cNvPr[@name='SomeTextbox']");
|
||||
assertXPath(pXmlDocRels, "//p:cNvPr[@name='SomeTextbox']"_ostr);
|
||||
|
||||
assertXPath(pXmlDocRels, "//p:cNvPr[@name='SomeTable']");
|
||||
assertXPath(pXmlDocRels, "//p:cNvPr[@name='SomeTable']"_ostr);
|
||||
|
||||
assertXPath(pXmlDocRels, "//p:cNvPr[@name='SomeGroup']");
|
||||
assertXPath(pXmlDocRels, "//p:cNvPr[@name='SomeGroup']"_ostr);
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTdf128213ShapeRot)
|
||||
@@ -578,10 +591,10 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTdf128213ShapeRot)
|
||||
|
||||
xmlDocUniquePtr pXmlDocRels = parseExport("ppt/slides/slide1.xml");
|
||||
|
||||
assertXPath(pXmlDocRels, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:bodyPr/a:scene3d");
|
||||
assertXPath(pXmlDocRels, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:bodyPr/a:scene3d"_ostr);
|
||||
assertXPath(pXmlDocRels,
|
||||
"/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:bodyPr/a:scene3d/a:camera/a:rot", "rev",
|
||||
"5400000");
|
||||
"/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:bodyPr/a:scene3d/a:camera/a:rot"_ostr,
|
||||
"rev"_ostr, "5400000");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTdf125560_textDeflate)
|
||||
@@ -594,8 +607,8 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTdf125560_textDeflate)
|
||||
xmlDocUniquePtr pXmlDocRels = parseExport("content.xml");
|
||||
assertXPath(pXmlDocRels,
|
||||
"/office:document-content/office:body/office:presentation/draw:page/"
|
||||
"draw:custom-shape/draw:enhanced-geometry",
|
||||
"type", "mso-spt161");
|
||||
"draw:custom-shape/draw:enhanced-geometry"_ostr,
|
||||
"type"_ostr, "mso-spt161");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTdf125560_textInflateTop)
|
||||
@@ -608,8 +621,8 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTdf125560_textInflateTop)
|
||||
xmlDocUniquePtr pXmlDocRels = parseExport("content.xml");
|
||||
assertXPath(pXmlDocRels,
|
||||
"/office:document-content/office:body/office:presentation/draw:page/"
|
||||
"draw:custom-shape/draw:enhanced-geometry",
|
||||
"type", "mso-spt164");
|
||||
"draw:custom-shape/draw:enhanced-geometry"_ostr,
|
||||
"type"_ostr, "mso-spt164");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTdf142235_TestPlaceholderTextAlignment)
|
||||
@@ -623,8 +636,8 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTdf142235_TestPlaceholderTextAlignm
|
||||
|
||||
// Without the fix in place many of these asserts failed, because alignment was bad.
|
||||
|
||||
assertXPath(pXml1, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:bodyPr", "anchor", "t");
|
||||
assertXPath(pXml2, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:bodyPr", "anchor", "t");
|
||||
assertXPath(pXml1, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:bodyPr"_ostr, "anchor"_ostr, "t");
|
||||
assertXPath(pXml2, "/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:bodyPr"_ostr, "anchor"_ostr, "t");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTdf96061_textHighlight)
|
||||
@@ -700,12 +713,14 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTdf143315)
|
||||
// - Actual : 216000
|
||||
// - In <file:///tmp/lu161922zcvd.tmp>, XPath '/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p/a:pPr' unexpected 'marL' attribute
|
||||
|
||||
assertXPathNoAttribute(pXml, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p/a:pPr", "marL");
|
||||
assertXPathNoAttribute(pXml, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p/a:pPr", "indent");
|
||||
assertXPath(pXml, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p/a:pPr/a:buClr", 0);
|
||||
assertXPath(pXml, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p/a:pPr/a:buSzPct", 0);
|
||||
assertXPath(pXml, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p/a:pPr/a:buFont", 0);
|
||||
assertXPath(pXml, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p/a:pPr/a:buChar", 0);
|
||||
assertXPathNoAttribute(pXml, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p/a:pPr"_ostr,
|
||||
"marL"_ostr);
|
||||
assertXPathNoAttribute(pXml, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p/a:pPr"_ostr,
|
||||
"indent"_ostr);
|
||||
assertXPath(pXml, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p/a:pPr/a:buClr"_ostr, 0);
|
||||
assertXPath(pXml, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p/a:pPr/a:buSzPct"_ostr, 0);
|
||||
assertXPath(pXml, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p/a:pPr/a:buFont"_ostr, 0);
|
||||
assertXPath(pXml, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p/a:pPr/a:buChar"_ostr, 0);
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTdf147121)
|
||||
@@ -727,7 +742,8 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTdf147121)
|
||||
// Parse the export
|
||||
xmlDocUniquePtr pXml = parseExport("ppt/slides/slide1.xml");
|
||||
const auto nFontSizeAfter
|
||||
= getXPath(pXml, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p/a:br[1]/a:rPr", "sz").toFloat();
|
||||
= getXPath(pXml, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p/a:br[1]/a:rPr"_ostr, "sz"_ostr)
|
||||
.toFloat();
|
||||
|
||||
// The font size was not saved before now it must be equal with the saved one.
|
||||
CPPUNIT_ASSERT_EQUAL_MESSAGE("Unexpected font size", nFontSizeBefore, nFontSizeAfter);
|
||||
@@ -876,7 +892,7 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTdf149551_tbrl90)
|
||||
// Test, that it is exported to vert="vert"
|
||||
save("Impress Office Open XML");
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDoc, "//a:bodyPr", "vert", "vert");
|
||||
assertXPath(pXmlDoc, "//a:bodyPr"_ostr, "vert"_ostr, "vert");
|
||||
|
||||
// Test, that the shape has writing mode TB_RL90 after read from pptx
|
||||
uno::Reference<beans::XPropertySet> xShapeProps2(getShapeFromPage(0, 0));
|
||||
@@ -889,7 +905,7 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTdf149551_tbrl90)
|
||||
pXmlDoc = parseExport("content.xml");
|
||||
assertXPath(
|
||||
pXmlDoc,
|
||||
"//style:style[@style:name='gr1']/style:graphic-properties[@loext:writing-mode='tb-rl90']");
|
||||
"//style:style[@style:name='gr1']/style:graphic-properties[@loext:writing-mode='tb-rl90']"_ostr);
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTdf149551_btlr)
|
||||
@@ -908,7 +924,7 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTdf149551_btlr)
|
||||
// Test, that it is exported to vert="vert270"
|
||||
save("Impress Office Open XML");
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDoc, "//a:bodyPr", "vert", "vert270");
|
||||
assertXPath(pXmlDoc, "//a:bodyPr"_ostr, "vert"_ostr, "vert270");
|
||||
|
||||
// Test, that the shape has writing mode BT_LR after read from pptx
|
||||
uno::Reference<beans::XPropertySet> xShapeProps2(getShapeFromPage(0, 0));
|
||||
@@ -921,7 +937,7 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTdf149551_btlr)
|
||||
pXmlDoc = parseExport("content.xml");
|
||||
assertXPath(
|
||||
pXmlDoc,
|
||||
"//style:style[@style:name='gr1']/style:graphic-properties[@loext:writing-mode='bt-lr']");
|
||||
"//style:style[@style:name='gr1']/style:graphic-properties[@loext:writing-mode='bt-lr']"_ostr);
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTdf94122_autoColor)
|
||||
@@ -945,21 +961,21 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTdf94122_autoColor)
|
||||
|
||||
xmlDocUniquePtr pXmlDocContent1 = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDocContent1,
|
||||
"/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p/a:r/a:rPr/a:solidFill/a:srgbClr", "val",
|
||||
"000000");
|
||||
"/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p/a:r/a:rPr/a:solidFill/a:srgbClr"_ostr,
|
||||
"val"_ostr, "000000");
|
||||
|
||||
xmlDocUniquePtr pXmlDocContent2 = parseExport("ppt/slides/slide2.xml");
|
||||
assertXPath(pXmlDocContent2,
|
||||
"/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p/a:r/a:rPr/a:solidFill/a:srgbClr", "val",
|
||||
"ffffff");
|
||||
"/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p/a:r/a:rPr/a:solidFill/a:srgbClr"_ostr,
|
||||
"val"_ostr, "ffffff");
|
||||
|
||||
xmlDocUniquePtr pXmlDocContent3 = parseExport("ppt/slides/slide3.xml");
|
||||
assertXPath(pXmlDocContent3,
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[1]/p:txBody/a:p/a:r/a:rPr/a:solidFill/a:srgbClr",
|
||||
"val", "ffffff");
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[1]/p:txBody/a:p/a:r/a:rPr/a:solidFill/a:srgbClr"_ostr,
|
||||
"val"_ostr, "ffffff");
|
||||
assertXPath(pXmlDocContent3,
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p/a:r/a:rPr/a:solidFill/a:srgbClr",
|
||||
"val", "000000");
|
||||
"/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p/a:r/a:rPr/a:solidFill/a:srgbClr"_ostr,
|
||||
"val"_ostr, "000000");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTdf124333)
|
||||
@@ -989,8 +1005,8 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testAutofittedTextboxIndent)
|
||||
// (the behaviour changed).
|
||||
|
||||
xmlDocUniquePtr pXmlDocContent1 = parseExport("ppt/slides/slide1.xml");
|
||||
assertXPath(pXmlDocContent1, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p[1]/a:pPr", "marL",
|
||||
"1080000");
|
||||
assertXPath(pXmlDocContent1, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p[1]/a:pPr"_ostr,
|
||||
"marL"_ostr, "1080000");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTdf151622_oleIcon)
|
||||
@@ -1005,7 +1021,7 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTdf151622_oleIcon)
|
||||
// - Expression: prop
|
||||
// - In ..., XPath '//p:oleObj' no attribute 'showAsIcon' exist
|
||||
// i.e. show as icon option wasn't exported.
|
||||
assertXPath(pXml, "//p:oleObj", "showAsIcon", "1");
|
||||
assertXPath(pXml, "//p:oleObj"_ostr, "showAsIcon"_ostr, "1");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTdf152436)
|
||||
@@ -1030,7 +1046,7 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testLinkedOLE)
|
||||
// - Actual : 0
|
||||
// - In<>, XPath '//p:oleObj' number of nodes is incorrect
|
||||
// i.e. the linked ole object wasn't exported.
|
||||
assertXPath(pXml, "//p:oleObj", 1);
|
||||
assertXPath(pXml, "//p:oleObj"_ostr, 1);
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTdf102261_testParaTabStopDefaultDistance)
|
||||
@@ -1062,9 +1078,9 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTableCellVerticalPropertyRoundtrip)
|
||||
|
||||
xmlDocUniquePtr pXml = parseExport("ppt/slides/slide1.xml");
|
||||
|
||||
assertXPath(pXml, "(//a:tcPr)[1]", "vert", "vert");
|
||||
assertXPath(pXml, "(//a:tcPr)[2]", "vert", "vert270");
|
||||
assertXPath(pXml, "(//a:tcPr)[3]", "vert", "wordArtVert");
|
||||
assertXPath(pXml, "(//a:tcPr)[1]"_ostr, "vert"_ostr, "vert");
|
||||
assertXPath(pXml, "(//a:tcPr)[2]"_ostr, "vert"_ostr, "vert270");
|
||||
assertXPath(pXml, "(//a:tcPr)[3]"_ostr, "vert"_ostr, "wordArtVert");
|
||||
}
|
||||
|
||||
CPPUNIT_PLUGIN_IMPLEMENT();
|
||||
|
||||
+110
-107
@@ -205,16 +205,16 @@ CPPUNIT_TEST_FIXTURE(SdExportTest, testDecorative)
|
||||
|
||||
auto doTest = [this](OString const test) {
|
||||
::std::set<OString> const decorative = {
|
||||
"Picture 6",
|
||||
"Rectangle 7",
|
||||
"Group 24",
|
||||
"Connector: Elbow 9",
|
||||
"Connector: Elbow 11",
|
||||
"Connector: Elbow 14",
|
||||
"Connector: Elbow 17",
|
||||
"Straight Arrow Connector 21",
|
||||
"Straight Arrow Connector 22",
|
||||
"Straight Arrow Connector 23",
|
||||
"Picture 6"_ostr,
|
||||
"Rectangle 7"_ostr,
|
||||
"Group 24"_ostr,
|
||||
"Connector: Elbow 9"_ostr,
|
||||
"Connector: Elbow 11"_ostr,
|
||||
"Connector: Elbow 14"_ostr,
|
||||
"Connector: Elbow 17"_ostr,
|
||||
"Straight Arrow Connector 21"_ostr,
|
||||
"Straight Arrow Connector 22"_ostr,
|
||||
"Straight Arrow Connector 23"_ostr,
|
||||
};
|
||||
|
||||
uno::Reference<drawing::XDrawPage> const xPage(getPage(0));
|
||||
@@ -276,13 +276,13 @@ CPPUNIT_TEST_FIXTURE(SdExportTest, testDecorative)
|
||||
nInnerShapes);
|
||||
};
|
||||
|
||||
doTest("initial pptx load: ");
|
||||
doTest("initial pptx load: "_ostr);
|
||||
|
||||
saveAndReload("Impress Office Open XML");
|
||||
doTest("reload OOXML: ");
|
||||
doTest("reload OOXML: "_ostr);
|
||||
|
||||
saveAndReload("impress8");
|
||||
doTest("reload ODF: ");
|
||||
doTest("reload ODF: "_ostr);
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdExportTest, testTdf142716)
|
||||
@@ -323,71 +323,73 @@ CPPUNIT_TEST_FIXTURE(SdExportTest, testFillBitmapUnused)
|
||||
// shapes
|
||||
assertXPath(
|
||||
pXmlDoc,
|
||||
"//style:style[@style:family='graphic']/style:graphic-properties[@draw:fill='bitmap']", 1);
|
||||
"//style:style[@style:family='graphic']/style:graphic-properties[@draw:fill='bitmap']"_ostr,
|
||||
1);
|
||||
assertXPath(
|
||||
pXmlDoc,
|
||||
"//style:style[@style:family='graphic']/style:graphic-properties[@draw:fill='bitmap']",
|
||||
"fill-image-name", "nav_5f_up");
|
||||
"//style:style[@style:family='graphic']/style:graphic-properties[@draw:fill='bitmap']"_ostr,
|
||||
"fill-image-name"_ostr, "nav_5f_up");
|
||||
assertXPath(
|
||||
pXmlDoc,
|
||||
"//style:style[@style:family='graphic']/style:graphic-properties[@draw:fill='solid']", 1);
|
||||
"//style:style[@style:family='graphic']/style:graphic-properties[@draw:fill='solid']"_ostr,
|
||||
1);
|
||||
assertXPath(pXmlDoc,
|
||||
"//style:style[@style:family='graphic']/"
|
||||
"style:graphic-properties[@draw:fill='solid' and @draw:fill-image-name]",
|
||||
"style:graphic-properties[@draw:fill='solid' and @draw:fill-image-name]"_ostr,
|
||||
0);
|
||||
assertXPath(
|
||||
pXmlDoc,
|
||||
"//style:style[@style:family='graphic']/style:graphic-properties[@draw:fill='solid']",
|
||||
"fill-color", "#808080");
|
||||
"//style:style[@style:family='graphic']/style:graphic-properties[@draw:fill='solid']"_ostr,
|
||||
"fill-color"_ostr, "#808080");
|
||||
|
||||
xmlDocUniquePtr pStyles = parseExport("styles.xml");
|
||||
// master slide presentation style
|
||||
assertXPath(pStyles,
|
||||
"/office:document-styles/office:styles/style:style[@style:family='presentation' "
|
||||
"and @style:name='Default-background']/style:graphic-properties",
|
||||
"fill", "bitmap");
|
||||
"and @style:name='Default-background']/style:graphic-properties"_ostr,
|
||||
"fill"_ostr, "bitmap");
|
||||
assertXPath(pStyles,
|
||||
"/office:document-styles/office:styles/style:style[@style:family='presentation' "
|
||||
"and @style:name='Default-background']/style:graphic-properties",
|
||||
"fill-image-name", "nav_5f_up");
|
||||
"and @style:name='Default-background']/style:graphic-properties"_ostr,
|
||||
"fill-image-name"_ostr, "nav_5f_up");
|
||||
assertXPath(pStyles,
|
||||
"/office:document-styles/office:styles/style:style[@style:family='presentation' "
|
||||
"and @style:name='Default_20_1-background']/style:graphic-properties",
|
||||
"fill", "solid");
|
||||
"and @style:name='Default_20_1-background']/style:graphic-properties"_ostr,
|
||||
"fill"_ostr, "solid");
|
||||
assertXPath(pStyles,
|
||||
"/office:document-styles/office:styles/style:style[@style:family='presentation' "
|
||||
"and @style:name='Default_20_1-background']/style:graphic-properties",
|
||||
"fill-color", "#808080");
|
||||
"and @style:name='Default_20_1-background']/style:graphic-properties"_ostr,
|
||||
"fill-color"_ostr, "#808080");
|
||||
assertXPath(
|
||||
pStyles,
|
||||
"/office:document-styles/office:styles/style:style[@style:family='presentation' and "
|
||||
"@style:name='Default_20_1-background']/style:graphic-properties[@draw:fill-image-name]",
|
||||
"@style:name='Default_20_1-background']/style:graphic-properties[@draw:fill-image-name]"_ostr,
|
||||
0);
|
||||
// master slide drawing-page style
|
||||
assertXPath(pStyles,
|
||||
"/office:document-styles/office:automatic-styles/style:style[@style:name='Mdp1']/"
|
||||
"style:drawing-page-properties",
|
||||
"fill", "bitmap");
|
||||
"style:drawing-page-properties"_ostr,
|
||||
"fill"_ostr, "bitmap");
|
||||
assertXPath(pStyles,
|
||||
"/office:document-styles/office:automatic-styles/style:style[@style:name='Mdp1']/"
|
||||
"style:drawing-page-properties",
|
||||
"fill-image-name", "nav_5f_up");
|
||||
"style:drawing-page-properties"_ostr,
|
||||
"fill-image-name"_ostr, "nav_5f_up");
|
||||
assertXPath(pStyles,
|
||||
"/office:document-styles/office:automatic-styles/style:style[@style:name='Mdp2']/"
|
||||
"style:drawing-page-properties",
|
||||
"fill", "solid");
|
||||
"style:drawing-page-properties"_ostr,
|
||||
"fill"_ostr, "solid");
|
||||
assertXPath(pStyles,
|
||||
"/office:document-styles/office:automatic-styles/style:style[@style:name='Mdp2']/"
|
||||
"style:drawing-page-properties",
|
||||
"fill-color", "#808080");
|
||||
"style:drawing-page-properties"_ostr,
|
||||
"fill-color"_ostr, "#808080");
|
||||
assertXPath(pStyles,
|
||||
"/office:document-styles/office:automatic-styles/style:style[@style:name='Mdp2']/"
|
||||
"style:drawing-page-properties[@draw:fill-image-name]",
|
||||
"style:drawing-page-properties[@draw:fill-image-name]"_ostr,
|
||||
0);
|
||||
|
||||
// the named items
|
||||
assertXPath(pStyles, "/office:document-styles/office:styles/draw:fill-image", 1);
|
||||
assertXPath(pStyles, "/office:document-styles/office:styles/draw:fill-image", "name",
|
||||
assertXPath(pStyles, "/office:document-styles/office:styles/draw:fill-image"_ostr, 1);
|
||||
assertXPath(pStyles, "/office:document-styles/office:styles/draw:fill-image"_ostr, "name"_ostr,
|
||||
"nav_5f_up");
|
||||
}
|
||||
|
||||
@@ -466,28 +468,28 @@ CPPUNIT_TEST_FIXTURE(SdExportTest, testTdf97630)
|
||||
assertXPath(pXmlDoc,
|
||||
"//style:style[@style:family='presentation']/"
|
||||
"style:graphic-properties[@draw:fit-to-size='false' and "
|
||||
"@style:shrink-to-fit='false']",
|
||||
"@style:shrink-to-fit='false']"_ostr,
|
||||
1);
|
||||
assertXPath(pXmlDoc,
|
||||
"//style:style[@style:family='presentation']/"
|
||||
"style:graphic-properties[@draw:fit-to-size='true' and "
|
||||
"@style:shrink-to-fit='false']",
|
||||
"@style:shrink-to-fit='false']"_ostr,
|
||||
2);
|
||||
assertXPath(pXmlDoc,
|
||||
"//style:style[@style:family='presentation']/"
|
||||
"style:graphic-properties[@draw:fit-to-size='false' and "
|
||||
"@style:shrink-to-fit='true']",
|
||||
"@style:shrink-to-fit='true']"_ostr,
|
||||
1);
|
||||
// fontworks
|
||||
assertXPath(pXmlDoc,
|
||||
"//style:style[@style:family='graphic']/"
|
||||
"style:graphic-properties[@draw:fit-to-size='false' and "
|
||||
"@style:shrink-to-fit='false']",
|
||||
"@style:shrink-to-fit='false']"_ostr,
|
||||
1);
|
||||
assertXPath(pXmlDoc,
|
||||
"//style:style[@style:family='graphic']/"
|
||||
"style:graphic-properties[@draw:fit-to-size='true' and "
|
||||
"@style:shrink-to-fit='false']",
|
||||
"@style:shrink-to-fit='false']"_ostr,
|
||||
1);
|
||||
}
|
||||
|
||||
@@ -585,9 +587,9 @@ CPPUNIT_TEST_FIXTURE(SdExportTest, testOOoXMLAnimations)
|
||||
// the problem was that legacy OOoXML animations were lost if store
|
||||
// immediately follows load because they were "converted" async by a timer
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("content.xml");
|
||||
assertXPath(pXmlDoc, "//anim:par[@presentation:node-type='timing-root']", 26);
|
||||
assertXPath(pXmlDoc, "//anim:par[@presentation:node-type='timing-root']"_ostr, 26);
|
||||
// currently getting 52 of these without the fix (depends on timing)
|
||||
assertXPath(pXmlDoc, "//anim:par", 223);
|
||||
assertXPath(pXmlDoc, "//anim:par"_ostr, 223);
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdExportTest, testBnc480256)
|
||||
@@ -655,11 +657,11 @@ CPPUNIT_TEST_FIXTURE(SdExportTest, testUnknownAttributes)
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("content.xml");
|
||||
assertXPath(pXmlDoc, "/office:document-content/office:automatic-styles/"
|
||||
"style:style[@style:name='gr1']/"
|
||||
"style:graphic-properties[@foo:non-existent-att='bar']");
|
||||
"style:graphic-properties[@foo:non-existent-att='bar']"_ostr);
|
||||
// TODO: if the namespace is *known*, the attribute is not preserved, but that seems to be a pre-existing problem, or maybe it's even intentional?
|
||||
// assertXPath(pXmlDoc, "/office:document-content/office:automatic-styles/style:style[@style:name='gr1']/style:graphic-properties[@svg:non-existent-att='blah']");
|
||||
// this was on style:graphic-properties on the import, but the export moves it to root node which is OK
|
||||
assertXPathNSDef(pXmlDoc, "/office:document-content", u"foo", u"http://example.com/");
|
||||
assertXPathNSDef(pXmlDoc, "/office:document-content"_ostr, u"foo", u"http://example.com/");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdExportTest, testTdf80020)
|
||||
@@ -790,31 +792,32 @@ CPPUNIT_TEST_FIXTURE(SdExportTest, testTdf79082)
|
||||
|
||||
// P1 should have 6 tab stops defined
|
||||
assertXPathChildren(
|
||||
pXmlDoc, "//style:style[@style:name='P1']/style:paragraph-properties/style:tab-stops", 6);
|
||||
pXmlDoc, "//style:style[@style:name='P1']/style:paragraph-properties/style:tab-stops"_ostr,
|
||||
6);
|
||||
assertXPath(pXmlDoc,
|
||||
"//style:style[@style:name='P1']/style:paragraph-properties/style:tab-stops/"
|
||||
"style:tab-stop[1]",
|
||||
"position", "0cm");
|
||||
"style:tab-stop[1]"_ostr,
|
||||
"position"_ostr, "0cm");
|
||||
assertXPath(pXmlDoc,
|
||||
"//style:style[@style:name='P1']/style:paragraph-properties/style:tab-stops/"
|
||||
"style:tab-stop[2]",
|
||||
"position", "5.08cm");
|
||||
"style:tab-stop[2]"_ostr,
|
||||
"position"_ostr, "5.08cm");
|
||||
assertXPath(pXmlDoc,
|
||||
"//style:style[@style:name='P1']/style:paragraph-properties/style:tab-stops/"
|
||||
"style:tab-stop[3]",
|
||||
"position", "10.16cm");
|
||||
"style:tab-stop[3]"_ostr,
|
||||
"position"_ostr, "10.16cm");
|
||||
assertXPath(pXmlDoc,
|
||||
"//style:style[@style:name='P1']/style:paragraph-properties/style:tab-stops/"
|
||||
"style:tab-stop[4]",
|
||||
"position", "15.24cm");
|
||||
"style:tab-stop[4]"_ostr,
|
||||
"position"_ostr, "15.24cm");
|
||||
assertXPath(pXmlDoc,
|
||||
"//style:style[@style:name='P1']/style:paragraph-properties/style:tab-stops/"
|
||||
"style:tab-stop[5]",
|
||||
"position", "20.32cm");
|
||||
"style:tab-stop[5]"_ostr,
|
||||
"position"_ostr, "20.32cm");
|
||||
assertXPath(pXmlDoc,
|
||||
"//style:style[@style:name='P1']/style:paragraph-properties/style:tab-stops/"
|
||||
"style:tab-stop[6]",
|
||||
"position", "25.4cm");
|
||||
"style:tab-stop[6]"_ostr,
|
||||
"position"_ostr, "25.4cm");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdExportTest, testImageWithSpecialID)
|
||||
@@ -1001,7 +1004,7 @@ CPPUNIT_TEST_FIXTURE(SdExportTest, testTdf98477)
|
||||
save("impress8");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("content.xml");
|
||||
assertXPath(pXmlDoc, "//anim:animateTransform", "by", "0.5,0.5");
|
||||
assertXPath(pXmlDoc, "//anim:animateTransform"_ostr, "by"_ostr, "0.5,0.5");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdExportTest, testAuthorField)
|
||||
@@ -1026,9 +1029,9 @@ CPPUNIT_TEST_FIXTURE(SdExportTest, testTdf50499)
|
||||
save("impress8");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("content.xml");
|
||||
assertXPath(pXmlDoc, "//anim:animate[1]", "from", "(-width/2)");
|
||||
assertXPath(pXmlDoc, "//anim:animate[1]", "to", "(x)");
|
||||
assertXPath(pXmlDoc, "//anim:animate[3]", "by", "(height/3+width*0.1)");
|
||||
assertXPath(pXmlDoc, "//anim:animate[1]"_ostr, "from"_ostr, "(-width/2)");
|
||||
assertXPath(pXmlDoc, "//anim:animate[1]"_ostr, "to"_ostr, "(x)");
|
||||
assertXPath(pXmlDoc, "//anim:animate[3]"_ostr, "by"_ostr, "(height/3+width*0.1)");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdExportTest, testTdf100926)
|
||||
@@ -1333,11 +1336,11 @@ CPPUNIT_TEST_FIXTURE(SdExportTest, testTdf113822)
|
||||
|
||||
// IterateContainer was created as ParallelTimeContainer before, so
|
||||
// the iterate type is not set too.
|
||||
assertXPath(pXmlDoc, "//anim:iterate", "iterate-type", "by-letter");
|
||||
assertXPath(pXmlDoc, "//anim:iterate"_ostr, "iterate-type"_ostr, "by-letter");
|
||||
// The target of the child animation nodes need to be in the iterate container.
|
||||
assertXPath(pXmlDoc, "//anim:iterate", "targetElement", "id1");
|
||||
assertXPath(pXmlDoc, "//anim:iterate/anim:set", "attributeName", "text-underline");
|
||||
assertXPath(pXmlDoc, "//anim:iterate/anim:set", "to", "solid");
|
||||
assertXPath(pXmlDoc, "//anim:iterate"_ostr, "targetElement"_ostr, "id1");
|
||||
assertXPath(pXmlDoc, "//anim:iterate/anim:set"_ostr, "attributeName"_ostr, "text-underline");
|
||||
assertXPath(pXmlDoc, "//anim:iterate/anim:set"_ostr, "to"_ostr, "solid");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdExportTest, testTdf113818)
|
||||
@@ -1348,8 +1351,8 @@ CPPUNIT_TEST_FIXTURE(SdExportTest, testTdf113818)
|
||||
save("impress8");
|
||||
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("content.xml");
|
||||
assertXPath(pXmlDoc, "//anim:animate[1]", "formula", "width*sin(2.5*pi*$)");
|
||||
assertXPath(pXmlDoc, "//anim:animate[1]", "values", "0;1");
|
||||
assertXPath(pXmlDoc, "//anim:animate[1]"_ostr, "formula"_ostr, "width*sin(2.5*pi*$)");
|
||||
assertXPath(pXmlDoc, "//anim:animate[1]"_ostr, "values"_ostr, "0;1");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdExportTest, testTdf119629)
|
||||
@@ -1369,7 +1372,7 @@ CPPUNIT_TEST_FIXTURE(SdExportTest, testTdf119629)
|
||||
"/anim:par[@presentation:node-type='on-click']"
|
||||
"/anim:par[@presentation:node-type='with-previous']"
|
||||
"/anim:par[@presentation:node-type='on-click']"
|
||||
"/anim:animate[@anim:formula='width*sin(2.5*pi*$)']",
|
||||
"/anim:animate[@anim:formula='width*sin(2.5*pi*$)']"_ostr,
|
||||
1);
|
||||
}
|
||||
|
||||
@@ -1407,18 +1410,18 @@ CPPUNIT_TEST_FIXTURE(SdExportTest, testTdf123557)
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("content.xml");
|
||||
|
||||
// Contains 2 interactive sequences and 3 triggered effects.
|
||||
assertXPath(pXmlDoc, "//draw:page", 1);
|
||||
assertXPath(pXmlDoc, "//draw:page/anim:par", 1);
|
||||
assertXPath(pXmlDoc, "//draw:page"_ostr, 1);
|
||||
assertXPath(pXmlDoc, "//draw:page/anim:par"_ostr, 1);
|
||||
assertXPath(pXmlDoc,
|
||||
"//draw:page"
|
||||
"/anim:par[@presentation:node-type='timing-root']"
|
||||
"/anim:seq[@presentation:node-type='interactive-sequence']",
|
||||
"/anim:seq[@presentation:node-type='interactive-sequence']"_ostr,
|
||||
2);
|
||||
assertXPath(pXmlDoc,
|
||||
"//draw:page"
|
||||
"/anim:par[@presentation:node-type='timing-root']"
|
||||
"/anim:seq[@presentation:node-type='interactive-sequence']"
|
||||
"/anim:par[@smil:begin]",
|
||||
"/anim:par[@smil:begin]"_ostr,
|
||||
3);
|
||||
}
|
||||
|
||||
@@ -1462,21 +1465,21 @@ CPPUNIT_TEST_FIXTURE(SdExportTest, testGlow)
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("content.xml");
|
||||
|
||||
// check that we actually test graphic style
|
||||
assertXPath(pXmlDoc, "/office:document-content/office:automatic-styles/style:style[2]",
|
||||
"family", "graphic");
|
||||
assertXPath(pXmlDoc, "/office:document-content/office:automatic-styles/style:style[2]"_ostr,
|
||||
"family"_ostr, "graphic");
|
||||
// check loext graphic attributes
|
||||
assertXPath(
|
||||
pXmlDoc,
|
||||
"/office:document-content/office:automatic-styles/style:style[2]/style:graphic-properties",
|
||||
"glow-radius", "0.529cm");
|
||||
"/office:document-content/office:automatic-styles/style:style[2]/style:graphic-properties"_ostr,
|
||||
"glow-radius"_ostr, "0.529cm");
|
||||
assertXPath(
|
||||
pXmlDoc,
|
||||
"/office:document-content/office:automatic-styles/style:style[2]/style:graphic-properties",
|
||||
"glow-color", "#ff4000");
|
||||
"/office:document-content/office:automatic-styles/style:style[2]/style:graphic-properties"_ostr,
|
||||
"glow-color"_ostr, "#ff4000");
|
||||
assertXPath(
|
||||
pXmlDoc,
|
||||
"/office:document-content/office:automatic-styles/style:style[2]/style:graphic-properties",
|
||||
"glow-transparency", "60%");
|
||||
"/office:document-content/office:automatic-styles/style:style[2]/style:graphic-properties"_ostr,
|
||||
"glow-transparency"_ostr, "60%");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdExportTest, testSoftEdges)
|
||||
@@ -1494,13 +1497,13 @@ CPPUNIT_TEST_FIXTURE(SdExportTest, testSoftEdges)
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("content.xml");
|
||||
|
||||
// check that we actually test graphic style
|
||||
assertXPath(pXmlDoc, "/office:document-content/office:automatic-styles/style:style[2]",
|
||||
"family", "graphic");
|
||||
assertXPath(pXmlDoc, "/office:document-content/office:automatic-styles/style:style[2]"_ostr,
|
||||
"family"_ostr, "graphic");
|
||||
// check loext graphic attribute
|
||||
assertXPath(
|
||||
pXmlDoc,
|
||||
"/office:document-content/office:automatic-styles/style:style[2]/style:graphic-properties",
|
||||
"softedge-radius", "0.635cm");
|
||||
"/office:document-content/office:automatic-styles/style:style[2]/style:graphic-properties"_ostr,
|
||||
"softedge-radius"_ostr, "0.635cm");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdExportTest, testShadowBlur)
|
||||
@@ -1515,12 +1518,12 @@ CPPUNIT_TEST_FIXTURE(SdExportTest, testShadowBlur)
|
||||
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("content.xml");
|
||||
|
||||
assertXPath(pXmlDoc, "/office:document-content/office:automatic-styles/style:style[3]",
|
||||
"family", "graphic");
|
||||
assertXPath(pXmlDoc, "/office:document-content/office:automatic-styles/style:style[3]"_ostr,
|
||||
"family"_ostr, "graphic");
|
||||
assertXPath(
|
||||
pXmlDoc,
|
||||
"/office:document-content/office:automatic-styles/style:style[3]/style:graphic-properties",
|
||||
"shadow-blur", "0.388cm");
|
||||
"/office:document-content/office:automatic-styles/style:style[3]/style:graphic-properties"_ostr,
|
||||
"shadow-blur"_ostr, "0.388cm");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdExportTest, testRhbz1870501)
|
||||
@@ -1562,8 +1565,8 @@ CPPUNIT_TEST_FIXTURE(SdExportTest, testTdf128550)
|
||||
createSdImpressDoc("pptx/tdf128550.pptx");
|
||||
save("impress8");
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("content.xml");
|
||||
assertXPath(pXmlDoc, "//anim:iterate[@anim:sub-item='background']", 1);
|
||||
assertXPath(pXmlDoc, "//anim:iterate[@anim:sub-item='text']", 4);
|
||||
assertXPath(pXmlDoc, "//anim:iterate[@anim:sub-item='background']"_ostr, 1);
|
||||
assertXPath(pXmlDoc, "//anim:iterate[@anim:sub-item='text']"_ostr, 4);
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdExportTest, testTdf140714)
|
||||
@@ -1753,29 +1756,29 @@ CPPUNIT_TEST_FIXTURE(SdExportTest, testMasterPageBackgroundFullSize)
|
||||
"style:style[@style:family='drawing-page' and @style:name = "
|
||||
"/office:document-styles/office:master-styles/"
|
||||
"style:master-page[@style:name='Default']/attribute::draw:style-name"
|
||||
"]/style:drawing-page-properties",
|
||||
"background-size", "border");
|
||||
"]/style:drawing-page-properties"_ostr,
|
||||
"background-size"_ostr, "border");
|
||||
assertXPath(pXmlDoc,
|
||||
"/office:document-styles/office:automatic-styles/"
|
||||
"style:style[@style:family='drawing-page' and @style:name = "
|
||||
"/office:document-styles/office:master-styles/"
|
||||
"style:master-page[@style:name='Default_20_3']/attribute::draw:style-name"
|
||||
"]/style:drawing-page-properties",
|
||||
"background-size", "full");
|
||||
"]/style:drawing-page-properties"_ostr,
|
||||
"background-size"_ostr, "full");
|
||||
assertXPath(pXmlDoc,
|
||||
"/office:document-styles/office:automatic-styles/"
|
||||
"style:style[@style:family='drawing-page' and @style:name = "
|
||||
"/office:document-styles/office:master-styles/"
|
||||
"style:master-page[@style:name='Default_20_2']/attribute::draw:style-name"
|
||||
"]/style:drawing-page-properties",
|
||||
"background-size", "border");
|
||||
"]/style:drawing-page-properties"_ostr,
|
||||
"background-size"_ostr, "border");
|
||||
assertXPath(pXmlDoc,
|
||||
"/office:document-styles/office:automatic-styles/"
|
||||
"style:style[@style:family='drawing-page' and @style:name = "
|
||||
"/office:document-styles/office:master-styles/"
|
||||
"style:master-page[@style:name='Default_20_1']/attribute::draw:style-name"
|
||||
"]/style:drawing-page-properties",
|
||||
"background-size", "full");
|
||||
"]/style:drawing-page-properties"_ostr,
|
||||
"background-size"_ostr, "full");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdExportTest, testColumnsODG)
|
||||
@@ -1831,12 +1834,12 @@ CPPUNIT_TEST_FIXTURE(SdExportTest, testColumnsODG)
|
||||
xmlDocUniquePtr pXmlDoc = parseExport("content.xml");
|
||||
assertXPath(pXmlDoc,
|
||||
"/office:document-content/office:automatic-styles/style:style/"
|
||||
"style:graphic-properties/style:columns",
|
||||
"column-count", "2");
|
||||
"style:graphic-properties/style:columns"_ostr,
|
||||
"column-count"_ostr, "2");
|
||||
assertXPath(pXmlDoc,
|
||||
"/office:document-content/office:automatic-styles/style:style/"
|
||||
"style:graphic-properties/style:columns",
|
||||
"column-gap", "0.7cm");
|
||||
"style:graphic-properties/style:columns"_ostr,
|
||||
"column-gap"_ostr, "0.7cm");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdExportTest, testTdf112126)
|
||||
|
||||
+52
-43
@@ -42,9 +42,9 @@ CPPUNIT_TEST_FIXTURE(SdLayoutTest, testTdf104722)
|
||||
// Without the fix in place, this would have failed with
|
||||
// - Expected: 2093
|
||||
// - Actual : -10276
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/textarray[1]", "x", "2093");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/textarray[1]"_ostr, "x"_ostr, "2093");
|
||||
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/textarray[1]", "y", "9273");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/textarray[1]"_ostr, "y"_ostr, "9273");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdLayoutTest, testTdf135843)
|
||||
@@ -54,11 +54,15 @@ CPPUNIT_TEST_FIXTURE(SdLayoutTest, testTdf135843)
|
||||
// Without the fix, the test fails with:
|
||||
// - Expected: 21165
|
||||
// - Actual : 4218
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/push[5]/polyline[1]/point[1]", "x", "21165");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/push[5]/polyline[1]/point[1]", "y", "3866");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/push[5]/polyline[1]/point[1]"_ostr, "x"_ostr,
|
||||
"21165");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/push[5]/polyline[1]/point[1]"_ostr, "y"_ostr,
|
||||
"3866");
|
||||
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/push[5]/polyline[1]/point[2]", "x", "21165");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/push[5]/polyline[1]/point[2]", "y", "5956");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/push[5]/polyline[1]/point[2]"_ostr, "x"_ostr,
|
||||
"21165");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/push[5]/polyline[1]/point[2]"_ostr, "y"_ostr,
|
||||
"5956");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdLayoutTest, testTdf146876)
|
||||
@@ -72,8 +76,8 @@ CPPUNIT_TEST_FIXTURE(SdLayoutTest, testTdf146876)
|
||||
{
|
||||
const OString xPath = "/metafile/push[1]/push[1]/push[" + OString::number(i)
|
||||
+ "]/polyline/point[" + OString::number(j) + "]";
|
||||
const sal_Int32 nX = getXPath(pXmlDoc, xPath, "x").toInt32();
|
||||
const sal_Int32 nY = getXPath(pXmlDoc, xPath, "y").toInt32();
|
||||
const sal_Int32 nX = getXPath(pXmlDoc, xPath, "x"_ostr).toInt32();
|
||||
const sal_Int32 nY = getXPath(pXmlDoc, xPath, "y"_ostr).toInt32();
|
||||
|
||||
// Without the fix in place, this test would have failed with
|
||||
// - Expected greater or equal than: 5000
|
||||
@@ -94,8 +98,10 @@ CPPUNIT_TEST_FIXTURE(SdLayoutTest, testTdf136949)
|
||||
// Without the fix in place, this test would have failed with
|
||||
// - Expected: 13687
|
||||
// - Actual : 2832
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/push[7]/polyline/point[1]", "x", "13687");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/push[7]/polyline/point[2]", "x", "24759");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/push[7]/polyline/point[1]"_ostr, "x"_ostr,
|
||||
"13687");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/push[7]/polyline/point[2]"_ostr, "x"_ostr,
|
||||
"24759");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdLayoutTest, testTdf128212)
|
||||
@@ -105,8 +111,8 @@ CPPUNIT_TEST_FIXTURE(SdLayoutTest, testTdf128212)
|
||||
// Without the fix in place, this test would have failed with
|
||||
// - Expected: 7792
|
||||
// - Actual : 12068
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/textarray", "x", "4520");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/textarray", "y", "7792");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/textarray"_ostr, "x"_ostr, "4520");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/textarray"_ostr, "y"_ostr, "7792");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdLayoutTest, testColumnsLayout)
|
||||
@@ -194,10 +200,10 @@ CPPUNIT_TEST_FIXTURE(SdLayoutTest, testColumnsLayout)
|
||||
const auto & [ sentence, index, length, x, y ] = strings[i];
|
||||
OString sXPath = "/metafile/push[1]/push[1]/textarray[" + OString::number(i + 1) + "]";
|
||||
assertXPathContent(pXmlDoc, sXPath + "/text", sText[sentence]);
|
||||
assertXPath(pXmlDoc, sXPath, "index", OUString::number(index));
|
||||
assertXPath(pXmlDoc, sXPath, "length", OUString::number(length));
|
||||
assertXPath(pXmlDoc, sXPath, "x", OUString::number(x));
|
||||
assertXPath(pXmlDoc, sXPath, "y", OUString::number(y));
|
||||
assertXPath(pXmlDoc, sXPath, "index"_ostr, OUString::number(index));
|
||||
assertXPath(pXmlDoc, sXPath, "length"_ostr, OUString::number(length));
|
||||
assertXPath(pXmlDoc, sXPath, "x"_ostr, OUString::number(x));
|
||||
assertXPath(pXmlDoc, sXPath, "y"_ostr, OUString::number(y));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -231,25 +237,25 @@ CPPUNIT_TEST_FIXTURE(SdLayoutTest, tdf143258_testTbRlLayout)
|
||||
|
||||
xmlDocUniquePtr pXmlDoc = load("odg/tb-rl-textbox.odg");
|
||||
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/font", SAL_N_ELEMENTS(strings));
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/textarray", SAL_N_ELEMENTS(strings));
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/font"_ostr, SAL_N_ELEMENTS(strings));
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/textarray"_ostr, SAL_N_ELEMENTS(strings));
|
||||
for (size_t i = 0; i < SAL_N_ELEMENTS(strings); ++i)
|
||||
{
|
||||
const auto & [ sentence, index, length, x, y ] = strings[i];
|
||||
OString sXPath = "/metafile/push[1]/push[1]/font[" + OString::number(i + 1) + "]";
|
||||
assertXPath(pXmlDoc, sXPath, "orientation", "-900");
|
||||
assertXPath(pXmlDoc, sXPath, "vertical", "true");
|
||||
assertXPath(pXmlDoc, sXPath, "orientation"_ostr, "-900");
|
||||
assertXPath(pXmlDoc, sXPath, "vertical"_ostr, "true");
|
||||
sXPath = "/metafile/push[1]/push[1]/textarray[" + OString::number(i + 1) + "]";
|
||||
assertXPathContent(pXmlDoc, sXPath + "/text", sText[sentence]);
|
||||
assertXPath(pXmlDoc, sXPath, "index", OUString::number(index));
|
||||
assertXPath(pXmlDoc, sXPath, "length", OUString::number(length));
|
||||
assertXPath(pXmlDoc, sXPath, "index"_ostr, OUString::number(index));
|
||||
assertXPath(pXmlDoc, sXPath, "length"_ostr, OUString::number(length));
|
||||
|
||||
// Without the fix in place, this would have failed with
|
||||
// - Expected: 5346
|
||||
// - Actual : 503924
|
||||
// - In <>, attribute 'x' of '/metafile/push[1]/push[1]/textarray[1]' incorrect value.
|
||||
assertXPath(pXmlDoc, sXPath, "x", OUString::number(x));
|
||||
assertXPath(pXmlDoc, sXPath, "y", OUString::number(y));
|
||||
assertXPath(pXmlDoc, sXPath, "x"_ostr, OUString::number(x));
|
||||
assertXPath(pXmlDoc, sXPath, "y"_ostr, OUString::number(y));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -257,15 +263,15 @@ CPPUNIT_TEST_FIXTURE(SdLayoutTest, testTdf146731)
|
||||
{
|
||||
xmlDocUniquePtr pXmlDoc = load("pptx/tdf146731.pptx");
|
||||
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/push[3]/polyline[1]", "width", "187");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/push[4]/polyline[1]", "width", "187");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/push[5]/polyline[1]", "width", "187");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/push[3]/polyline[1]"_ostr, "width"_ostr, "187");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/push[4]/polyline[1]"_ostr, "width"_ostr, "187");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/push[5]/polyline[1]"_ostr, "width"_ostr, "187");
|
||||
|
||||
// Without the fix in place, this test would have failed with
|
||||
// - Expected: 30
|
||||
// - Actual : 187
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/push[6]/polyline[1]", "width", "30");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/push[7]/polyline[1]", "width", "187");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/push[6]/polyline[1]"_ostr, "width"_ostr, "30");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/push[7]/polyline[1]"_ostr, "width"_ostr, "187");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdLayoutTest, testTdf135843_InsideHBorders)
|
||||
@@ -277,7 +283,7 @@ CPPUNIT_TEST_FIXTURE(SdLayoutTest, testTdf135843_InsideHBorders)
|
||||
//- Actual : 36
|
||||
// We shouldn't see two vertical borders inside the table on ui.
|
||||
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/push", 34);
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/push"_ostr, 34);
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdLayoutTest, testBnc480256)
|
||||
@@ -289,7 +295,8 @@ CPPUNIT_TEST_FIXTURE(SdLayoutTest, testBnc480256)
|
||||
//- Actual : #ffffff
|
||||
// We should see the red vertical border inside the table.
|
||||
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/push[8]/linecolor[1]", "color", "#ff0000");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/push[8]/linecolor[1]"_ostr, "color"_ostr,
|
||||
"#ff0000");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdLayoutTest, testFitToFrameTextFitting)
|
||||
@@ -306,11 +313,13 @@ CPPUNIT_TEST_FIXTURE(SdLayoutTest, testFitToFrameTextFitting)
|
||||
|
||||
xmlDocUniquePtr pXmlDoc = load("odg/FitToFrameText.odg");
|
||||
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/textarray[1]", "x", "0");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/textarray[1]", "y", "406");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/textarray[1]/dxarray", "first", "110");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/textarray[1]"_ostr, "x"_ostr, "0");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/textarray[1]"_ostr, "y"_ostr, "406");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/textarray[1]/dxarray"_ostr, "first"_ostr,
|
||||
"110");
|
||||
#ifndef _WIN32 // Windows seems to differ in text layouting, so ignore for now
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/textarray[1]/dxarray", "last", "6981");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/textarray[1]/dxarray"_ostr, "last"_ostr,
|
||||
"6981");
|
||||
#endif
|
||||
}
|
||||
|
||||
@@ -323,7 +332,7 @@ CPPUNIT_TEST_FIXTURE(SdLayoutTest, testTdf148966)
|
||||
// - Expected: 5952
|
||||
// - Actual : 7814
|
||||
// i.e. Line break after multiline field should have been ignored.
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/textarray[3]", "y", "5952");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/textarray[3]"_ostr, "y"_ostr, "5952");
|
||||
}
|
||||
{
|
||||
xmlDocUniquePtr pXmlDoc = load("odp/tdf148966-withflag.odp");
|
||||
@@ -332,11 +341,11 @@ CPPUNIT_TEST_FIXTURE(SdLayoutTest, testTdf148966)
|
||||
// - Actual : 7814
|
||||
// i.e. When IgnoreBreakAfterMultilineField flag is set, line break
|
||||
// after multiline field should have been ignored.
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/textarray[3]", "y", "5952");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/textarray[3]"_ostr, "y"_ostr, "5952");
|
||||
}
|
||||
{
|
||||
xmlDocUniquePtr pXmlDoc = load("odp/tdf148966-withoutflag.odp");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/textarray[3]", "y", "7814");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/textarray[3]"_ostr, "y"_ostr, "7814");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -350,8 +359,8 @@ CPPUNIT_TEST_FIXTURE(SdLayoutTest, testTableVerticalText)
|
||||
// - In <>, attribute 'orientation' of '//font[1]' incorrect value.
|
||||
// i.e. table cell text that was supposed to be vertical (rotated 90
|
||||
// degrees) was not vertical.
|
||||
assertXPath(pXmlDoc, "//font[1]", "orientation", "-900");
|
||||
assertXPath(pXmlDoc, "//font[2]", "orientation", "900");
|
||||
assertXPath(pXmlDoc, "//font[1]"_ostr, "orientation"_ostr, "-900");
|
||||
assertXPath(pXmlDoc, "//font[2]"_ostr, "orientation"_ostr, "900");
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdLayoutTest, testTdf112594)
|
||||
@@ -365,9 +374,9 @@ CPPUNIT_TEST_FIXTURE(SdLayoutTest, testTdf112594)
|
||||
// - Expected: 4
|
||||
// - Actual : 3
|
||||
// - In <>, attribute 'length' of '/metafile/push[1]/push[1]/textarray[3]' incorrect value.
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/textarray[3]", "index", "0");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/textarray[3]", "length", "4");
|
||||
assertXPathContent(pXmlDoc, "/metafile/push[1]/push[1]/textarray[3]/text",
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/textarray[3]"_ostr, "index"_ostr, "0");
|
||||
assertXPath(pXmlDoc, "/metafile/push[1]/push[1]/textarray[3]"_ostr, "length"_ostr, "4");
|
||||
assertXPathContent(pXmlDoc, "/metafile/push[1]/push[1]/textarray[3]/text"_ostr,
|
||||
u"11\u202f\u1824"_ustr);
|
||||
}
|
||||
|
||||
|
||||
@@ -773,7 +773,8 @@ void SdMiscTest::testTdf98839_ShearVFlipH()
|
||||
static constexpr OString sPathStart(
|
||||
"/office:document-content/office:body/office:drawing/draw:page"_ostr);
|
||||
assertXPath(pXmlDoc, sPathStart);
|
||||
const OUString sTransform = getXPath(pXmlDoc, sPathStart + "/draw:custom-shape", "transform");
|
||||
const OUString sTransform
|
||||
= getXPath(pXmlDoc, sPathStart + "/draw:custom-shape", "transform"_ostr);
|
||||
|
||||
// Error was, that the shear angle had a wrong sign.
|
||||
CPPUNIT_ASSERT_MESSAGE("expected: draw:transform='skewX (-0.64350...)",
|
||||
|
||||
@@ -205,9 +205,9 @@ void LOKitSearchTest::testSearchAll()
|
||||
lcl_search("match", /*bFindAll=*/true);
|
||||
|
||||
// This was empty: find-all did not highlight the first match.
|
||||
CPPUNIT_ASSERT_EQUAL(OString("match"),
|
||||
CPPUNIT_ASSERT_EQUAL("match"_ostr,
|
||||
apitest::helper::transferable::getTextSelection(
|
||||
pXImpressDocument->getSelection(), "text/plain;charset=utf-8"));
|
||||
pXImpressDocument->getSelection(), "text/plain;charset=utf-8"_ostr));
|
||||
|
||||
// We're on the first slide, search for something on the second slide and make sure we get a SET_PART.
|
||||
mpCallbackRecorder->m_nPart = 0;
|
||||
@@ -253,9 +253,9 @@ void LOKitSearchTest::testSearchAllFollowedBySearch()
|
||||
|
||||
// This used to give wrong result: 'search' after 'search all' still
|
||||
// returned 'third'
|
||||
CPPUNIT_ASSERT_EQUAL(OString("match"),
|
||||
CPPUNIT_ASSERT_EQUAL("match"_ostr,
|
||||
apitest::helper::transferable::getTextSelection(
|
||||
pXImpressDocument->getSelection(), "text/plain;charset=utf-8"));
|
||||
pXImpressDocument->getSelection(), "text/plain;charset=utf-8"_ostr));
|
||||
}
|
||||
|
||||
void LOKitSearchTest::testDontSearchInMasterPages()
|
||||
@@ -336,7 +336,7 @@ void LOKitSearchTest::testSearchInPDF()
|
||||
CPPUNIT_ASSERT_EQUAL(1, mpCallbackRecorder->m_nSearchResultCount);
|
||||
|
||||
CPPUNIT_ASSERT_EQUAL(size_t(1), mpCallbackRecorder->m_aSearchResultSelection.size());
|
||||
CPPUNIT_ASSERT_EQUAL(OString("3763, 1331, 1432, 483"),
|
||||
CPPUNIT_ASSERT_EQUAL("3763, 1331, 1432, 483"_ostr,
|
||||
mpCallbackRecorder->m_aSearchResultSelection[0]);
|
||||
CPPUNIT_ASSERT_EQUAL(tools::Rectangle(Point(3763, 1331), Size(1433, 484)),
|
||||
mpCallbackRecorder->m_aSelection[0]);
|
||||
@@ -348,7 +348,7 @@ void LOKitSearchTest::testSearchInPDF()
|
||||
CPPUNIT_ASSERT_EQUAL(2, mpCallbackRecorder->m_nSearchResultCount);
|
||||
|
||||
CPPUNIT_ASSERT_EQUAL(size_t(1), mpCallbackRecorder->m_aSearchResultSelection.size());
|
||||
CPPUNIT_ASSERT_EQUAL(OString("3763, 1331, 1432, 483"),
|
||||
CPPUNIT_ASSERT_EQUAL("3763, 1331, 1432, 483"_ostr,
|
||||
mpCallbackRecorder->m_aSearchResultSelection[0]);
|
||||
CPPUNIT_ASSERT_EQUAL(tools::Rectangle(Point(3763, 1331), Size(1433, 484)),
|
||||
mpCallbackRecorder->m_aSelection[0]);
|
||||
@@ -433,7 +433,7 @@ void LOKitSearchTest::testSearchInPDFInMultiplePages()
|
||||
CPPUNIT_ASSERT_EQUAL(size_t(1), mpCallbackRecorder->m_aSearchResultPart.size());
|
||||
|
||||
CPPUNIT_ASSERT_EQUAL(0, mpCallbackRecorder->m_aSearchResultPart[0]);
|
||||
CPPUNIT_ASSERT_EQUAL(OString("9463, 3382, 1099, 499"),
|
||||
CPPUNIT_ASSERT_EQUAL("9463, 3382, 1099, 499"_ostr,
|
||||
mpCallbackRecorder->m_aSearchResultSelection[0]);
|
||||
|
||||
// Search for "him"
|
||||
@@ -446,7 +446,7 @@ void LOKitSearchTest::testSearchInPDFInMultiplePages()
|
||||
CPPUNIT_ASSERT_EQUAL(size_t(1), mpCallbackRecorder->m_aSearchResultPart.size());
|
||||
|
||||
CPPUNIT_ASSERT_EQUAL(0, mpCallbackRecorder->m_aSearchResultPart[0]);
|
||||
CPPUNIT_ASSERT_EQUAL(OString("5592, 5038, 1100, 499"),
|
||||
CPPUNIT_ASSERT_EQUAL("5592, 5038, 1100, 499"_ostr,
|
||||
mpCallbackRecorder->m_aSearchResultSelection[0]);
|
||||
|
||||
// Search for "him"
|
||||
@@ -459,7 +459,7 @@ void LOKitSearchTest::testSearchInPDFInMultiplePages()
|
||||
CPPUNIT_ASSERT_EQUAL(size_t(1), mpCallbackRecorder->m_aSearchResultPart.size());
|
||||
|
||||
CPPUNIT_ASSERT_EQUAL(1, mpCallbackRecorder->m_aSearchResultPart[0]);
|
||||
CPPUNIT_ASSERT_EQUAL(OString("9463, 1308, 1099, 499"),
|
||||
CPPUNIT_ASSERT_EQUAL("9463, 1308, 1099, 499"_ostr,
|
||||
mpCallbackRecorder->m_aSearchResultSelection[0]);
|
||||
|
||||
// Search for "him"
|
||||
@@ -472,7 +472,7 @@ void LOKitSearchTest::testSearchInPDFInMultiplePages()
|
||||
CPPUNIT_ASSERT_EQUAL(size_t(1), mpCallbackRecorder->m_aSearchResultPart.size());
|
||||
|
||||
CPPUNIT_ASSERT_EQUAL(1, mpCallbackRecorder->m_aSearchResultPart[0]);
|
||||
CPPUNIT_ASSERT_EQUAL(OString("5592, 2964, 1100, 499"),
|
||||
CPPUNIT_ASSERT_EQUAL("5592, 2964, 1100, 499"_ostr,
|
||||
mpCallbackRecorder->m_aSearchResultSelection[0]);
|
||||
|
||||
// Search for "him" - back to start
|
||||
@@ -485,7 +485,7 @@ void LOKitSearchTest::testSearchInPDFInMultiplePages()
|
||||
CPPUNIT_ASSERT_EQUAL(size_t(1), mpCallbackRecorder->m_aSearchResultPart.size());
|
||||
|
||||
CPPUNIT_ASSERT_EQUAL(0, mpCallbackRecorder->m_aSearchResultPart[0]);
|
||||
CPPUNIT_ASSERT_EQUAL(OString("9463, 3382, 1099, 499"),
|
||||
CPPUNIT_ASSERT_EQUAL("9463, 3382, 1099, 499"_ostr,
|
||||
mpCallbackRecorder->m_aSearchResultSelection[0]);
|
||||
}
|
||||
|
||||
@@ -536,7 +536,7 @@ void LOKitSearchTest::testSearchInPDFInMultiplePagesBackwards()
|
||||
CPPUNIT_ASSERT_EQUAL(size_t(1), mpCallbackRecorder->m_aSearchResultPart.size());
|
||||
|
||||
CPPUNIT_ASSERT_EQUAL(0, mpCallbackRecorder->m_aSearchResultPart[0]);
|
||||
CPPUNIT_ASSERT_EQUAL(OString("5592, 5038, 1100, 499"),
|
||||
CPPUNIT_ASSERT_EQUAL("5592, 5038, 1100, 499"_ostr,
|
||||
mpCallbackRecorder->m_aSearchResultSelection[0]);
|
||||
|
||||
// Search for "him"
|
||||
@@ -549,7 +549,7 @@ void LOKitSearchTest::testSearchInPDFInMultiplePagesBackwards()
|
||||
CPPUNIT_ASSERT_EQUAL(size_t(1), mpCallbackRecorder->m_aSearchResultPart.size());
|
||||
|
||||
CPPUNIT_ASSERT_EQUAL(0, mpCallbackRecorder->m_aSearchResultPart[0]);
|
||||
CPPUNIT_ASSERT_EQUAL(OString("9463, 3382, 1099, 499"),
|
||||
CPPUNIT_ASSERT_EQUAL("9463, 3382, 1099, 499"_ostr,
|
||||
mpCallbackRecorder->m_aSearchResultSelection[0]);
|
||||
|
||||
// Search for "him"
|
||||
@@ -562,7 +562,7 @@ void LOKitSearchTest::testSearchInPDFInMultiplePagesBackwards()
|
||||
CPPUNIT_ASSERT_EQUAL(size_t(1), mpCallbackRecorder->m_aSearchResultPart.size());
|
||||
|
||||
CPPUNIT_ASSERT_EQUAL(1, mpCallbackRecorder->m_aSearchResultPart[0]);
|
||||
CPPUNIT_ASSERT_EQUAL(OString("5592, 2964, 1100, 499"),
|
||||
CPPUNIT_ASSERT_EQUAL("5592, 2964, 1100, 499"_ostr,
|
||||
mpCallbackRecorder->m_aSearchResultSelection[0]);
|
||||
|
||||
// Search for "him"
|
||||
@@ -575,7 +575,7 @@ void LOKitSearchTest::testSearchInPDFInMultiplePagesBackwards()
|
||||
CPPUNIT_ASSERT_EQUAL(size_t(1), mpCallbackRecorder->m_aSearchResultPart.size());
|
||||
|
||||
CPPUNIT_ASSERT_EQUAL(1, mpCallbackRecorder->m_aSearchResultPart[0]);
|
||||
CPPUNIT_ASSERT_EQUAL(OString("9463, 1308, 1099, 499"),
|
||||
CPPUNIT_ASSERT_EQUAL("9463, 1308, 1099, 499"_ostr,
|
||||
mpCallbackRecorder->m_aSearchResultSelection[0]);
|
||||
|
||||
// Search for "him" - back to start
|
||||
@@ -588,7 +588,7 @@ void LOKitSearchTest::testSearchInPDFInMultiplePagesBackwards()
|
||||
CPPUNIT_ASSERT_EQUAL(size_t(1), mpCallbackRecorder->m_aSearchResultPart.size());
|
||||
|
||||
CPPUNIT_ASSERT_EQUAL(0, mpCallbackRecorder->m_aSearchResultPart[0]);
|
||||
CPPUNIT_ASSERT_EQUAL(OString("5592, 5038, 1100, 499"),
|
||||
CPPUNIT_ASSERT_EQUAL("5592, 5038, 1100, 499"_ostr,
|
||||
mpCallbackRecorder->m_aSearchResultSelection[0]);
|
||||
}
|
||||
|
||||
@@ -653,7 +653,7 @@ void LOKitSearchTest::testSearchIn2MixedObjects()
|
||||
CPPUNIT_ASSERT_EQUAL(size_t(1), mpCallbackRecorder->m_aSearchResultSelection.size());
|
||||
CPPUNIT_ASSERT_EQUAL(size_t(1), mpCallbackRecorder->m_aSearchResultPart.size());
|
||||
|
||||
CPPUNIT_ASSERT_EQUAL(OString("3546, 3174, 738, 402"),
|
||||
CPPUNIT_ASSERT_EQUAL("3546, 3174, 738, 402"_ostr,
|
||||
mpCallbackRecorder->m_aSearchResultSelection[0]);
|
||||
|
||||
// Search next
|
||||
@@ -666,7 +666,7 @@ void LOKitSearchTest::testSearchIn2MixedObjects()
|
||||
CPPUNIT_ASSERT_EQUAL(size_t(1), mpCallbackRecorder->m_aSearchResultSelection.size());
|
||||
CPPUNIT_ASSERT_EQUAL(size_t(1), mpCallbackRecorder->m_aSearchResultPart.size());
|
||||
|
||||
CPPUNIT_ASSERT_EQUAL(OString("8412, 6385, 519, 174"),
|
||||
CPPUNIT_ASSERT_EQUAL("8412, 6385, 519, 174"_ostr,
|
||||
mpCallbackRecorder->m_aSearchResultSelection[0]);
|
||||
|
||||
// Search next again - we should get the first object again
|
||||
@@ -679,7 +679,7 @@ void LOKitSearchTest::testSearchIn2MixedObjects()
|
||||
CPPUNIT_ASSERT_EQUAL(size_t(1), mpCallbackRecorder->m_aSearchResultSelection.size());
|
||||
CPPUNIT_ASSERT_EQUAL(size_t(1), mpCallbackRecorder->m_aSearchResultPart.size());
|
||||
|
||||
CPPUNIT_ASSERT_EQUAL(OString("3546, 3174, 738, 402"),
|
||||
CPPUNIT_ASSERT_EQUAL("3546, 3174, 738, 402"_ostr,
|
||||
mpCallbackRecorder->m_aSearchResultSelection[0]);
|
||||
}
|
||||
|
||||
|
||||
@@ -406,10 +406,10 @@ CPPUNIT_TEST_FIXTURE(SdTiledRenderingTest, testGetTextSelection)
|
||||
ESelection aWordSelection(0, 0, 0, 5);
|
||||
rEditView.SetSelection(aWordSelection);
|
||||
// Did we indeed manage to copy the selected text?
|
||||
CPPUNIT_ASSERT_EQUAL(OString("Shape"), apitest::helper::transferable::getTextSelection(pXImpressDocument->getSelection(), "text/plain;charset=utf-8"));
|
||||
CPPUNIT_ASSERT_EQUAL("Shape"_ostr, apitest::helper::transferable::getTextSelection(pXImpressDocument->getSelection(), "text/plain;charset=utf-8"_ostr));
|
||||
|
||||
// Make sure returned RTF is not empty.
|
||||
CPPUNIT_ASSERT(!apitest::helper::transferable::getTextSelection(pXImpressDocument->getSelection(), "text/rtf").isEmpty());
|
||||
CPPUNIT_ASSERT(!apitest::helper::transferable::getTextSelection(pXImpressDocument->getSelection(), "text/rtf"_ostr).isEmpty());
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdTiledRenderingTest, testSetGraphicSelection)
|
||||
@@ -730,9 +730,9 @@ CPPUNIT_TEST_FIXTURE(SdTiledRenderingTest, testResizeTableColumn)
|
||||
|
||||
// Remember the original cell widths.
|
||||
xmlDocUniquePtr pXmlDoc = parseXmlDump();
|
||||
OString aPrefix = "/SdDrawDocument/SdrModel/maPages/SdPage/SdrPage/SdrObjList/SdrTableObj/SdrTableObjImpl/TableLayouter/columns/";
|
||||
sal_Int32 nExpectedColumn1 = getXPath(pXmlDoc, aPrefix + "TableLayouter_Layout[1]", "size").toInt32();
|
||||
sal_Int32 nExpectedColumn2 = getXPath(pXmlDoc, aPrefix + "TableLayouter_Layout[2]", "size").toInt32();
|
||||
OString aPrefix = "/SdDrawDocument/SdrModel/maPages/SdPage/SdrPage/SdrObjList/SdrTableObj/SdrTableObjImpl/TableLayouter/columns/"_ostr;
|
||||
sal_Int32 nExpectedColumn1 = getXPath(pXmlDoc, aPrefix + "TableLayouter_Layout[1]", "size"_ostr).toInt32();
|
||||
sal_Int32 nExpectedColumn2 = getXPath(pXmlDoc, aPrefix + "TableLayouter_Layout[2]", "size"_ostr).toInt32();
|
||||
pXmlDoc = nullptr;
|
||||
|
||||
// Resize the left column, decrease its width by 1 cm.
|
||||
@@ -742,9 +742,9 @@ CPPUNIT_TEST_FIXTURE(SdTiledRenderingTest, testResizeTableColumn)
|
||||
|
||||
// Remember the resized column widths.
|
||||
pXmlDoc = parseXmlDump();
|
||||
sal_Int32 nResizedColumn1 = getXPath(pXmlDoc, aPrefix + "TableLayouter_Layout[1]", "size").toInt32();
|
||||
sal_Int32 nResizedColumn1 = getXPath(pXmlDoc, aPrefix + "TableLayouter_Layout[1]", "size"_ostr).toInt32();
|
||||
CPPUNIT_ASSERT(nResizedColumn1 < nExpectedColumn1);
|
||||
sal_Int32 nResizedColumn2 = getXPath(pXmlDoc, aPrefix + "TableLayouter_Layout[2]", "size").toInt32();
|
||||
sal_Int32 nResizedColumn2 = getXPath(pXmlDoc, aPrefix + "TableLayouter_Layout[2]", "size"_ostr).toInt32();
|
||||
CPPUNIT_ASSERT(nResizedColumn2 > nExpectedColumn2);
|
||||
pXmlDoc = nullptr;
|
||||
|
||||
@@ -753,10 +753,10 @@ CPPUNIT_TEST_FIXTURE(SdTiledRenderingTest, testResizeTableColumn)
|
||||
|
||||
// Check the undo result.
|
||||
pXmlDoc = parseXmlDump();
|
||||
sal_Int32 nActualColumn1 = getXPath(pXmlDoc, aPrefix + "TableLayouter_Layout[1]", "size").toInt32();
|
||||
sal_Int32 nActualColumn1 = getXPath(pXmlDoc, aPrefix + "TableLayouter_Layout[1]", "size"_ostr).toInt32();
|
||||
// Expected was 7049, actual was 6048, i.e. the first column width after undo was 1cm smaller than expected.
|
||||
CPPUNIT_ASSERT_EQUAL(nExpectedColumn1, nActualColumn1);
|
||||
sal_Int32 nActualColumn2 = getXPath(pXmlDoc, aPrefix + "TableLayouter_Layout[2]", "size").toInt32();
|
||||
sal_Int32 nActualColumn2 = getXPath(pXmlDoc, aPrefix + "TableLayouter_Layout[2]", "size"_ostr).toInt32();
|
||||
CPPUNIT_ASSERT_EQUAL(nExpectedColumn2, nActualColumn2);
|
||||
pXmlDoc = nullptr;
|
||||
}
|
||||
@@ -1569,8 +1569,8 @@ CPPUNIT_TEST_FIXTURE(SdTiledRenderingTest, testTdf104405)
|
||||
getXPath(
|
||||
pXmlDoc,
|
||||
"/SdDrawDocument/SdrModel/maPages/SdPage/SdrPage/SdrObjList/SdrTableObj/SdrTableObjImpl"
|
||||
"/TableModel/Cell[1]/DefaultProperties/SfxItemSet/SdrTextVertAdjustItem",
|
||||
"value"));
|
||||
"/TableModel/Cell[1]/DefaultProperties/SfxItemSet/SdrTextVertAdjustItem"_ostr,
|
||||
"value"_ostr));
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SdTiledRenderingTest, testTdf81754)
|
||||
@@ -1638,8 +1638,8 @@ CPPUNIT_TEST_FIXTURE(SdTiledRenderingTest, testTdf105502)
|
||||
// Assert that the selected A1 has now a larger font than the unselected
|
||||
// A2.
|
||||
xmlDocUniquePtr pXmlDoc = parseXmlDump();
|
||||
sal_Int32 nA1Height = getXPath(pXmlDoc, "//Cell[1]/SdrText/OutlinerParaObject/EditTextObject/ContentInfo/SfxItemSet/SvxFontHeightItem[1]", "height").toInt32();
|
||||
sal_Int32 nA2Height = getXPath(pXmlDoc, "//Cell[3]/SdrText/OutlinerParaObject/EditTextObject/ContentInfo/attribs[1]/SvxFontHeightItem", "height").toInt32();
|
||||
sal_Int32 nA1Height = getXPath(pXmlDoc, "//Cell[1]/SdrText/OutlinerParaObject/EditTextObject/ContentInfo/SfxItemSet/SvxFontHeightItem[1]"_ostr, "height"_ostr).toInt32();
|
||||
sal_Int32 nA2Height = getXPath(pXmlDoc, "//Cell[3]/SdrText/OutlinerParaObject/EditTextObject/ContentInfo/attribs[1]/SvxFontHeightItem"_ostr, "height"_ostr).toInt32();
|
||||
// This failed when FuText::ChangeFontSize() never did "continue" in the
|
||||
// text loop, instead of doing so depending on what IsInSelection() returns.
|
||||
CPPUNIT_ASSERT(nA1Height > nA2Height);
|
||||
@@ -2163,7 +2163,7 @@ CPPUNIT_TEST_FIXTURE(SdTiledRenderingTest, testIMESupport)
|
||||
SfxCallMode::SYNCHRON, { &aInputString });
|
||||
|
||||
// sequence of chinese IME compositions when 'nihao' is typed in an IME
|
||||
const std::vector<OString> aUtf8Inputs{ "年", "你", "你好", "你哈", "你好", "你好" };
|
||||
const std::vector<OString> aUtf8Inputs{ "年"_ostr, "你"_ostr, "你好"_ostr, "你哈"_ostr, "你好"_ostr, "你好"_ostr };
|
||||
std::vector<OUString> aInputs;
|
||||
std::transform(aUtf8Inputs.begin(), aUtf8Inputs.end(),
|
||||
std::back_inserter(aInputs), [](OString aInput) {
|
||||
@@ -2398,11 +2398,11 @@ CPPUNIT_TEST_FIXTURE(SdTiledRenderingTest, testGetViewRenderState)
|
||||
SdXImpressDocument* pXImpressDocument = createDoc("dummy.odp");
|
||||
int nFirstViewId = SfxLokHelper::getView();
|
||||
ViewCallback aView1;
|
||||
CPPUNIT_ASSERT_EQUAL(OString(";Default"), pXImpressDocument->getViewRenderState());
|
||||
CPPUNIT_ASSERT_EQUAL(";Default"_ostr, pXImpressDocument->getViewRenderState());
|
||||
// Create a second view
|
||||
SfxLokHelper::createView();
|
||||
ViewCallback aView2;
|
||||
CPPUNIT_ASSERT_EQUAL(OString(";Default"), pXImpressDocument->getViewRenderState());
|
||||
CPPUNIT_ASSERT_EQUAL(";Default"_ostr, pXImpressDocument->getViewRenderState());
|
||||
// Set to dark scheme
|
||||
{
|
||||
uno::Sequence<beans::PropertyValue> aPropertyValues = comphelper::InitPropertySequence(
|
||||
@@ -2412,10 +2412,10 @@ CPPUNIT_TEST_FIXTURE(SdTiledRenderingTest, testGetViewRenderState)
|
||||
);
|
||||
dispatchCommand(mxComponent, ".uno:ChangeTheme", aPropertyValues);
|
||||
}
|
||||
CPPUNIT_ASSERT_EQUAL(OString(";Dark"), pXImpressDocument->getViewRenderState());
|
||||
CPPUNIT_ASSERT_EQUAL(";Dark"_ostr, pXImpressDocument->getViewRenderState());
|
||||
// Switch back to the first view, and check that the options string is the same
|
||||
SfxLokHelper::setView(nFirstViewId);
|
||||
CPPUNIT_ASSERT_EQUAL(OString(";Default"), pXImpressDocument->getViewRenderState());
|
||||
CPPUNIT_ASSERT_EQUAL(";Default"_ostr, pXImpressDocument->getViewRenderState());
|
||||
}
|
||||
|
||||
// Helper function to get a tile to a bitmap and check the pixel color
|
||||
|
||||
@@ -1883,7 +1883,7 @@ ShapeExport& PowerPointShapeExport::WritePlaceholderShape(const Reference< XShap
|
||||
// visual shape properties
|
||||
mpFS->startElementNS(XML_p, XML_spPr);
|
||||
WriteShapeTransformation(xShape, XML_a);
|
||||
WritePresetShape("rect");
|
||||
WritePresetShape("rect"_ostr);
|
||||
if (xProps.is())
|
||||
{
|
||||
WriteBlipFill(xProps, "Graphic");
|
||||
|
||||
@@ -55,7 +55,7 @@ void SdModule::InitInterface_Impl()
|
||||
|
||||
// Ctor
|
||||
SdModule::SdModule(SfxObjectFactory* pFact1, SfxObjectFactory* pFact2 )
|
||||
: SfxModule("sd", {pFact1, pFact2}),
|
||||
: SfxModule("sd"_ostr, {pFact1, pFact2}),
|
||||
pTransferClip(nullptr),
|
||||
pTransferDrag(nullptr),
|
||||
pTransferSelection(nullptr),
|
||||
|
||||
@@ -53,10 +53,10 @@ void Communicator::execute()
|
||||
pTransmitter.reset( new Transmitter( mpSocket.get() ) );
|
||||
pTransmitter->create();
|
||||
|
||||
pTransmitter->addMessage( "LO_SERVER_SERVER_PAIRED\n\n",
|
||||
pTransmitter->addMessage( "LO_SERVER_SERVER_PAIRED\n\n"_ostr,
|
||||
Transmitter::PRIORITY_HIGH );
|
||||
|
||||
pTransmitter->addMessage( "LO_SERVER_INFO\n" LIBO_VERSION_DOTTED "\n\n",
|
||||
pTransmitter->addMessage( "LO_SERVER_INFO\n" LIBO_VERSION_DOTTED "\n\n"_ostr,
|
||||
Transmitter::PRIORITY_HIGH );
|
||||
|
||||
Receiver aReceiver( pTransmitter.get() );
|
||||
@@ -82,7 +82,7 @@ void Communicator::execute()
|
||||
}
|
||||
else
|
||||
{
|
||||
pTransmitter->addMessage( "slideshow_finished\n\n",
|
||||
pTransmitter->addMessage( "slideshow_finished\n\n"_ostr,
|
||||
Transmitter::PRIORITY_HIGH );
|
||||
}
|
||||
}
|
||||
@@ -131,7 +131,7 @@ void Communicator::informListenerDestroyed()
|
||||
// during disposal of this communicator
|
||||
|
||||
if ( pTransmitter )
|
||||
pTransmitter->addMessage( "slideshow_finished\n\n",
|
||||
pTransmitter->addMessage( "slideshow_finished\n\n"_ostr,
|
||||
Transmitter::PRIORITY_HIGH );
|
||||
}
|
||||
|
||||
|
||||
@@ -181,7 +181,7 @@ OString ImagePreparer::prepareNotes( sal_uInt32 aSlideNumber )
|
||||
OUStringBuffer aRet;
|
||||
|
||||
if ( !xController->isRunning() )
|
||||
return "";
|
||||
return ""_ostr;
|
||||
|
||||
uno::Reference<css::drawing::XDrawPage> aNotesPage;
|
||||
uno::Reference< drawing::XDrawPage > xSourceDoc(
|
||||
@@ -192,7 +192,7 @@ OString ImagePreparer::prepareNotes( sal_uInt32 aSlideNumber )
|
||||
if (xPresentationPage.is())
|
||||
aNotesPage = xPresentationPage->getNotesPage();
|
||||
else
|
||||
return "";
|
||||
return ""_ostr;
|
||||
|
||||
static constexpr OUString sNotesShapeName (
|
||||
u"com.sun.star.presentation.NotesShape"_ustr );
|
||||
|
||||
@@ -253,9 +253,9 @@ ViewShellBase::ViewShellBase (
|
||||
ViewShellBase::~ViewShellBase()
|
||||
{
|
||||
// Notify other LOK views that we are going away.
|
||||
SfxLokHelper::notifyOtherViews(this, LOK_CALLBACK_VIEW_CURSOR_VISIBLE, "visible", "false");
|
||||
SfxLokHelper::notifyOtherViews(this, LOK_CALLBACK_TEXT_VIEW_SELECTION, "selection", "");
|
||||
SfxLokHelper::notifyOtherViews(this, LOK_CALLBACK_GRAPHIC_VIEW_SELECTION, "selection", "EMPTY");
|
||||
SfxLokHelper::notifyOtherViews(this, LOK_CALLBACK_VIEW_CURSOR_VISIBLE, "visible", "false"_ostr);
|
||||
SfxLokHelper::notifyOtherViews(this, LOK_CALLBACK_TEXT_VIEW_SELECTION, "selection", ""_ostr);
|
||||
SfxLokHelper::notifyOtherViews(this, LOK_CALLBACK_GRAPHIC_VIEW_SELECTION, "selection", "EMPTY"_ostr);
|
||||
|
||||
sfx2::SfxNotebookBar::CloseMethod(GetFrame()->GetBindings());
|
||||
|
||||
|
||||
@@ -454,7 +454,7 @@ void DrawViewShell::ChangeEditMode(EditMode eEMode, bool bIsLayerModeActive)
|
||||
|
||||
if (comphelper::LibreOfficeKit::isActive())
|
||||
GetViewShell()->libreOfficeKitViewCallback(LOK_CALLBACK_STATE_CHANGED,
|
||||
".uno:SlideMasterPage=true");
|
||||
".uno:SlideMasterPage=true"_ostr);
|
||||
if (!mpActualPage)
|
||||
{
|
||||
// as long as there is no mpActualPage, take first
|
||||
|
||||
@@ -1035,7 +1035,7 @@ void DrawViewShell::FuSupport(SfxRequest& rReq)
|
||||
{
|
||||
if (comphelper::LibreOfficeKit::isActive())
|
||||
GetViewShell()->libreOfficeKitViewCallback(LOK_CALLBACK_STATE_CHANGED,
|
||||
".uno:SlideMasterPage=true");
|
||||
".uno:SlideMasterPage=true"_ostr);
|
||||
|
||||
// AutoLayouts needs to be finished
|
||||
GetDoc()->StopWorkStartupDelay();
|
||||
@@ -1074,7 +1074,7 @@ void DrawViewShell::FuSupport(SfxRequest& rReq)
|
||||
// Notify of disabling master view, which is enabled in DrawViewShell::ChangeEditMode.
|
||||
if (comphelper::LibreOfficeKit::isActive())
|
||||
GetViewShell()->libreOfficeKitViewCallback(LOK_CALLBACK_STATE_CHANGED,
|
||||
".uno:SlideMasterPage=false");
|
||||
".uno:SlideMasterPage=false"_ostr);
|
||||
|
||||
Broadcast (
|
||||
ViewShellHint(ViewShellHint::HINT_CHANGE_EDIT_MODE_START));
|
||||
|
||||
@@ -811,7 +811,7 @@ SdrEndTextEditKind View::SdrEndTextEdit(bool bDontDeleteReally)
|
||||
mpViewSh->GetViewShellBase().GetDrawController()->FireSelectionChangeListener();
|
||||
|
||||
if (comphelper::LibreOfficeKit::isActive())
|
||||
SfxLokHelper::notifyOtherViews(&mpViewSh->GetViewShellBase(), LOK_CALLBACK_VIEW_LOCK, "rectangle", "EMPTY");
|
||||
SfxLokHelper::notifyOtherViews(&mpViewSh->GetViewShellBase(), LOK_CALLBACK_VIEW_LOCK, "rectangle", "EMPTY"_ostr);
|
||||
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user