Author: shadzik                      Date: Tue Jan 18 13:54:55 2011 GMT
Module: packages                      Tag: HEAD
---- Log message:
- stolen from fedora

---- Files affected:
packages/kde4-koffice:
   kde4-koffice-libwpg02.patch (NONE -> 1.1)  (NEW)

---- Diffs:

================================================================
Index: packages/kde4-koffice/kde4-koffice-libwpg02.patch
diff -u /dev/null packages/kde4-koffice/kde4-koffice-libwpg02.patch:1.1
--- /dev/null   Tue Jan 18 14:54:55 2011
+++ packages/kde4-koffice/kde4-koffice-libwpg02.patch   Tue Jan 18 14:54:50 2011
@@ -0,0 +1,1323 @@
+diff -Nur koffice-2.3.1/filters/karbon/wpg/import/CMakeLists.txt 
koffice-2.3.1-libwpg02/filters/karbon/wpg/import/CMakeLists.txt
+--- koffice-2.3.1/filters/karbon/wpg/import/CMakeLists.txt     2011-01-15 
21:05:35.000000000 +0100
++++ koffice-2.3.1-libwpg02/filters/karbon/wpg/import/CMakeLists.txt    
2011-01-18 07:40:25.000000000 +0100
+@@ -1,16 +1,11 @@
+ 
+-
+ include_directories(${CMAKE_BINARY_DIR}/filters/ ${WPD_INCLUDE_DIR} 
${LIBWPG_INCLUDE_DIR}/)
+ 
+-set(wpgimport_PART_SRCS 
+-WPGImport.cpp 
+-OdgExporter.cxx
+-FileOutputHandler.cxx
+-GraphicsElement.cxx)
++set(wpgimport_PART_SRCS WPGImport.cpp)
+ 
+ kde4_add_plugin(wpgimport ${wpgimport_PART_SRCS})
+ 
+-target_link_libraries(wpgimport komain ${LIBWPG_LIBRARIES} 
${LIBWPG_STREAM_LIBRARIES})
++target_link_libraries(wpgimport komain ${LIBWPG_LIBRARIES} 
${LIBWPG_STREAM_LIBRARIES} ${WPD_LIBRARIES})
+ 
+ install(TARGETS wpgimport DESTINATION ${PLUGIN_INSTALL_DIR})
+ install(FILES karbon_wpg_import.desktop DESTINATION ${SERVICES_INSTALL_DIR})
+diff -Nur koffice-2.3.1/filters/karbon/wpg/import/FileOutputHandler.cxx 
koffice-2.3.1-libwpg02/filters/karbon/wpg/import/FileOutputHandler.cxx
+--- koffice-2.3.1/filters/karbon/wpg/import/FileOutputHandler.cxx      
2011-01-15 21:05:35.000000000 +0100
++++ koffice-2.3.1-libwpg02/filters/karbon/wpg/import/FileOutputHandler.cxx     
1970-01-01 01:00:00.000000000 +0100
+@@ -1,95 +0,0 @@
+-/* libwpg
+- * Copyright (C) 2006 Fridrich Strba ([email protected])
+- *
+- * This library is free software; you can redistribute it and/or
+- * modify it under the terms of the GNU Library General Public
+- * License as published by the Free Software Foundation; either
+- * version 2 of the License, or (at your option) any later version.
+- *
+- * This library is distributed in the hope that it will be useful,
+- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+- * Library General Public License for more details.
+- *
+- * You should have received a copy of the GNU Library General Public
+- * License along with this library; if not, write to the 
+- * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, 
+- * Boston, MA  02111-1301 USA
+- *
+- * For further information visit http://libwpg.sourceforge.net
+- */
+-
+-/* "This product is not manufactured, approved, or supported by
+- * Corel Corporation or Corel Corporation Limited."
+- */
+-
+-#include "FileOutputHandler.hxx"
+-
+-FileOutputHandler::FileOutputHandler(std::ostringstream &contentStream) :
+-      mbIsTagOpened(false),
+-      mContentStream(contentStream)
+-{
+-}
+-
+-void FileOutputHandler::startDocument()
+-{
+-}
+-
+-void FileOutputHandler::startElement(const char *psName, const 
std::vector<std::pair<std::string, std::string> > &xPropList)
+-{
+-      if (mbIsTagOpened)
+-      {
+-              mContentStream << ">";
+-              mbIsTagOpened = false;
+-      }
+-      mContentStream << "<" << psName;
+-
+-      for (std::vector<std::pair<std::string, std::string> >::const_iterator 
i = xPropList.begin(); i != xPropList.end(); i++)
+-      {
+-              mContentStream << " " <<  (*i).first.c_str() << "=\"" << 
(*i).second.c_str() << "\"";
+-      }
+-      mbIsTagOpened = true;
+-      msOpenedTagName = psName;
+-}
+-
+-void FileOutputHandler::endElement(const char *psName)
+-{
+-      if (mbIsTagOpened)
+-      {
+-              if( msOpenedTagName == psName )
+-              {
+-                      mContentStream << "/>";
+-                      mbIsTagOpened = false;
+-              }
+-              else // should not happen, but handle it
+-              {
+-                      mContentStream << ">";
+-                      mContentStream << "</" << psName << ">";
+-                      mbIsTagOpened = false;
+-              }
+-      }
+-      else
+-      {
+-              mContentStream << "</" << psName << ">";
+-              mbIsTagOpened = false;
+-      }
+-}
+-
+-void FileOutputHandler::characters(const std::string &sCharacters)
+-{
+-      if (mbIsTagOpened)
+-      {
+-              mContentStream << ">";
+-              mbIsTagOpened = false;
+-      }
+-      mContentStream << sCharacters.c_str();
+-}
+-
+-void FileOutputHandler::endDocument()
+-{
+-      if (mbIsTagOpened)
+-      {
+-              mContentStream << ">";
+-              mbIsTagOpened = false;
+-      }
+-}
+diff -Nur koffice-2.3.1/filters/karbon/wpg/import/FileOutputHandler.hxx 
koffice-2.3.1-libwpg02/filters/karbon/wpg/import/FileOutputHandler.hxx
+--- koffice-2.3.1/filters/karbon/wpg/import/FileOutputHandler.hxx      
2011-01-15 21:05:35.000000000 +0100
++++ koffice-2.3.1-libwpg02/filters/karbon/wpg/import/FileOutputHandler.hxx     
1970-01-01 01:00:00.000000000 +0100
+@@ -1,49 +0,0 @@
+-/* libwpg
+- * Copyright (C) 2006 Fridrich Strba ([email protected])
+- *
+- * This library is free software; you can redistribute it and/or
+- * modify it under the terms of the GNU Library General Public
+- * License as published by the Free Software Foundation; either
+- * version 2 of the License, or (at your option) any later version.
+- *
+- * This library is distributed in the hope that it will be useful,
+- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+- * Library General Public License for more details.
+- *
+- * You should have received a copy of the GNU Library General Public
+- * License along with this library; if not, write to the 
+- * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, 
+- * Boston, MA  02111-1301 USA
+- *
+- * For further information visit http://libwpg.sourceforge.net
+- */
+-
+-/* "This product is not manufactured, approved, or supported by
+- * Corel Corporation or Corel Corporation Limited."
+- */
+-
+-#ifndef FILEOUTPUTHANDLER_H
+-#define FILEOUTPUTHANDLER_H
+-
+-#include <iostream>
+-#include <sstream>
+-#include <string>
+-#include "GraphicsHandler.hxx"
+-
+-class FileOutputHandler : public GraphicsHandler
+-{
+-  public:
+-        explicit FileOutputHandler(std::ostringstream &contentStream);
+-        virtual void startDocument();
+-        virtual void endDocument();
+-        virtual void startElement(const char *psName, const 
std::vector<std::pair<std::string, std::string> > &xPropList);
+-        virtual void endElement(const char *psName);
+-        virtual void characters(const std::string &sCharacters);
+-
+-  private:
+-      bool mbIsTagOpened;
+-      std::string msOpenedTagName;
+-      std::ostringstream &mContentStream;
+-};
+-#endif
+diff -Nur koffice-2.3.1/filters/karbon/wpg/import/GraphicsElement.cxx 
koffice-2.3.1-libwpg02/filters/karbon/wpg/import/GraphicsElement.cxx
+--- koffice-2.3.1/filters/karbon/wpg/import/GraphicsElement.cxx        
2011-01-15 21:05:35.000000000 +0100
++++ koffice-2.3.1-libwpg02/filters/karbon/wpg/import/GraphicsElement.cxx       
1970-01-01 01:00:00.000000000 +0100
+@@ -1,66 +0,0 @@
+-/* GraphicsElement: The items we are collecting to be put into the Writer
+- * document: paragraph and spans of text, as well as section breaks.
+- *
+- * Copyright (C) 2002-2003 William Lachance ([email protected])
+- * 
+- * This program is free software; you can redistribute it and/or
+- * modify it under the terms of the GNU Lesser General Public
+- * License as published by the Free Software Foundation; either
+- * version 2 of the License, or (at your option) any later version.
+- *
+- * This program is distributed in the hope that it will be useful,
+- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+- * Library General Public License for more details.
+- *
+- * You should have received a copy of the GNU Library General Public
+- * License along with this library; if not, write to the 
+- * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, 
+- * Boston, MA  02111-1301 USA
+- *
+- * For further information visit http://libwpg.sourceforge.net
+- *
+- */
+-
+-/* "This product is not manufactured, approved, or supported by 
+- * Corel Corporation or Corel Corporation Limited."
+- */
+-
+-#include "GraphicsElement.hxx"
+-#include "GraphicsHandler.hxx"
+-#include <string.h>
+-
+-#define ASCII_SPACE 0x0020
+-
+-void TagGraphicsElement::print() const
+-{
+-}
+-
+-void OpenTagGraphicsElement::write(GraphicsHandler *pHandler) const
+-{
+-      pHandler->startElement(getTagName().c_str(), maAttrList);
+-}
+-
+-void OpenTagGraphicsElement::print() const
+-{ 
+-      TagGraphicsElement::print();    
+-}
+-
+-void OpenTagGraphicsElement::addAttribute(const std::string &szAttributeName, 
const std::string &sAttributeValue)
+-{
+-      std::pair<std::string, std::string> tmpAttribute;
+-      tmpAttribute.first = szAttributeName;
+-      tmpAttribute.second = sAttributeValue;
+-        maAttrList.push_back(tmpAttribute);
+-}
+-
+-void CloseTagGraphicsElement::write(GraphicsHandler *pHandler) const
+-{
+-
+-      pHandler->endElement(getTagName().c_str());
+-}
+-
+-void CharDataGraphicsElement::write(GraphicsHandler *pHandler) const
+-{
+-      pHandler->characters(msData);
+-}
+diff -Nur koffice-2.3.1/filters/karbon/wpg/import/GraphicsElement.hxx 
koffice-2.3.1-libwpg02/filters/karbon/wpg/import/GraphicsElement.hxx
+--- koffice-2.3.1/filters/karbon/wpg/import/GraphicsElement.hxx        
2011-01-15 21:05:35.000000000 +0100
++++ koffice-2.3.1-libwpg02/filters/karbon/wpg/import/GraphicsElement.hxx       
1970-01-01 01:00:00.000000000 +0100
+@@ -1,84 +0,0 @@
+-/* GraphicsElement: The items we are collecting to be put into the Writer
+- * document: paragraph and spans of text, as well as section breaks.
+- *
+- * Copyright (C) 2002-2003 William Lachance ([email protected])
+- * 
+- * This program is free software; you can redistribute it and/or
+- * modify it under the terms of the GNU Lesser General Public
+- * License as published by the Free Software Foundation; either
+- * version 2 of the License, or (at your option) any later version.
+- *
+- * This program is distributed in the hope that it will be useful,
+- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+- * Library General Public License for more details.
+- *
+- * You should have received a copy of the GNU Library General Public
+- * License along with this library; if not, write to the 
+- * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, 
+- * Boston, MA  02111-1301 USA
+- *
+- * For further information visit http://libwpd.sourceforge.net
+- *
+- */
+-
+-/* "This product is not manufactured, approved, or supported by 
+- * Corel Corporation or Corel Corporation Limited."
+- */
+-
+-#ifndef _GRAPHICSELEMENT_H
+-#define _GRAPHICSELEMENT_H
+-#include <string>
+-#include <map>
+-#include <vector>
+-
+-#include "GraphicsHandler.hxx"
+-
+-class GraphicsElement
+-{
+-public:       
+-      virtual ~GraphicsElement() {}
+-      virtual void write(GraphicsHandler *pHandler) const = 0;
+-      virtual void print() const {}
+-};
+-
+-class TagGraphicsElement : public GraphicsElement
+-{
+-public:
+-      explicit TagGraphicsElement(const char *szTagName) : 
msTagName(szTagName) {}
+-      const std::string &getTagName() const { return msTagName; }
+-      virtual void print() const;
+-private:
+-      const std::string msTagName;
+-};
+-
+-class OpenTagGraphicsElement : public TagGraphicsElement
+-{
+-public:
+-      explicit OpenTagGraphicsElement(const char *szTagName) : 
TagGraphicsElement(szTagName) {}
+-      ~OpenTagGraphicsElement() {}
+-      void addAttribute(const std::string &szAttributeName, const std::string 
&sAttributeValue);
+-      virtual void write(GraphicsHandler *pHandler) const;
+-      virtual void print () const;
+-private:
+-      std::vector<std::pair<std::string, std::string> > maAttrList;
+-};
+-
+-class CloseTagGraphicsElement : public TagGraphicsElement
+-{
+-public:
+-      explicit CloseTagGraphicsElement(const char *szTagName) : 
TagGraphicsElement(szTagName) {}
+-      virtual void write(GraphicsHandler *pHandler) const;
+-};
+-
+-class CharDataGraphicsElement : public GraphicsElement
+-{
+-public:
+-      CharDataGraphicsElement(const char *sData) : GraphicsElement(), 
msData(sData) {}
+-      virtual void write(GraphicsHandler *pHandler) const;
+-private:
+-      std::string msData;
+-};
+-
+-
+-#endif
+diff -Nur koffice-2.3.1/filters/karbon/wpg/import/GraphicsHandler.hxx 
koffice-2.3.1-libwpg02/filters/karbon/wpg/import/GraphicsHandler.hxx
+--- koffice-2.3.1/filters/karbon/wpg/import/GraphicsHandler.hxx        
2011-01-15 21:05:35.000000000 +0100
++++ koffice-2.3.1-libwpg02/filters/karbon/wpg/import/GraphicsHandler.hxx       
1970-01-01 01:00:00.000000000 +0100
+@@ -1,43 +0,0 @@
+-/*
+- * Copyright (C) 2004 William Lachance ([email protected])
+- * Copyright (C) 2004 Net Integration Technologies (http://www.net-itech.com)
+- *
+- * This program is free software; you can redistribute it and/or
+- * modify it under the terms of the GNU General Public License
+- * as published by the Free Software Foundation; either version 2
+- * of the License, or (at your option) any later version.
+- *
+- * This program is distributed in the hope that it will be useful,
+- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+- * GNU General Public License for more details.
+- *
+- * You should have received a copy of the GNU Library General Public
+- * License along with this library; if not, write to the 
+- * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, 
+- * Boston, MA  02111-1301 USA
+- *
+- *  Contributor(s): Martin Gallwey ([email protected])
+- *
+- */
+-
+-/* "This product is not manufactured, approved, or supported by
+- * Corel Corporation or Corel Corporation Limited."
+- */
+-#ifndef _GRAPHICSHANDLER_H
+-#define _GRAPHICSHANDLER_H
+-#include <string>
+-#include <map>
+-#include <vector>
+-
+-class GraphicsHandler
+-{
+-public:
+-      virtual ~GraphicsHandler() {}
+-        virtual void startDocument() = 0;
+-        virtual void endDocument() = 0;
+-        virtual void startElement(const char *psName, const std::vector< 
std::pair <std::string, std::string> > &xPropList) = 0;
+-        virtual void endElement(const char *psName) = 0;
+-        virtual void characters(const std::string &sCharacters) = 0;
+-};
+-#endif
+diff -Nur koffice-2.3.1/filters/karbon/wpg/import/OdgExporter.cxx 
koffice-2.3.1-libwpg02/filters/karbon/wpg/import/OdgExporter.cxx
+--- koffice-2.3.1/filters/karbon/wpg/import/OdgExporter.cxx    2011-01-15 
21:05:35.000000000 +0100
++++ koffice-2.3.1-libwpg02/filters/karbon/wpg/import/OdgExporter.cxx   
1970-01-01 01:00:00.000000000 +0100
+@@ -1,662 +0,0 @@
+-/* libwpg
+- * Copyright (C) 2006 Ariya Hidayat ([email protected])
+- * Copyright (C) 2006 Fridrich Strba ([email protected])
+- *
+- * This library is free software; you can redistribute it and/or
+- * modify it under the terms of the GNU Library General Public
+- * License as published by the Free Software Foundation; either
+- * version 2 of the License, or (at your option) any later version.
+- *
+- * This library is distributed in the hope that it will be useful,
+- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+- * Library General Public License for more details.
+- *
+- * You should have received a copy of the GNU Library General Public
+- * License along with this library; if not, write to the
+- * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+- * Boston, MA  02111-1301 USA
+- *
+- * For further information visit http://libwpg.sourceforge.net
+- */
+-
+-/* "This product is not manufactured, approved, or supported by
+- * Corel Corporation or Corel Corporation Limited."
+- */
+-
+-#include "OdgExporter.hxx"
+-#include "GraphicsElement.hxx"
+-#include "GraphicsHandler.hxx"
+-#include <locale.h>
+-
+-static std::string doubleToString(const double value)
+-{
+-  std::ostringstream tempStream;
+-  tempStream << value;
+-  std::string decimalPoint(localeconv()->decimal_point);
+-  if ((decimalPoint.size() == 0) || (decimalPoint == "."))
+-    return tempStream.str();
+-  std::string stringValue(tempStream.str());
+-  if (!stringValue.empty())
+-  {
+-    std::string::size_type pos;
+-    while ((pos = stringValue.find(decimalPoint)) != std::string::npos)
+-          stringValue.replace(pos,decimalPoint.size(),".");
+-  }
+-  return stringValue;
+-}
+-
+-
+-OdgExporter::OdgExporter(GraphicsHandler *pHandler, const bool isFlatXML):
+-        mpHandler(pHandler),
+-        m_fillRule(AlternatingFill),
+-        m_gradientIndex(1),
+-        m_dashIndex(1),
+-        m_styleIndex(1),
+-        m_width(0.0f),
+-        m_height(0.0f),
+-        m_isFlatXML(isFlatXML)
+-{
+-}
+-
+-OdgExporter::~OdgExporter()
+-{
+-        for (std::vector <GraphicsElement *>::iterator iterStroke = 
mStrokeDashElements.begin();
+-                iterStroke != mStrokeDashElements.end(); iterStroke++)
+-                delete (*iterStroke);
+-
+-        for (std::vector <GraphicsElement *>::iterator iterGradient = 
mGradientElements.begin();
+-                iterGradient != mGradientElements.end(); iterGradient++)
+-                delete (*iterGradient);
+-
+-        for (std::vector <GraphicsElement *>::iterator iterAutomaticStyles = 
mAutomaticStylesElements.begin();
+-                iterAutomaticStyles != mAutomaticStylesElements.end(); 
iterAutomaticStyles++)
+-                delete (*iterAutomaticStyles);
+-
+-        for (std::vector<GraphicsElement *>::iterator bodyIter = 
mBodyElements.begin();
+-                bodyIter != mBodyElements.end(); bodyIter++)
+-                delete (*bodyIter);
+-}
+-
+-void OdgExporter::startGraphics(double width, double height)
+-{
+-        m_gradientIndex = 1;
+-        m_dashIndex = 1;
+-        m_styleIndex = 1;
+-        m_width = width;
+-        m_height = height;
+-
+-
+-        mpHandler->startDocument();
+-        OpenTagGraphicsElement tmpOfficeDocumentContent("office:document");
+-        tmpOfficeDocumentContent.addAttribute("xmlns:office", 
"urn:oasis:names:tc:opendocument:xmlns:office:1.0");
+-        tmpOfficeDocumentContent.addAttribute("xmlns:style", 
"urn:oasis:names:tc:opendocument:xmlns:style:1.0");
+-        tmpOfficeDocumentContent.addAttribute("xmlns:text", 
"urn:oasis:names:tc:opendocument:xmlns:text:1.0");
+-        tmpOfficeDocumentContent.addAttribute("xmlns:draw", 
"urn:oasis:names:tc:opendocument:xmlns:drawing:1.0");
+-        tmpOfficeDocumentContent.addAttribute("xmlns:dc", 
"http://purl.org/dc/elements/1.1/";);
+-        tmpOfficeDocumentContent.addAttribute("xmlns:svg", 
"urn:oasis:names:tc:opendocument:xmlns:svg-compatible:1.0");
+-        tmpOfficeDocumentContent.addAttribute("xmlns:fo", 
"urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compatible:1.0");
+-        tmpOfficeDocumentContent.addAttribute("xmlns:config", 
"urn:oasis:names:tc:opendocument:xmlns:config:1.0");
+-        tmpOfficeDocumentContent.addAttribute("xmlns:ooo", 
"http://openoffice.org/2004/office";);
+-        tmpOfficeDocumentContent.addAttribute("office:version", "1.0");
+-        if (m_isFlatXML)
+-                        
tmpOfficeDocumentContent.addAttribute("office:mimetype", 
"application/x-vnd.oasis.openoffice.drawing");
+-        tmpOfficeDocumentContent.write(mpHandler);
+-
+-        OpenTagGraphicsElement("office:settings").write(mpHandler);
+-
+-        OpenTagGraphicsElement 
configItemSetOpenElement("config:config-item-set");
+-        configItemSetOpenElement.addAttribute("config:name", 
"ooo:view-settings");
+-        configItemSetOpenElement.write(mpHandler);
+-
+-        OpenTagGraphicsElement configItemOpenElement1("config:config-item");
+-        configItemOpenElement1.addAttribute("config:name", "VisibleAreaTop");
+-        configItemOpenElement1.addAttribute("config:type", "int");
+-        configItemOpenElement1.write(mpHandler);
+-        mpHandler->characters("0");
+-        mpHandler->endElement("config:config-item");
+-
+-        OpenTagGraphicsElement configItemOpenElement2("config:config-item");
+-        configItemOpenElement2.addAttribute("config:name", "VisibleAreaLeft");
+-        configItemOpenElement2.addAttribute("config:type", "int");
+-        configItemOpenElement2.write(mpHandler);
+-        mpHandler->characters("0");
+-        mpHandler->endElement("config:config-item");
+-
+-        OpenTagGraphicsElement configItemOpenElement3("config:config-item");
+-        configItemOpenElement3.addAttribute("config:name", 
"VisibleAreaWidth");
+-        configItemOpenElement3.addAttribute("config:type", "int");
+-        configItemOpenElement3.write(mpHandler);
+-        m_value.str("");
+-        m_value << (unsigned)(2540 * width);
+-        mpHandler->characters(m_value.str());
+-        mpHandler->endElement("config:config-item");
+-
+-        OpenTagGraphicsElement configItemOpenElement4("config:config-item");
+-        configItemOpenElement4.addAttribute("config:name", 
"VisibleAreaHeight");
+-        configItemOpenElement4.addAttribute("config:type", "int");
+-        configItemOpenElement4.write(mpHandler);
+-        m_value.str("");
+-        m_value << (unsigned)(2540 * height);
+-        mpHandler->characters(m_value.str());
+-        mpHandler->endElement("config:config-item");
+-
+-        mpHandler->endElement("config:config-item-set");
+-
+-        mpHandler->endElement("office:settings");
+-
+-}
+-
+-void OdgExporter::endGraphics()
+-{
+-        OpenTagGraphicsElement("office:styles").write(mpHandler);
+-
+-        for (std::vector <GraphicsElement *>::const_iterator iterStroke = 
mStrokeDashElements.begin();
+-                iterStroke != mStrokeDashElements.end(); iterStroke++)
+-                (*iterStroke)->write(mpHandler);
+-
+-        for (std::vector <GraphicsElement *>::const_iterator iterGradient = 
mGradientElements.begin();
+-                iterGradient != mGradientElements.end(); iterGradient++)
+-                (*iterGradient)->write(mpHandler);
+-
+-        mpHandler->endElement("office:styles");
+-
+-        OpenTagGraphicsElement("office:automatic-styles").write(mpHandler);
+-
+-        for (std::vector <GraphicsElement *>::const_iterator 
iterAutomaticStyles = mAutomaticStylesElements.begin();
+-                iterAutomaticStyles != mAutomaticStylesElements.end(); 
iterAutomaticStyles++)
+-                (*iterAutomaticStyles)->write(mpHandler);
+-
+-        OpenTagGraphicsElement 
tmpStylePageLayoutOpenElement("style:page-layout");
+-        tmpStylePageLayoutOpenElement.addAttribute("style:name", "PM0");
+-        tmpStylePageLayoutOpenElement.write(mpHandler);
+-
+-        OpenTagGraphicsElement 
tmpStylePageLayoutPropertiesOpenElement("style:page-layout-properties");
+-        tmpStylePageLayoutPropertiesOpenElement.addAttribute("fo:margin-top", 
"0in");
+-        
tmpStylePageLayoutPropertiesOpenElement.addAttribute("fo:margin-bottom", "0in");
+-        
tmpStylePageLayoutPropertiesOpenElement.addAttribute("fo:margin-left", "0in");
+-        
tmpStylePageLayoutPropertiesOpenElement.addAttribute("fo:margin-right", "0in");
+-        m_value.str("");
+-        m_value <<  doubleToString(m_width) << "in";
+-        tmpStylePageLayoutPropertiesOpenElement.addAttribute("fo:page-width", 
m_value.str());
+-        m_value.str("");
+-        m_value << doubleToString(m_height)  << "in";
+-        
tmpStylePageLayoutPropertiesOpenElement.addAttribute("fo:page-height", 
m_value.str());
+-        m_value.str("");
+-        
tmpStylePageLayoutPropertiesOpenElement.addAttribute("style:print-orientation", 
"portrait");
+-        tmpStylePageLayoutPropertiesOpenElement.write(mpHandler);
+-
+-        mpHandler->endElement("style:page-layout-properties");
+-
+-        mpHandler->endElement("style:page-layout");
+-
+-        OpenTagGraphicsElement tmpStyleStyleOpenElement("style:style");
+-        tmpStyleStyleOpenElement.addAttribute("style:name", "dp1");
+-        tmpStyleStyleOpenElement.addAttribute("style:family", "drawing-page");
+-        tmpStyleStyleOpenElement.write(mpHandler);
+-
+-        OpenTagGraphicsElement 
tmpStyleDrawingPagePropertiesOpenElement("style:drawing-page-properties");
+-        // 
tmpStyleDrawingPagePropertiesOpenElement.addAttribute("draw:background-size", 
"border");
+-        tmpStyleDrawingPagePropertiesOpenElement.addAttribute("draw:fill", 
"none");
+-        tmpStyleDrawingPagePropertiesOpenElement.write(mpHandler);
+-
+-        mpHandler->endElement("style:drawing-page-properties");
+-
+-        mpHandler->endElement("style:style");
+-
+-        mpHandler->endElement("office:automatic-styles");
+-
<<Diff was trimmed, longer than 597 lines>>
_______________________________________________
pld-cvs-commit mailing list
[email protected]
http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit

Reply via email to