summaryrefslogtreecommitdiff
path: root/sw/qa/extras/ww8export/ww8export2.cxx
diff options
context:
space:
mode:
authorJustin Luth <justin.luth@collabora.com>2020-08-31 14:40:55 +0300
committerMiklos Vajna <vmiklos@collabora.com>2020-09-01 09:27:34 +0200
commitfb8334aa79e811bb6780e072e24d2580932f1031 (patch)
treed86f54c8941e211b3651592d098341bfb31d97e3 /sw/qa/extras/ww8export/ww8export2.cxx
parente22408d15f74f3aa4be324fa00978f7041882673 (diff)
tdf#136282 ww8import: track para bidi, not char bidi for style
This fixes a LO 7.0 regression from tdf#99197. Apparently I was watching the wrong SPRM for bidi change in styles. It looks like it should be sprmPFBiDi: A Bool8 value that specifies whether the paragraph uses right-to-left layout. By default, a paragraph does not use right-to-left layout. Instead, I had been using sprmCFBiDi: A ToggleOperand value that specifies whether the text is formatted with right-to-left layout. By default, text is displayed from right to left if the language for the text is a right-to-left language. [So this one looks like a character run property.] I no longer remember why I used CfBiDi. Perhaps just because it sets m_bBiDi which sounds good? However, there are no existing unit tests that have a CFBiDi in a style, but there are examples with CFBiDi. I'm really surprised that QA didn't have any documents that picked up on this regression. I was counting on that... Change-Id: If5a115db5962e7e26ca1b280cd9f31d493cee69c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101726 Tested-by: Jenkins Reviewed-by: Justin Luth <justin_luth@sil.org> Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Diffstat (limited to 'sw/qa/extras/ww8export/ww8export2.cxx')
-rw-r--r--sw/qa/extras/ww8export/ww8export2.cxx1
1 files changed, 1 insertions, 0 deletions
diff --git a/sw/qa/extras/ww8export/ww8export2.cxx b/sw/qa/extras/ww8export/ww8export2.cxx
index 48391d594236..f811fc5200e1 100644
--- a/sw/qa/extras/ww8export/ww8export2.cxx
+++ b/sw/qa/extras/ww8export/ww8export2.cxx
@@ -351,6 +351,7 @@ DECLARE_WW8EXPORT_TEST(testTdf112074_RTLtableJustification, "tdf112074_RTLtableJ
DECLARE_WW8EXPORT_TEST(testTdf98620_rtlJustify, "tdf98620_rtlJustify.doc")
{
CPPUNIT_ASSERT_EQUAL( style::ParagraphAdjust_RIGHT, static_cast<style::ParagraphAdjust>(getProperty<sal_Int16>(getParagraph(1), "ParaAdjust")) );
+ CPPUNIT_ASSERT_EQUAL_MESSAGE("Right To Left style", text::WritingMode2::RL_TB, getProperty<sal_Int16>(getParagraph(1), "WritingMode"));
}
DECLARE_WW8EXPORT_TEST(testTdf121110_absJustify, "tdf121110_absJustify.doc")