]> git.sesse.net Git - kdenlive/blobdiff - src/titledocument.h
Show image path for title clips
[kdenlive] / src / titledocument.h
index fab51a5e63a642ee78446571a4983f216d7b4e84..e8bad6b7844fac619286b5ab189871e3a10c0c64 100644 (file)
  ***************************************************************************/
 #ifndef TITLEDOCUMENT_H
 #define TITLEDOCUMENT_H
+
+#include <QDomDocument>
+
 #include <KUrl>
 
 class QGraphicsScene;
 class QGraphicsPolygonItem;
 
-class TitleDocument {
+class TitleDocument
+{
     QGraphicsScene* scene;
 public:
     TitleDocument();
     void setScene(QGraphicsScene* scene);
     bool saveDocument(const KUrl& url, QGraphicsPolygonItem* startv, QGraphicsPolygonItem* endv);
-    bool loadDocument(const KUrl& url, QGraphicsPolygonItem* startv, QGraphicsPolygonItem* endv);
+    int loadDocument(const KUrl& url, QGraphicsPolygonItem* startv, QGraphicsPolygonItem* endv);
+    QDomDocument xml(QGraphicsPolygonItem* startv, QGraphicsPolygonItem* endv);
+    int loadFromXml(QDomDocument doc, QGraphicsPolygonItem* startv, QGraphicsPolygonItem* endv);
+    /** \brief Get the background color (incl. alpha) from the document, if possibly
+     * \returns The background color of the document, inclusive alpha. If none found, returns (0,0,0,0) */
+    QColor getBackgroundColor();
+
 private:
     QString colorToString(const QColor&);
     QString rectFToString(const QRectF&);