diff -r 000000000000 -r 58e7594239df misc.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/misc.h Tue Aug 01 09:31:22 2006 +0000 @@ -0,0 +1,64 @@ +#ifndef MISC_H +#define MISC_H + +#include +#include + +using namespace std; + +#define Z_BBOX 0 +#define Z_LINK 20 +#define Z_FRAME 50 +#define Z_SELBOX 60 +#define Z_ICON 80 +#define Z_TEXT 100 + +enum LoadMode {NewMap,ImportAdd,ImportReplace}; +enum SaveMode {PartOfMap,CompleteMap}; + +///////////////////////////////////////////////////////////////////////////// +extern ostream &operator<< (ostream &stream, QPoint const &p); +float getAngle(const QPoint &); +QPoint normalise (const QPoint &); +QString maskPath (QString ); +QString convertToRel (const QString &,const QString &); +QString quotemeta(const QString&); +int max (int,int); +class BranchObj; +class MapEditor; + +///////////////////////////////////////////////////////////////////////////// +class xmlObj +{ +public: + xmlObj(); + QString singleElement(QString,QString); + QString beginElement(QString,QString); + QString beginElement(QString); + QString endElement (QString); + QString attribut (QString,QString); + QString valueElement(QString,QString); + QString valueElement(QString,QString,QString); + void incIndent(); + void decIndent(); + static int actindent; + +protected: + QString indent(); + int indentwidth; +}; + +///////////////////////////////////////////////////////////////////////////// + +#include +#include +#include + +class ImagePreview : public QLabel, public QFilePreview +{ +public: + ImagePreview( QWidget * ); + void previewUrl( const QUrl & ); +}; + +#endif