From 1faecafbc6cc74daa8d0a781c0b54f2c778b04b0 Mon Sep 17 00:00:00 2001 From: Stefan Suhren Date: Sat, 16 May 2015 23:41:43 +0200 Subject: Add 2d drawing for lines. --- line.h | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 line.h (limited to 'line.h') diff --git a/line.h b/line.h new file mode 100644 index 0000000..745f653 --- /dev/null +++ b/line.h @@ -0,0 +1,22 @@ +#ifndef LINE_H +#define LINE_H + +#include +#include +#include + +class Line : public QLine +{ +public: + Line(); + Line(const Line &other); + + bool isHit(const QPoint & clickPoint); + void setSelected(bool selected); + void draw(QPainter * painter); + +private: + bool m_selected; +}; + +#endif // LINE_H -- cgit v1.2.3-70-g09d2