summaryrefslogtreecommitdiff
path: root/sw/source
diff options
context:
space:
mode:
authorMichael Stahl <Michael.Stahl@cib.de>2020-02-27 14:59:50 +0100
committerMichael Stahl <michael.stahl@cib.de>2020-02-27 16:43:31 +0100
commit74e3c95b9b628a0b326790b62b4e378a12d02997 (patch)
tree5f2ff642e40ee34993b1a4a056146c64acc45d42 /sw/source
parent9fa3d941c05b64e79c5a36b9b4d29953326a32d4 (diff)
sw: DOCX export: fix first-line indent of list items
The problem is that since CVS import, if a SwTextNode has a first-line indent and is in a list or outline that has LABEL_WIDTH_AND_POSITION mode, then MSWordExportBase::OutputTextNode() will throw away the node's first-line indent and overwrite it with the numbering's. Experiments indicate that adding the numbering's value to the node's value fixes most cases, but RTL still doesn't work in many cases. Change-Id: I9707f475dac4e501642ebaf51c0117107fd34a3b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/89634 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.stahl@cib.de>
Diffstat (limited to 'sw/source')
-rw-r--r--sw/source/filter/ww8/wrtw8nds.cxx8
1 files changed, 6 insertions, 2 deletions
diff --git a/sw/source/filter/ww8/wrtw8nds.cxx b/sw/source/filter/ww8/wrtw8nds.cxx
index 53b709bc0f21..bec214a2830e 100644
--- a/sw/source/filter/ww8/wrtw8nds.cxx
+++ b/sw/source/filter/ww8/wrtw8nds.cxx
@@ -2813,9 +2813,13 @@ void MSWordExportBase::OutputTextNode( SwTextNode& rNode )
SvxNumberFormat::LABEL_WIDTH_AND_POSITION )
{
if (bParaRTL)
- aLR.SetTextFirstLineOffsetValue(pFormat->GetAbsLSpace() - pFormat->GetFirstLineOffset()); //TODO: overflow
+ {
+ aLR.SetTextFirstLineOffsetValue(aLR.GetTextFirstLineOffset() + pFormat->GetAbsLSpace() - pFormat->GetFirstLineOffset()); //TODO: overflow
+ }
else
- aLR.SetTextFirstLineOffset(GetWordFirstLineOffset(*pFormat));
+ {
+ aLR.SetTextFirstLineOffset(aLR.GetTextFirstLineOffset() + GetWordFirstLineOffset(*pFormat));
+ }
}
// correct fix for issue i94187