xmloff/source/text/txtflde.cxx |   28 +++++++++++++++++-----------
 1 file changed, 17 insertions(+), 11 deletions(-)

New commits:
commit 49f9694e34d07468cff4a7e4de332f11be3e0dd8
Author: Eike Rathke <er...@redhat.com>
Date:   Fri Dec 13 23:30:34 2013 +0100

    fdo#72697 actually write this only in ODF 1.2 extended
    
    Change-Id: I32097cc4b8a67615b0b6d6172cafd0edad7469b6

diff --git a/xmloff/source/text/txtflde.cxx b/xmloff/source/text/txtflde.cxx
index 63f5cc9..6f476c4 100644
--- a/xmloff/source/text/txtflde.cxx
+++ b/xmloff/source/text/txtflde.cxx
@@ -1752,14 +1752,17 @@ void XMLTextFieldExport::ExportFieldHelper(
             GetExport().Characters(aBuffer.makeStringAndClear());
         }
 
-        // initials
-        OUString aInitials( GetStringProperty(sPropertyInitials, rPropSet) );
-        if( !aInitials.isEmpty() )
+        if (SvtSaveOptions().GetODFDefaultVersion() > 
SvtSaveOptions::ODFVER_012)
         {
-            SvXMLElementExport aCreatorElem( GetExport(), XML_NAMESPACE_LO_EXT,
-                                              XML_SENDER_INITIALS, sal_True,
-                                              sal_False );
-            GetExport().Characters(aInitials);
+            // initials
+            OUString aInitials( GetStringProperty(sPropertyInitials, rPropSet) 
);
+            if( !aInitials.isEmpty() )
+            {
+                SvXMLElementExport aCreatorElem( GetExport(), 
XML_NAMESPACE_LO_EXT,
+                        XML_SENDER_INITIALS, sal_True,
+                        sal_False );
+                GetExport().Characters(aInitials);
+            }
         }
 
         com::sun::star::uno::Reference < com::sun::star::text::XText > xText;
@@ -2228,10 +2231,13 @@ void XMLTextFieldExport::ExportElement(enum 
XMLTokenEnum eElementName,
         // Element
         if (eElementName == XML_SENDER_INITIALS)
         {
-            SvXMLElementExport aElem( GetExport(), XML_NAMESPACE_LO_EXT,
-                                      eElementName, bAddSpace, bAddSpace );
-            // export content
-            GetExport().Characters(sContent);
+            if (SvtSaveOptions().GetODFDefaultVersion() > 
SvtSaveOptions::ODFVER_012)
+            {
+                SvXMLElementExport aElem( GetExport(), XML_NAMESPACE_LO_EXT,
+                        eElementName, bAddSpace, bAddSpace );
+                // export content
+                GetExport().Characters(sContent);
+            }
         }
         else
         {
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to