[Libreoffice-commits] .: 2 commits - sw/qa writerfilter/source
Miklos Vajna
vmiklos at kemper.freedesktop.org
Thu Aug 2 01:58:27 PDT 2012
sw/qa/extras/ooxmlexport/data/fdo51034.odt |binary
sw/qa/extras/ooxmlexport/ooxmlexport.cxx | 9 +++++++++
writerfilter/source/dmapper/DomainMapper_Impl.cxx | 2 +-
3 files changed, 10 insertions(+), 1 deletion(-)
New commits:
commit 6ff70708b4a39011a61aa0f53541eb7eec09c813
Author: Miklos Vajna <vmiklos at suse.cz>
Date: Thu Aug 2 10:57:07 2012 +0200
fdo#51034 testcase
Change-Id: I9a7a4e596ffb14cdcb211ff0d905c66831d30708
diff --git a/sw/qa/extras/ooxmlexport/data/fdo51034.odt b/sw/qa/extras/ooxmlexport/data/fdo51034.odt
new file mode 100644
index 0000000..9720cfb
Binary files /dev/null and b/sw/qa/extras/ooxmlexport/data/fdo51034.odt differ
diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport.cxx
index 02f66a2..020bffd 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlexport.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlexport.cxx
@@ -42,6 +42,7 @@ public:
void defaultTabStopNotInStyles();
void testFdo38244();
void testMathEscape();
+ void testFdo51034();
CPPUNIT_TEST_SUITE(Test);
#if !defined(MACOSX) && !defined(WNT)
@@ -52,6 +53,7 @@ public:
#if !(__GNUC__ == 4 && __GNUC_MINOR__ == 4)
CPPUNIT_TEST(testMathEscape);
#endif
+ CPPUNIT_TEST(testFdo51034);
#endif
CPPUNIT_TEST_SUITE_END();
@@ -170,6 +172,13 @@ void Test::testMathEscape()
CPPUNIT_ASSERT_EQUAL(OUString("\\{ left [ right ] left ( right ) \\}"), getFormula(getRun(getParagraph(1), 1)));
}
+void Test::testFdo51034()
+{
+ // The problem was that the 'l' param of the HYPERLINK field was parsed with = "#", not += "#".
+ roundtrip("fdo51034.odt");
+ CPPUNIT_ASSERT_EQUAL(OUString("http://Www.google.com/#a"), getProperty<OUString>(getRun(getParagraph(1), 1), "HyperLinkURL"));
+}
+
CPPUNIT_TEST_SUITE_REGISTRATION(Test);
CPPUNIT_PLUGIN_IMPLEMENT();
commit 9c53a7f94f3bdcb694498db335a01af25257853a
Author: Miklos Vajna <vmiklos at suse.cz>
Date: Thu Aug 2 10:49:02 2012 +0200
fdo#51034 fix docx import of HYPERLINK field, l param
Change-Id: Ic6896f7c795d7d303bf7589a74afb937d4a8e8b5
diff --git a/writerfilter/source/dmapper/DomainMapper_Impl.cxx b/writerfilter/source/dmapper/DomainMapper_Impl.cxx
index ebee085..164a2d4 100644
--- a/writerfilter/source/dmapper/DomainMapper_Impl.cxx
+++ b/writerfilter/source/dmapper/DomainMapper_Impl.cxx
@@ -2871,7 +2871,7 @@ void DomainMapper_Impl::CloseFieldCommand()
if (aPartIt == aItEnd)
break;
- sURL = OUString('#');
+ sURL += OUString('#');
sURL += *aPartIt;
}
else if ( *aPartIt == "\\m" || *aPartIt == "\\n" )
More information about the Libreoffice-commits
mailing list