// xlsxtheme.cpp #include "xlsxtheme_p.h" #include QT_BEGIN_NAMESPACE_XLSX const char *defaultXmlData = "\n" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" ; Theme::Theme(CreateFlag flag) :AbstractOOXmlFile(flag) { } void Theme::saveToXmlFile(QIODevice *device) const { if (xmlData.isEmpty()) device->write(defaultXmlData); else device->write(xmlData); } QByteArray Theme::saveToXmlData() const { if (xmlData.isEmpty()) return defaultXmlData; else return xmlData; } bool Theme::loadFromXmlData(const QByteArray &data) { xmlData = data; return true; } bool Theme::loadFromXmlFile(QIODevice *device) { xmlData = device->readAll(); return true; } QT_END_NAMESPACE_XLSX