summaryrefslogtreecommitdiff
path: root/sw/qa/extras/odfexport
diff options
context:
space:
mode:
authorSamuel Mehrbrodt <samuel.mehrbrodt@allotropia.de>2021-07-19 08:11:43 +0200
committerSamuel Mehrbrodt <samuel.mehrbrodt@allotropia.de>2021-07-26 14:13:53 +0200
commita23b44fd9f0119f7ea3523e32875f55c1a07c1cd (patch)
tree2a9ffc63b7186fea9d0cfea8660d95d30a8f6684 /sw/qa/extras/odfexport
parent3c3b9ad8886da916027f0fb940a2df822d63d4d7 (diff)
tdf#123626 Allow adding hyperlinks to shapes
* Support hyperlinks on Shapes in Writer * Add menu items * Add context menu items * ODF import/export + test * OOXML import/export + test Change-Id: I7269064c4cabd16fdb8259a48429c508184d3ccf Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119164 Tested-by: Jenkins Reviewed-by: Samuel Mehrbrodt <samuel.mehrbrodt@allotropia.de>
Diffstat (limited to 'sw/qa/extras/odfexport')
-rw-r--r--sw/qa/extras/odfexport/data/shape-with-hyperlink.odtbin0 -> 10149 bytes
-rw-r--r--sw/qa/extras/odfexport/odfexport2.cxx10
2 files changed, 10 insertions, 0 deletions
diff --git a/sw/qa/extras/odfexport/data/shape-with-hyperlink.odt b/sw/qa/extras/odfexport/data/shape-with-hyperlink.odt
new file mode 100644
index 000000000000..7b112782845f
--- /dev/null
+++ b/sw/qa/extras/odfexport/data/shape-with-hyperlink.odt
Binary files differ
diff --git a/sw/qa/extras/odfexport/odfexport2.cxx b/sw/qa/extras/odfexport/odfexport2.cxx
index 5269779a1690..0812f2c801e3 100644
--- a/sw/qa/extras/odfexport/odfexport2.cxx
+++ b/sw/qa/extras/odfexport/odfexport2.cxx
@@ -82,6 +82,16 @@ DECLARE_ODFEXPORT_TEST(testListFormatDocx, "listformat.docx")
"text:list-level-style-number[@text:level='3']", "num-suffix", "<<");
}
+DECLARE_ODFEXPORT_TEST(testShapeWithHyperlink, "shape-with-hyperlink.odt")
+{
+ if (xmlDocUniquePtr pXmlDoc = parseExport("content.xml"))
+ {
+ // Check how conversion from prefix/suffix to list format did work
+ assertXPath(pXmlDoc, "/office:document-content/office:body/office:text/text:p/draw:a",
+ "href", "http://shape.com/");
+ }
+}
+
DECLARE_ODFEXPORT_TEST(testListFormatOdt, "listformat.odt")
{
// Ensure in resulting ODT we also have not just prefix/suffix, but custom delimiters