summaryrefslogtreecommitdiff
path: root/src/gui/toolpalette.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/toolpalette.h')
-rw-r--r--src/gui/toolpalette.h34
1 files changed, 34 insertions, 0 deletions
diff --git a/src/gui/toolpalette.h b/src/gui/toolpalette.h
new file mode 100644
index 0000000..ba6aed5
--- /dev/null
+++ b/src/gui/toolpalette.h
@@ -0,0 +1,34 @@
+/**
+ * A small window that lets the user select the current editing tool.
+ */
+
+#ifndef TOOLPALETTE_H
+#define TOOLPALETTE_H
+
+#include <QObject>
+#include <QToolBar>
+#include <QAction>
+#include <QActionGroup>
+
+class ToolPalette : public QToolBar
+{
+ Q_OBJECT
+public:
+ ToolPalette(QWidget *parent = 0);
+ enum Tool {
+ SELECT,
+ VERTEX,
+ EDGE,
+ CROP
+ };
+
+ Tool currentTool() const;
+private:
+ QActionGroup *tools;
+ QAction *select;
+ QAction *vertex;
+ QAction *edge;
+ QAction *crop;
+};
+
+#endif // TOOLPALETTE_H