summaryrefslogtreecommitdiff
path: root/sw/qa
diff options
context:
space:
mode:
authorMiklos Vajna <vmiklos@collabora.co.uk>2014-11-20 11:02:45 +0100
committerMiklos Vajna <vmiklos@collabora.co.uk>2014-11-20 11:46:59 +0100
commitb2c1474c1dc93b69f0ede03fc5c9ab496c669955 (patch)
tree7f049ca2cdabad5e0fcf415e39e29f7f07ed3a5d /sw/qa
parent96664bf0152ecf8ee64aa6b22ed399c1866117f1 (diff)
SwTxtNode::IsIgnoredCharFmtForNumbering: ignore RES_CHRATR_COLOR
And also in SwTxtFormatter::NewNumberPortion(), use SwTxtNode::IsIgnoredCharFmtForNumbering(), via checkApplyParagraphMarkFormatToNumbering(). Otherwise the color of the paragraph mark is inherited by the numbering portion, which is not what IDocumentSettingAccess::APPLY_PARAGRAPH_MARK_FORMAT_TO_NUMBERING (mirroring Word's behavior) is supposed to do. Change-Id: I5d8df9b404916cc4a4405bf796d971ede59e6111
Diffstat (limited to 'sw/qa')
-rw-r--r--sw/qa/extras/ooxmlexport/data/num-override-lvltext.docxbin13625 -> 13708 bytes
-rw-r--r--sw/qa/extras/ooxmlexport/ooxmlexport.cxx3
2 files changed, 3 insertions, 0 deletions
diff --git a/sw/qa/extras/ooxmlexport/data/num-override-lvltext.docx b/sw/qa/extras/ooxmlexport/data/num-override-lvltext.docx
index 5ee36020a112..fe3142d54a03 100644
--- a/sw/qa/extras/ooxmlexport/data/num-override-lvltext.docx
+++ b/sw/qa/extras/ooxmlexport/data/num-override-lvltext.docx
Binary files differ
diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport.cxx
index 8c78d45343fb..519ad65e45f4 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlexport.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlexport.cxx
@@ -596,6 +596,9 @@ DECLARE_OOXMLEXPORT_TEST(testNumOverrideLvltext, "num-override-lvltext.docx")
uno::Reference<container::XIndexAccess> xRules = getProperty< uno::Reference<container::XIndexAccess> >(getStyles("NumberingStyles")->getByName("WWNum1"), "NumberingRules");
// This was 1, i.e. the numbering on the second level was "1", not "1.1".
CPPUNIT_ASSERT_EQUAL(sal_Int16(2), comphelper::SequenceAsHashMap(xRules->getByIndex(1))["ParentNumbering"].get<sal_Int16>());
+
+ // The paragraph marker's red font color was inherited by the number portion, this was ff0000.
+ CPPUNIT_ASSERT_EQUAL(OUString("00000a"), parseDump("//Special[@nType='POR_NUMBER']/pFont", "color"));
}
CPPUNIT_PLUGIN_IMPLEMENT();