path: root/writerfilter/source/rtftok/rtfdocumentimpl.cxx
diff options
authorMichael Stahl <>2020-09-18 18:52:45 +0200
committerMichael Stahl <>2020-09-21 10:47:42 +0200
commit54bd2266d6e0c8926ecaf0fbb2dbb5ee9d1a802d (patch)
treedacb8d4bc325619f405d9529981c4529be98fd4a /writerfilter/source/rtftok/rtfdocumentimpl.cxx
parentfefcad1186232b26180d095bbafdf8e8bdda8209 (diff)
tdf#136855 writerfilter: RTF import: buffer annotations inside tables
The problem is that one of the annotations is inside a table that happens to start with a covered cell (vertically merged). The table row is buffered, but the annotation is not, so it is inserted before any of the text of the table cells is inserted, so it ends up in the covered cell. The strucuture of annotations is a bit icky; to fix this, buffer both the \annotation destination and \atrfstart \atrfend start and end destinations. Change-Id: Ie955a75a2d254f8d7e965259698b688eece7cbd6 Reviewed-on: Tested-by: Jenkins Reviewed-by: Michael Stahl <>
Diffstat (limited to 'writerfilter/source/rtftok/rtfdocumentimpl.cxx')
1 files changed, 9 insertions, 1 deletions
diff --git a/writerfilter/source/rtftok/rtfdocumentimpl.cxx b/writerfilter/source/rtftok/rtfdocumentimpl.cxx
index 7edeccdcb4e7..bbcec8792bc1 100644
--- a/writerfilter/source/rtftok/rtfdocumentimpl.cxx
+++ b/writerfilter/source/rtftok/rtfdocumentimpl.cxx
@@ -2725,7 +2725,15 @@ RTFError RTFDocumentImpl::beforePopState(RTFParserState& rState)
aAttributes.set(NS_ooxml::LN_EG_RangeMarkupElements_commentRangeEnd, pValue);
writerfilter::Reference<Properties>::Pointer_t pProperties
= new RTFReferenceProperties(aAttributes);
- Mapper().props(pProperties);
+ if (!
+ {
+ Mapper().props(pProperties);
+ }
+ else
+ {
+ auto const pValue2 = new RTFValue(aAttributes, RTFSprms());
+ bufferProperties(*, pValue2, nullptr);
+ }