Kaydet (Commit) fe5b3c33 authored tarafından Ravindra Vidhate's avatar Ravindra Vidhate Kaydeden (comit) Miklos Vajna

fdo#79915:Text Data Lost after exporting through LO

In the OutputTextNode, the text data is postponed when the in case of
NOT_PROCESSED state of fly frame. This text data is never been processed
later.

When the text data is postponed we should write this before processing
the next text node.

Change-Id: Ib8d5fdcf8dcfb9ff394d32103502150e08bbd521
Reviewed-on: https://gerrit.libreoffice.org/9737Reviewed-by: 's avatarMiklos Vajna <vmiklos@collabora.co.uk>
Tested-by: 's avatarMiklos Vajna <vmiklos@collabora.co.uk>
üst 3f4ea7a6
...@@ -3617,6 +3617,15 @@ DECLARE_OOXMLEXPORT_TEST(testfdo79822, "fdo79822.docx") ...@@ -3617,6 +3617,15 @@ DECLARE_OOXMLEXPORT_TEST(testfdo79822, "fdo79822.docx")
return; return;
} }
DECLARE_OOXMLEXPORT_TEST(testFDO79915, "fdo79915.docx")
{
xmlDocPtr pXmlDoc = parseExport("word/document.xml");
if (!pXmlDoc)
return;
assertXPathContent(pXmlDoc, "/w:document/w:body/w:p[2]/w:r[8]/w:t", "How much buoyancy does the water provide?");
}
DECLARE_OOXMLEXPORT_TEST(testfdo79817,"fdo79817.docx") DECLARE_OOXMLEXPORT_TEST(testfdo79817,"fdo79817.docx")
{ {
xmlDocPtr pXmlDoc = parseExport("word/document.xml"); xmlDocPtr pXmlDoc = parseExport("word/document.xml");
......
...@@ -2320,6 +2320,13 @@ void MSWordExportBase::OutputTextNode( const SwTxtNode& rNode ) ...@@ -2320,6 +2320,13 @@ void MSWordExportBase::OutputTextNode( const SwTxtNode& rNode )
AttrOutput().RunText( aSavedSnippet, eChrSet ); AttrOutput().RunText( aSavedSnippet, eChrSet );
AttrOutput().EndRun(); AttrOutput().EndRun();
} }
else if( bPostponeWritingText && FLY_NOT_PROCESSED == nStateOfFlyFrame )
{
//write the postponed text run
bPostponeWritingText = false ;
AttrOutput().RunText( aSavedSnippet, eChrSet );
AttrOutput().EndRun();
}
else else
AttrOutput().EndRun(); AttrOutput().EndRun();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment