diff options
author | Miklos Vajna <vmiklos@collabora.co.uk> | 2014-05-26 15:28:31 +0200 |
---|---|---|
committer | Andras Timar <andras.timar@collabora.com> | 2014-06-02 19:01:54 +0200 |
commit | 12c1ce9d7c4333138c62e1602480df271561ddbe (patch) | |
tree | 1ce6ce7820836d1ecaa79c80f394c60bc17b26f3 /writerfilter | |
parent | 13f63f5c90d5d282390ea17caa703ce953230490 (diff) |
fdo#78900 RTF import: allow \dpxsize inside \dptxbxtext
Previously we assumed that they always appear under \do directly.
Change-Id: Ie3a978da856986f604a3815d6127abb4191323c0
(cherry picked from commit 21c11ffe254612ac46aa891addacb0024d5b93f0)
Reviewed-on: https://gerrit.libreoffice.org/9488
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'writerfilter')
-rw-r--r-- | writerfilter/source/rtftok/rtfdocumentimpl.cxx | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/writerfilter/source/rtftok/rtfdocumentimpl.cxx b/writerfilter/source/rtftok/rtfdocumentimpl.cxx index ab23fb46f23d..816595d598b0 100644 --- a/writerfilter/source/rtftok/rtfdocumentimpl.cxx +++ b/writerfilter/source/rtftok/rtfdocumentimpl.cxx @@ -5037,6 +5037,17 @@ int RTFDocumentImpl::popState() m_aStates.top().pCurrentBuffer->push_back( Buf_t(BUFFER_ENDSHAPE)); } + + // It's allowed to declare these inside the the shape text, and they + // are expected to have an effect for the whole shape. + if (aState.aDrawingObject.nLeft) + m_aStates.top().aDrawingObject.nLeft = aState.aDrawingObject.nLeft; + if (aState.aDrawingObject.nTop) + m_aStates.top().aDrawingObject.nTop = aState.aDrawingObject.nTop; + if (aState.aDrawingObject.nRight) + m_aStates.top().aDrawingObject.nRight = aState.aDrawingObject.nRight; + if (aState.aDrawingObject.nBottom) + m_aStates.top().aDrawingObject.nBottom = aState.aDrawingObject.nBottom; break; default: { |