[Libreoffice-commits] .: writerperfect/source

Fridrich Strba fridrich at kemper.freedesktop.org
Thu Jan 12 03:23:25 PST 2012


 writerperfect/source/filter/OdgGenerator.cxx |    8 ++++++++
 1 file changed, 8 insertions(+)

New commits:
commit b9e50a307122b6d16f43581f128a782ba10e3f7f
Author: Fridrich Å trba <fridrich.strba at bluewin.ch>
Date:   Thu Jan 12 12:15:29 2012 +0100

    Consider the style:mirror property

diff --git a/writerperfect/source/filter/OdgGenerator.cxx b/writerperfect/source/filter/OdgGenerator.cxx
index 4d70f8d..584e8cc 100644
--- a/writerperfect/source/filter/OdgGenerator.cxx
+++ b/writerperfect/source/filter/OdgGenerator.cxx
@@ -950,10 +950,16 @@ void OdgGenerator::drawGraphicObject(const ::WPXPropertyList &propList, const ::
 {
     if (!propList["libwpg:mime-type"] && propList["libwpg:mime-type"]->getStr().len() <= 0)
         return;
+
+    mpImpl->_writeGraphicsStyle();
+
     TagOpenElement *pDrawFrameElement = new TagOpenElement("draw:frame");
 
 
     WPXString sValue;
+    sValue.sprintf("gr%i", mpImpl->miGraphicsStyleIndex-1);
+    pDrawFrameElement->addAttribute("draw:style-name", sValue);
+
     if (propList["svg:x"])
         pDrawFrameElement->addAttribute("svg:x", propList["svg:x"]->getStr());
     if (propList["svg:y"])
@@ -1280,6 +1286,8 @@ void OdgGeneratorPrivate::_writeGraphicsStyle()
         else
             pStyleGraphicsPropertiesElement->addAttribute("draw:marker-end-width", "0.118in");
     }
+    if (mxStyle["style:mirror"])
+        pStyleGraphicsPropertiesElement->addAttribute("style:mirror", mxStyle["style:mirror"]->getStr());
 
     mGraphicsAutomaticStyles.push_back(pStyleGraphicsPropertiesElement);
     mGraphicsAutomaticStyles.push_back(new TagCloseElement("style:graphic-properties"));


More information about the Libreoffice-commits mailing list