diff options
author | 2023-09-09 20:09:50 -0400 | |
---|---|---|
committer | 2023-09-09 20:09:50 -0400 | |
commit | 93cf929f29dea490ed60e5300cacdd99886c988e (patch) | |
tree | 0f8669c56e22a287047ee20846b92f1580d7364f /mapman/src/painter.hpp | |
parent | 40432e083b11271cf3148b9c38156cf759436699 (diff) | |
download | meteor-trashy-addon-93cf929f29dea490ed60e5300cacdd99886c988e.tar.xz |
Add the standalone portion of mapman.
Diffstat (limited to 'mapman/src/painter.hpp')
-rw-r--r-- | mapman/src/painter.hpp | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/mapman/src/painter.hpp b/mapman/src/painter.hpp new file mode 100644 index 0000000..489a87b --- /dev/null +++ b/mapman/src/painter.hpp @@ -0,0 +1,34 @@ +#ifndef MAPPAINTER_HPP +#define MAPPAINTER_HPP + +#include <vector> +#include <QObject> + +class QGraphicsScene; +class QGraphicsView; +class QGraphicsItem; +class map_library; + +class map_painter : public QObject +{ + Q_OBJECT +public: + map_painter(); + ~map_painter(); + void set_dimension(int h, int v); + void set_map_library(map_library *lib); + void set_map_id(int pos, bool populated, int id, bool user_input = false); + + QGraphicsView* view() { return v; } +signals: + void map_id_changed(int pos, bool populated, int id); +private: + QGraphicsView *v; + QGraphicsScene *s; + map_library *l; + int hc; + int vc; + std::vector<QGraphicsItem*> slices; +}; + +#endif |