diff options
author | Miklos Vajna <vmiklos@collabora.com> | 2020-07-20 21:22:14 +0200 |
---|---|---|
committer | Andras Timar <andras.timar@collabora.com> | 2020-07-23 10:24:25 +0200 |
commit | 4a88779af7619a37c4c04bf513994f119fc8f354 (patch) | |
tree | 7db751513d28f94629001cca54c5a24b1ffbec60 /writerfilter | |
parent | f651419fcfa2e4a5059ba41587f1b437fe069109 (diff) |
tdf#134400 RTF import: fix unexpected inner properties for picture-in-textframe
Regression from commit 4ab658b56f5c6ff0082d38d8ace1924d11e30e96 (RTF
import: implement support for tables inside text frames, 2013-06-16),
the problem was that both the outer "textbox" and the inner "picture
frame" object had a shapeType property, and the properties were stored
in a vector. So by the time RTFSdrImport::initShape() looked up the
shape type for the inner shape, it thought it's not a picture frame,
leading to data loss.
(cherry picked from commit 5a083be34456e91427d0f2e2fea172f49f4502db)
Change-Id: I4a536789371619d1d54afa8c8d41c7d273b0d21b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/99118
Tested-by: Jenkins
Reviewed-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com>
Signed-off-by: Xisco Fauli <xiscofauli@libreoffice.org>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/99167
Reviewed-by: Michael Stahl <michael.stahl@cib.de>
Diffstat (limited to 'writerfilter')
-rw-r--r-- | writerfilter/source/rtftok/rtfsdrimport.cxx | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/writerfilter/source/rtftok/rtfsdrimport.cxx b/writerfilter/source/rtftok/rtfsdrimport.cxx index 85f61129b1f3..ddd2337a9945 100644 --- a/writerfilter/source/rtftok/rtfsdrimport.cxx +++ b/writerfilter/source/rtftok/rtfsdrimport.cxx @@ -1129,6 +1129,11 @@ void RTFSdrImport::resolve(RTFShape& rShape, bool bClose, ShapeOrPict const shap m_rImport.Mapper().endShape(); } } + + // If the shape has an inner shape, the inner object's properties should not be influenced by + // the outer one. + rShape.getProperties().clear(); + m_xShape = xShape; } |