umlviewimageexportermodel.h
00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012 #ifndef UMLVIEWIMAGEEXPORTERMODEL_H
00013 #define UMLVIEWIMAGEEXPORTERMODEL_H
00014
00015 #include <qstringlist.h>
00016 #include <qrect.h>
00017
00018
00019 class UMLView;
00020
00021
00022 class KTempFile;
00023 class KURL;
00024
00035 class UMLViewImageExporterModel {
00036 public:
00037
00044 static QStringList supportedImageTypes();
00045
00052 static QStringList supportedMimeTypes();
00053
00062 static QString imageTypeToMimeType(const QString& imageType);
00063
00072 static QString mimeTypeToImageType(const QString& mimeType);
00073
00077 UMLViewImageExporterModel() {
00078 }
00079
00083 virtual ~UMLViewImageExporterModel() {
00084 }
00085
00108 QStringList exportAllViews(const QString &imageType, const KURL &directory, bool useFolders) const;
00109
00125 QString exportView(UMLView* view, const QString &imageType, const KURL &url) const;
00126
00127 private:
00128
00145 QString getDiagramFileName(UMLView *view, const QString &imageType, bool useFolders = false) const;
00146
00155 bool prepareDirectory(const KURL &url) const;
00156
00166 bool exportViewTo(UMLView* view, const QString &imageType, const QString &fileName) const;
00167
00178 bool exportViewToEps(UMLView* view, const QString &fileName, bool isEPS) const;
00179
00188 bool fixEPS(const QString &fileName, QRect rect) const;
00189
00198 bool exportViewToSvg(UMLView* view, const QString &fileName) const;
00199
00210 bool exportViewToPixmap(UMLView* view, const QString &imageType, const QString &fileName) const;
00211
00212 };
00213
00214 #endif
This file is part of the documentation for umbrello Version 3.1.0.