Warning, file /office/calligra/libs/flake/KoDragOdfSaveHelper.h was not indexed or was modified since last indexation (in which case cross-reference links may be missing, inaccurate or erroneous).

0001 /* This file is part of the KDE project
0002  * Copyright ( C ) 2007 Thorsten Zachmann <zachmann@kde.org>
0003  *
0004  * This library is free software; you can redistribute it and/or
0005  * modify it under the terms of the GNU Library General Public
0006  * License as published by the Free Software Foundation; either
0007  * version 2 of the License, or (at your option) any later version.
0008  *
0009  * This library is distributed in the hope that it will be useful,
0010  * but WITHOUT ANY WARRANTY; without even the implied warranty of
0011  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
0012  * Library General Public License for more details.
0013  *
0014  * You should have received a copy of the GNU Library General Public License
0015  * along with this library; see the file COPYING.LIB.  If not, write to
0016  * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
0017  * Boston, MA 02110-1301, USA.
0018  */
0019 
0020 #ifndef KODRAGODFSAVEHELPER_H
0021 #define KODRAGODFSAVEHELPER_H
0022 
0023 #include "flake_export.h"
0024 
0025 #include <QtGlobal>
0026 
0027 class KoShapeSavingContext;
0028 class KoXmlWriter;
0029 class KoGenStyles;
0030 class KoEmbeddedDocumentSaver;
0031 class KoDragOdfSaveHelperPrivate;
0032 
0033 class FLAKE_EXPORT KoDragOdfSaveHelper
0034 {
0035 public:
0036     KoDragOdfSaveHelper();
0037     virtual ~KoDragOdfSaveHelper();
0038 
0039     /**
0040      * Create and return the context used for saving
0041      *
0042      * If you need a special context for saving you can reimplent this function.
0043      * The default implementation return a KoShapeSavingContext.
0044      *
0045      * The returned context is valid as long as the KoDragOdfSaveHelper is existing
0046      */
0047     virtual KoShapeSavingContext *context(KoXmlWriter *bodyWriter, KoGenStyles &mainStyles, KoEmbeddedDocumentSaver &embeddedSaver);
0048 
0049     /**
0050      * This method is called for writing the body of odf document.
0051      *
0052      * You need to have created a context before calling this function
0053      */
0054     virtual bool writeBody() = 0;
0055 
0056 protected:
0057     /// constructor
0058     KoDragOdfSaveHelper(KoDragOdfSaveHelperPrivate &);
0059 
0060     KoDragOdfSaveHelperPrivate *d_ptr;
0061 
0062 private:
0063     Q_DECLARE_PRIVATE(KoDragOdfSaveHelper)
0064 };
0065 
0066 #endif /* KODRAGODFSAVEHELPER_H */