summaryrefslogtreecommitdiff
path: root/sw
diff options
context:
space:
mode:
authorJustin Luth <justin.luth@collabora.com>2022-04-19 15:29:14 +0200
committerJustin Luth <jluth@mail.com>2022-04-19 21:05:27 +0200
commit76de78c338fd508c21289ff2edab80fc4f5d8c23 (patch)
treee19ce3d0830503ab8ffb4e708c48685077e69184 /sw
parentc7ed23137f7601833793ea8c27e1c601b6d19290 (diff)
tdf#148565 sw ms export: a new run can't be postponed-started
This fixes a LO 7.4 regression from commit 46b62f7777c6acdc2c94dc4b2ab79d38a10c49f9. A make check with an assert indicated the following existing unit tests matched - but they had no noticable char run content to test against. ooxmlexport6's testShapeThemePreservation ooxmlexport7's testBnc884615 ooxmlexport9's testTdf90789 ooxmlexport10's testTdf90153 ooxmlexport11's testTdf137655 ooxmlexport14's testTdf131539 ooxmlexport15's testTdf138739 ooxmlexport17's testTdf126287 Change-Id: Iae89ff1f6de06bfe37b886e1e39e8457157ae240 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/133187 Tested-by: Jenkins Reviewed-by: Justin Luth <jluth@mail.com>
Diffstat (limited to 'sw')
-rw-r--r--sw/qa/extras/ooxmlexport/ooxmlexport15.cxx4
-rw-r--r--sw/source/filter/ww8/wrtw8nds.cxx2
2 files changed, 6 insertions, 0 deletions
diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport15.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport15.cxx
index 1a9bddbfbd67..d5cc153b7a7d 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlexport15.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlexport15.cxx
@@ -9,6 +9,7 @@
#include <swmodeltestbase.hxx>
+#include <com/sun/star/awt/FontWeight.hpp>
#include <com/sun/star/drawing/FillStyle.hpp>
#include <com/sun/star/text/RelOrientation.hpp>
#include <com/sun/star/text/XTextViewCursorSupplier.hpp>
@@ -268,6 +269,9 @@ DECLARE_OOXMLEXPORT_TEST(testTdf138739, "tdf138739.docx")
uno::Reference<beans::XPropertySet> xParaProps(getParagraph(1), uno::UNO_QUERY);
CPPUNIT_ASSERT_EQUAL_MESSAGE("Font type name does not match!", OUString("Comic Sans MS"),
xParaProps->getPropertyValue("CharFontName").get<OUString>());
+
+ // tdf#148565: text at anchor point should be bold, Comic Sanc MS font
+ CPPUNIT_ASSERT_EQUAL(awt::FontWeight::BOLD, getProperty<float>(getRun(getParagraph(5), 3), "CharWeight"));
}
DECLARE_OOXMLEXPORT_TEST(testTdf123390, "tdf123390.fodt")
diff --git a/sw/source/filter/ww8/wrtw8nds.cxx b/sw/source/filter/ww8/wrtw8nds.cxx
index 1a600e33e799..dbbe0d67fc9d 100644
--- a/sw/source/filter/ww8/wrtw8nds.cxx
+++ b/sw/source/filter/ww8/wrtw8nds.cxx
@@ -2772,6 +2772,8 @@ void MSWordExportBase::OutputTextNode( SwTextNode& rNode )
if (FLY_PROCESSED == nStateOfFlyFrame || FLY_NONE == nStateOfFlyFrame)
{
AttrOutput().EndRun(&rNode, nCurrentPos, /*bLastRun=*/false);
+ if (!aSavedSnippet.isEmpty())
+ bStartedPostponedRunProperties = false;
AttrOutput().StartRun( pRedlineData, nCurrentPos, bSingleEmptyRun );
AttrOutput().SetAnchorIsLinkedToNode( false );