diff options
author | Miklos Vajna <vmiklos@collabora.com> | 2019-09-17 17:08:02 +0200 |
---|---|---|
committer | Andras Timar <andras.timar@collabora.com> | 2019-10-04 15:41:58 +0200 |
commit | 1bd742d6f8482467c5b306779efb3de2d54111a4 (patch) | |
tree | df36c63660f2186424ded1ffc6eb178d94a3ac75 /sw/source | |
parent | 57dde667d9256192a83944a3dbc1fc83bc1e3a31 (diff) |
Related: tdf#124600 sw textbox: sync left/right margin of shape to textbox
Writer TextFrames have a default left/right margin; sync from shape to
textbox is needed to have correct layout when a DOCX shape has 0 left or
right margin.
The left margin of the shape was already correct.
(The shape in the docx file was extended to have text.)
(cherry picked from commit ff5f02b9282e19a2a8a68604c588e9487021b0b5)
Change-Id: I832f1bc460f2553bd7f08252d3e21000b4906538
Reviewed-on: https://gerrit.libreoffice.org/80109
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Diffstat (limited to 'sw/source')
-rw-r--r-- | sw/source/core/doc/textboxhelper.cxx | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/sw/source/core/doc/textboxhelper.cxx b/sw/source/core/doc/textboxhelper.cxx index fedb6dfb7e2a..59ccce892de7 100644 --- a/sw/source/core/doc/textboxhelper.cxx +++ b/sw/source/core/doc/textboxhelper.cxx @@ -445,6 +445,19 @@ void SwTextBoxHelper::syncProperty(SwFrameFormat* pShape, sal_uInt16 nWID, sal_u break; } break; + case RES_LR_SPACE: + { + switch (nMemberID) + { + case MID_L_MARGIN: + aPropertyName = UNO_NAME_LEFT_MARGIN; + break; + case MID_R_MARGIN: + aPropertyName = UNO_NAME_RIGHT_MARGIN; + break; + } + break; + } case RES_VERT_ORIENT: switch (nMemberID) { |