Summary: | KOffice 1.6: formulas lost in saved document | ||
---|---|---|---|
Product: | [Applications] calligraformula | Reporter: | Yuriy Kozlov <yuriy.kozlov> |
Component: | general | Assignee: | Alfredo Beaumont <alfredo.beaumont> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | alfredo.beaumont |
Priority: | NOR | ||
Version: | 1.x | ||
Target Milestone: | --- | ||
Platform: | Ubuntu | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Attachments: |
the test file
a screenshot where commas are inserted |
Description
Yuriy Kozlov
2006-09-14 03:59:10 UTC
Created attachment 17761 [details]
the test file
This contains one formula, created in KWord, that appears in OpenOffice but not
in KWord.
Created attachment 17762 [details]
a screenshot where commas are inserted
Thanks for your report, I can confirm it. Hope to fix later today. SVN commit 584398 by abeaumont: OpenDocument: Fix saving <semantics>, it does not infer mrows, so mrow is manually added. BUG: 134044 M +9 -4 formulaelement.cc --- branches/koffice/1.6/koffice/lib/kformula/formulaelement.cc #584397:584398 @@ -316,16 +316,21 @@ void FormulaElement::writeMathML( QDomDocument& doc, QDomNode& parent, bool oasisFormat ) const { QDomElement de; - if ( !oasisFormat ) + if ( !oasisFormat ) { de = doc.createElementNS( "http://www.w3.org/1998/Math/MathML", "math" ); - else - de =doc.createElement( "math:semantics" ); + parent.appendChild( de ); + } + else { + QDomElement element = doc.createElement( "math:semantics" ); + de = doc.createElement( "math:mrow" ); + parent.appendChild( element ); + element.appendChild( de ); + } for ( uint i = 0; i < countChildren(); ++i ) { const BasicElement* e = getChild( i ); e->writeMathML( doc, de, oasisFormat ); } - parent.appendChild( de ); } KFORMULA_NAMESPACE_END |